Am having a real problem with the geodjango saving an entry.
It produces a “Error: Access Violation reading 0x???????”
The error does not indicate which file or folder it’s trying to gain read/write access to.
Upon researching i found other non-django programs that also have this issue, some were fixed by turning off Vista’s DEP controller, but am a bit scared to go down this route and am not even totally sure if this would fix the issue.
Any one got any ideas….?
Vista is a nightmare to work on.
Below is error output:
Python 2.5.4 (r254:67916, Dec 23 2008, 15:10:54) [MSC v.1310
Type “help”, “copyright”, “credits” or “license” for more in
(InteractiveConsole)
from django.contrib.gis.utils import add_postgis_srs
add_postgis_srs(900913)
from geofencing.models import FencingBorder
from django.contrib.gis.geos import Point
il = FencingBorder()
il.name = ‘some place’
il.interestingness = 3
il.geometry = Point(-16.57,14.0)
Traceback (most recent call last):
File “”, line 1, in
File “C:SWsoftPleskAdditionalPythonlibsite-packages
if isinstance(value, self._klass) and (str(value.geom_ty
File “C:SWsoftPleskAdditionalPythonLibsite-packages
return capi.geos_type(self.ptr)
File “C:SWsoftPleskAdditionalPythonlibsite-packages
in call
return self.cfunc(*args)
File “C:SWsoftPleskAdditionalPythonlibsite-packages
check_string
free(result)
WindowsError: exception: access violation reading 0x03C2A964
il.geometry = Point(-16.57,14.0)
Traceback (most recent call last):
File “”, line 1, in
File “C:SWsoftPleskAdditionalPythonlibsite-packages
if isinstance(value, self._klass) and (str(value.geom_ty
File “C:SWsoftPleskAdditionalPythonLibsite-packages
return capi.geos_type(self.ptr)
File “C:SWsoftPleskAdditionalPythonlibsite-packages
in call
return self.cfunc(*args)
File “C:SWsoftPleskAdditionalPythonlibsite-packages
check_string
free(result)
WindowsError: exception: access violation reading 0x03C2A964
2
Answers
Right In case anyone else ever has the issue.. The problem was following a doc referenced at: http://code.google.com/p/geodjango-basic-apps/wiki/FOSS4GWorkshop
if you install GDAL from binary or install PostgreSQL 9.0 DO NOT reference the GDAL dll file in your settings.py. Always go with setting the VARIABLE_DEFINITION in windows system's PATH.
The culprit was this in settings.py: GEOS_LIBRARY_PATH='c:geodjangogdalbingeos_c_fw.dll'
You seems to have answered your own question. Thanks for the suggestion. I had a similar issue as well. I also had a line like:
GEOS_LIBRARY_PATH = r’C:OSGeo4Wbingeos_c.dll’
(Hijack the topic for a while. I know people have problems with finding a working geos binary distribution on windows. After several tries, seems OSGeo4W’s distribution works for me. But I read on other people’s blogs that some other distribution instead of OSGeo4W’s works on their machines.)
So I remove this line and add C:OSGeo4Wbingeos_c.dll to system’s PATH environment variable. After that, it works fine. So this confirms Tuscan’s solution. Hopes it can help people running into the same issue.