couchdb-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Paul Torres <ptorres...@gmail.com>
Subject Re: geocouch with polygons
Date Wed, 18 Jul 2012 04:40:16 GMT
Volker,
    Thanks for the tip. It sheds some light on the problem. Your
suggestion indeed
produced an error, however I think I have a problem unrelated to GEOS?
But I'm not
sure what.

The error states:
=ERROR REPORT==== 18-Jul-2012::00:31:27 ===
The on_load function for module erlgeom returned {error,
                                                  {load_failed,
                                                   "Failed to load NIF
library: '/home/paul/couchdb/geocouch_experimental/geocouch/deps/erlgeom/priv/erlgeom.so:
cannot open shared object file: No such file or directory'"}}
** exception error: undefined function erlgeom:to_geom/1

In that directory there is a single file but it is named erlgeom_drv.so
This seems to be a much more fundamental and simpler problem than the
proper installation of a library. I double checked with git that I am
using the couchdbgeom branch. The compilation of geocouch runs fine as
do whatever tests I can run from the provided makefile.

Am I checking out the wrong branch with git?

GEOS, compiled for me fine and passes all of its tests. Is there a
minimum version of GEOS required? Your documentation is silent on the
matter and I presume there must be a minimum--or at least a version
you worked with? I could just use the debian package for GEOS instead
of compiling the latest version from source. If indeed I made a
mistake somewhere installing GEOS from source that would be one way to
cure it.

-Paul

On Mon, Jul 16, 2012 at 10:21 AM, Volker Mische <volker.mische@gmail.com> wrote:
> Hi Paul,
>
> do you have GEOS [1] installed?
>
> In case you start CouchDB with ./utils/run, you can run it with "-i".
> Now you have an interactive shell. Try there something like:
>
> erlgeom:to_geom({'Point',[5,5]}).
>
> Now you should get an error, if the NIF can't be loaded (which could be
> the case if you don't have GEOS installed properly).
>
> [1] http://trac.osgeo.org/geos/
>
> Cheers,
>   Volker
>
> On 07/15/2012 12:21 AM, Paul Torres wrote:
>> Volker,
>>      I finally traced all my mistakes. Couch 1.2.0 works fine now and
>> passes all Couch 1.2.0 specific tests. I had to upgrade my version of
>> Firefox in the process amongst other things. I had also forgotten to
>> update an environment flag.
>>
>>      In any event, all but one test for geocouch (with polygons)
>> passes. The final test spatial_opensearch fails with:
>> Assertion 'Intersects 3 geometries.' failed: expected '3', got '0'
>> Assertion 'searching with polygon' failed: expected '["0","1","2"]', got '[]'
>> Assertion 'Intersects one LineString twice.' failed: expected '1', got '0'
>> Assertion 'Intersects one geometry.' failed: expected '1', got '0'
>> Assertion 'Intersects two geometries.' failed: expected '2', got '0'
>>
>>      Any clue what that might be?
>>
>> -Paul
>>
>> On Thu, Jul 12, 2012 at 2:32 AM, Paul Torres <ptorresnyc@gmail.com> wrote:
>>> Thank you Volker. I am interested in getting this to work.
>>>
>>> I'll have to get back to you still later. I thought I was having
>>> problems with geocouch (with support for polygons) in combination with
>>> couchdb 1.2.0 but it turns out I'm having problems with couchdb 1.2.0
>>> itself. Maybe I can get advice on this new issue from someone?
>>>
>>> 1.2.0 builds fine, make check passes all tests, the configure script
>>> is happy, and
>>> I removed the first installation (I used make uninstall to do some of
>>> that as well).
>>> I manually removed the old geocouch.ini file. After the new install I
>>> changed the
>>> ownership and groups to my couchdb user and group, etc. And I am not
>>> forgetting to
>>> use Firefox.
>>>
>>> But some of the futon tests are failing...and then many of them fail.
>>> To be precise, the attachments test fails right away with:
>>> Assertion failed: xhr.responseText == lorem
>>> Exception raised: {}
>>>
>>> list_views fails right away with:
>>> Assertion 'xhr.status == 200, "standard get should be 200"' failed:
>>> standard get should be 200
>>> Assertion failed: /head0123456789tail/.test(xhr.responseText)
>>>
>>> rev_stemming fails right away with:
>>> Assertion failed: db.open("bar", {revs: true})._revisions.ids.length
>>> == newLimit + 1
>>> Assertion failed: db.open("bar", {revs: true})._revisions.ids.length
>>> == newLimit + 1
>>>
>>> view_compaction fails [but succeeds on a 2nd manual try] with:
>>> Assertion failed: resp.view_index.disk_size < disk_size_before_compact
>>>
>>>
>>> Then if I run all the tests again, a whole lot more of them fail. In particular
>>> all tests after users_db_security fail with the error:
>>> Exception raised: {"error":"unauthorized","reason":"You are not a
>>> server admin."}
>>> The test users_db_security itself fails with: Exception raised: {}
>>>
>>>
>>> And following any links--or clicking on reload--causes the "admin party" to
>>> suddenly end and I'm no longer admin nor can I run any more tests. The "Verify
>>>  your installation" works the first time (before all these failed tests) but
>>> after the failures, it returns X: [object Object]
>>>
>>> I'm not sure what to do. I have a nagging feeling something from the
>>> 1.1.0 install
>>> lingers and screws up the 1.2.0 install, but I cannot find it. And if it is not
>>> that I don't have a clue right now what is causing this error. I've never had
>>> this much trouble building from source before and it's eaten up so much time.
>>>
>>> -Paul
>>>
>>> On Wed, Jul 11, 2012 at 11:19 AM, Volker Mische <volker.mische@gmail.com>
wrote:
>>>> Hi Paul
>>>>
>>>> On 07/11/2012 03:44 AM, Paul Torres wrote:
>>>>> Does anyone have any experience with the latest experimental geocouch
>>>>> that supports
>>>>> polygons? From: https://github.com/vmx/geocouch/tree/couchdbgeom
>>>>
>>>> Yes ;)
>>>>
>>>>> Being experimental, does that mean the tests in the futon test suite
do not
>>>>> neccessarily all pass? I have a few that are failing, but I cannot track
down
>>>>> any (more) of my own errors that might be causing it. I have all the
>>>>> dependencies
>>>>> including GEOS available in my PATH, and my ERL_FLAGS are set, etc. I
>>>>> compiled and copied the .ini file and the tests and updated the list
>>>>> of tests that
>>>>> should be run... I'm running couch 1.1.0 compiled from source.
>>>>
>>>> All Futon tests should work. The problem might be that this version is
>>>> for CouchDB 1.2.0 and was only tested with it.
>>>>
>>>>> Poking around the makefile for the geocouch I noticed it included targets
for
>>>>> running tests and these do not all pass either, so it would seem to me
that
>>>>> something might be wrong at the compilation stage. If true then I guess
the
>>>>> code just needs more work. But is that the case? I'm not very fluent
in Erlang
>>>>> yet to read it all and determine definitely for myself and I'd like to
>>>>> double check
>>>>> with anyone who knows for certain.
>>>>
>>>> Try again with CouchDB 1.2.0 and let me know if it still doesn't pass
>>>> all tests.
>>>>
>>>> Cheers,
>>>>   Volker
>>>>
>

Mime
View raw message