Tuesday, March 27, 2012

Re: LinearRing creation causing WindowsError

The solution I found is as follows:

I updated to the latest OSGeo4W (which still uses GEOS 3.2.2 as far as
I can tell), added OSGeo4W to my PATH var and LinearRing is working
fine.

I had been using a work-around configuration referencing (in my PATH
var) the GEOS binaries included with a Postgres 9.0 install (also
3.2.2, but from Sept of 2010 while the OSGeo4W GEOS 3.2.2 is from Dec
of 2010...seems weird, but that's what I'm seeing).
This configuration worked fine until my Django upgrade this morning
when LinearRing stopped working (see original email for error
details).

So, in closing, I'm not really sure what's going on here, but
LinearRing is working for me once again.


On Mar 27, 1:52 pm, sfletche <sflet...@gmail.com> wrote:
> I updated Django today to trunk (last update was Oct 2010) and I'm now
> getting an error when creating a LinearRing object.
> The following from a python shell will produce the error:
>
> from django.contrib.gis.geos import *
> test = LinearRing ( [ (1,1), (2,1), (2,2), (1,1) ] )
> test
>
> Accessing 'test' with the last line above causes the following error
> to occur:
>
> WindowsError: exception: access violation writing 0x0291CC80
>
> (the string of chars following the 0x will naturally vary)
>
> As best I can tell, I have GEOS 3.2.2 installed (and will happily give
> more information if it helps).
> (I say 'As best as I can tell' as this is what is reported when I run
> "select postgis_full_version()" from psql command prompt and the
> PostgresSQL\9.0\bin is the only entry in my PATH variable that I can
> see that would point to the GEOS binaries).
>
> I can run the same python code on a Linux machine (with the latest
> Django and GEOS 3.3.2) and I get no error (not sure if it's the GEOS
> library version or the OS that's making the difference...).
>
> Any ideas?

--
You received this message because you are subscribed to the Google Groups "Django users" group.
To post to this group, send email to django-users@googlegroups.com.
To unsubscribe from this group, send email to django-users+unsubscribe@googlegroups.com.
For more options, visit this group at http://groups.google.com/group/django-users?hl=en.

No comments:

Post a Comment