funciton GDALAllRegister not found, django 1.8a release on windows

30 views
Skip to first unread message

mattxbart

unread,
Feb 2, 2015, 1:55:05 PM2/2/15
to django...@googlegroups.com
Hi all,
I had a working 1.7.4 (using geodjango) on windows 7 install, no issues. I'm using osgeo4w to manage all the gdal/gis libraries. When I install the django 1.8a release or off git master, I get the following traceback:

$ ./manage.py shell
Traceback (most recent call last):
  File "./manage.py", line 10, in <module>
    execute_from_command_line(sys.argv)
  File "c:\Python27\lib\site-packages\django\core\management\__init__.py", line
338, in execute_from_command_line
    utility.execute()
  File "c:\Python27\lib\site-packages\django\core\management\__init__.py", line
312, in execute
    django.setup()
  File "c:\Python27\lib\site-packages\django\__init__.py", line 18, in setup
    apps.populate(settings.INSTALLED_APPS)
  File "c:\Python27\lib\site-packages\django\apps\registry.py", line 108, in pop
ulate
    app_config.import_models(all_models)
  File "c:\Python27\lib\site-packages\django\apps\config.py", line 202, in impor
t_models
    self.models_module = import_module(models_module_name)
  File "c:\Python27\lib\importlib\__init__.py", line 37, in import_module
    __import__(name)
  File "c:\Python27\lib\site-packages\django\contrib\auth\models.py", line 42, i
n <module>
    class Permission(models.Model):
  File "c:\Python27\lib\site-packages\django\db\models\base.py", line 126, in __
new__
    new_class.add_to_class('_meta', Options(meta, **kwargs))
  File "c:\Python27\lib\site-packages\django\db\models\base.py", line 310, in ad
d_to_class
    value.contribute_to_class(cls, name)
  File "c:\Python27\lib\site-packages\django\db\models\options.py", line 246, in
 contribute_to_class
    self.db_table = truncate_name(self.db_table, connection.ops.max_name_length(
))
  File "c:\Python27\lib\site-packages\django\db\__init__.py", line 36, in __geta
ttr__
    return getattr(connections[DEFAULT_DB_ALIAS], item)
  File "c:\Python27\lib\site-packages\django\db\utils.py", line 238, in __getite
m__
    backend = load_backend(db['ENGINE'])
  File "c:\Python27\lib\site-packages\django\db\utils.py", line 109, in load_bac
kend
    return import_module('%s.base' % backend_name)
  File "c:\Python27\lib\importlib\__init__.py", line 37, in import_module
    __import__(name)
  File "c:\Python27\lib\site-packages\django\contrib\gis\db\backends\postgis\bas
e.py", line 9, in <module>
    from .features import DatabaseFeatures
  File "c:\Python27\lib\site-packages\django\contrib\gis\db\backends\postgis\fea
tures.py", line 1, in <module>
    from django.contrib.gis.db.backends.base.features import BaseSpatialFeatures

  File "c:\Python27\lib\site-packages\django\contrib\gis\db\backends\base\featur
es.py", line 3, in <module>
    from django.contrib.gis.db.models import aggregates
  File "c:\Python27\lib\site-packages\django\contrib\gis\db\models\__init__.py",
 line 7, in <module>
    from django.contrib.gis.geos import HAS_GEOS
  File "c:\Python27\lib\site-packages\django\contrib\gis\geos\__init__.py", line
 16, in <module>
    from .geometry import GEOSGeometry, wkt_regex, hex_regex
  File "c:\Python27\lib\site-packages\django\contrib\gis\geos\geometry.py", line
 13, in <module>
    from django.contrib.gis.gdal.error import SRSException
  File "c:\Python27\lib\site-packages\django\contrib\gis\gdal\__init__.py", line
 47, in <module>
    from django.contrib.gis.gdal.driver import Driver  # NOQA
  File "c:\Python27\lib\site-packages\django\contrib\gis\gdal\driver.py", line 4
, in <module>
    from django.contrib.gis.gdal.prototypes import ds as vcapi, raster as rcapi
  File "c:\Python27\lib\site-packages\django\contrib\gis\gdal\prototypes\raster.
py", line 22, in <module>
    register_all = void_output(lgdal.GDALAllRegister, [])
  File "c:\Python27\lib\ctypes\__init__.py", line 378, in __getattr__
    func = self.__getitem__(name)
  File "c:\Python27\lib\ctypes\__init__.py", line 383, in __getitem__
    func = self._FuncPtr((name_or_ordinal, self))
AttributeError: function 'GDALAllRegister' not found

I've installed all 32bit libs, looks like something in the new raster functionality? How can I get this working?

Thanks,
Matt
Reply all
Reply to author
Forward
0 new messages