Heroku-16, Django==1.11.8  

Any `heroku run python manage.py x` command will throw:  

OSError: libjasper.so.1: cannot open shared object file: No such file or 
directory

According to this issue 
here: https://github.com/cyberdelia/heroku-geo-buildpack/issues/43, 
heroku-16 is without libjasper at runtime.  

It was apparently solved by user @dschep 
here: 
https://github.com/TrailStash/heroku-geo-buildpack/commit/5ae45e57353aab6a9fb2f0443e9ea0974d8b29ba
  

However for me and others, the same issue remains even when using the 
forked buildpack. Libjasper is nowhere to be found.   

Anybody push through this?  

some personal settings:  

import dj_database_url
from os import environ

DATABASES['default'] =  dj_database_url.config()
DATABASES['default']['ENGINE'] = 'django.contrib.gis.db.backends.postgis'

GEOS_LIBRARY_PATH = "{}/libgeos_c.so".format(environ.get('GEOS_LIBRARY_PATH'))
GDAL_LIBRARY_PATH = "{}/libgdal.so".format(environ.get('GDAL_LIBRARY_PATH'))
PROJ4_LIBRARY_PATH = "{}/libproj.so".format(environ.get('PROJ4_LIBRARY_PATH'))



A full traceback in case:  

Running python manage.py migrate on ⬢ paup... up, run.5502 (Free)

/app/.heroku/python/lib/python3.6/site-packages/daphne/server.py:12: 
UserWarning: Something has already installed a non-asyncio Twisted reactor. 
Attempting to uninstall it; you can fix this warning by importing daphne.server 
early in your codebase or finding the package that imports Twisted and 
importing it later on.

  UserWarning,

Traceback (most recent call last):

  File "manage.py", line 29, in <module>

    execute_from_command_line(sys.argv)

  File 
"/app/.heroku/python/lib/python3.6/site-packages/django/core/management/__init__.py"
, line 364, in execute_from_command_line

    utility.execute()

  File 
"/app/.heroku/python/lib/python3.6/site-packages/django/core/management/__init__.py"
, line 338, in execute

    django.setup()

  File "/app/.heroku/python/lib/python3.6/site-packages/django/__init__.py", 
line 27, in setup

    apps.populate(settings.INSTALLED_APPS)

  File 
"/app/.heroku/python/lib/python3.6/site-packages/django/apps/registry.py", 
line 108, in populate

    app_config.import_models()

  File 
"/app/.heroku/python/lib/python3.6/site-packages/django/apps/config.py", 
line 202, in import_models

    self.models_module = import_module(models_module_name)

  File "/app/.heroku/python/lib/python3.6/importlib/__init__.py", line 126, 
in import_module

    return _bootstrap._gcd_import(name[level:], package, level)

  File "<frozen importlib._bootstrap>", line 978, in _gcd_import

  File "<frozen importlib._bootstrap>", line 961, in _find_and_load

  File "<frozen importlib._bootstrap>", line 950, in _find_and_load_unlocked

  File "<frozen importlib._bootstrap>", line 655, in _load_unlocked

  File "<frozen importlib._bootstrap_external>", line 678, in exec_module

  File "<frozen importlib._bootstrap>", line 205, in 
_call_with_frames_removed

  File 
"/app/.heroku/python/lib/python3.6/site-packages/django/contrib/auth/models.py"
, line 4, in <module>

    from django.contrib.auth.base_user import AbstractBaseUser, 
BaseUserManager

  File 
"/app/.heroku/python/lib/python3.6/site-packages/django/contrib/auth/base_user.py"
, line 52, in <module>

    class AbstractBaseUser(models.Model):

  File 
"/app/.heroku/python/lib/python3.6/site-packages/django/db/models/base.py", 
line 124, in __new__

    new_class.add_to_class('_meta', Options(meta, app_label))

  File 
"/app/.heroku/python/lib/python3.6/site-packages/django/db/models/base.py", 
line 325, in add_to_class

    value.contribute_to_class(cls, name)

  File 
"/app/.heroku/python/lib/python3.6/site-packages/django/db/models/options.py"
, line 214, in contribute_to_class

    self.db_table = truncate_name(self.db_table, connection.ops.
max_name_length())

  File 
"/app/.heroku/python/lib/python3.6/site-packages/django/db/__init__.py", 
line 33, in __getattr__

    return getattr(connections[DEFAULT_DB_ALIAS], item)

  File "/app/.heroku/python/lib/python3.6/site-packages/django/db/utils.py", 
line 211, in __getitem__

    backend = load_backend(db['ENGINE'])

  File "/app/.heroku/python/lib/python3.6/site-packages/django/db/utils.py", 
line 115, in load_backend

    return import_module('%s.base' % backend_name)

  File "/app/.heroku/python/lib/python3.6/importlib/__init__.py", line 126, 
in import_module

    return _bootstrap._gcd_import(name[level:], package, level)

  File 
"/app/.heroku/python/lib/python3.6/site-packages/django/contrib/gis/db/backends/postgis/base.py"
, line 6, in <module>

    from .features import DatabaseFeatures

  File 
"/app/.heroku/python/lib/python3.6/site-packages/django/contrib/gis/db/backends/postgis/features.py"
, line 1, in <module>

    from django.contrib.gis.db.backends.base.features import 
BaseSpatialFeatures

  File 
"/app/.heroku/python/lib/python3.6/site-packages/django/contrib/gis/db/backends/base/features.py"
, line 4, in <module>

    from django.contrib.gis.db.models import aggregates

  File 
"/app/.heroku/python/lib/python3.6/site-packages/django/contrib/gis/db/models/__init__.py"
, line 3, in <module>

    from django.contrib.gis.db.models.aggregates import *  # NOQA

  File 
"/app/.heroku/python/lib/python3.6/site-packages/django/contrib/gis/db/models/aggregates.py"
, line 1, in <module>

    from django.contrib.gis.db.models.fields import ExtentField

  File 
"/app/.heroku/python/lib/python3.6/site-packages/django/contrib/gis/db/models/fields.py"
, line 3, in <module>

    from django.contrib.gis import forms, gdal

  File 
"/app/.heroku/python/lib/python3.6/site-packages/django/contrib/gis/forms/__init__.py"
, line 3, in <module>

    from .fields import (  # NOQA

  File 
"/app/.heroku/python/lib/python3.6/site-packages/django/contrib/gis/forms/fields.py"
, line 4, in <module>

    from django.contrib.gis.geos import GEOSException, GEOSGeometry

  File 
"/app/.heroku/python/lib/python3.6/site-packages/django/contrib/gis/geos/__init__.py"
, line 5, in <module>

    from .collections import (  # NOQA

  File 
"/app/.heroku/python/lib/python3.6/site-packages/django/contrib/gis/geos/collections.py"
, line 11, in <module>

    from django.contrib.gis.geos.geometry import GEOSGeometry, 
LinearGeometryMixin

  File 
"/app/.heroku/python/lib/python3.6/site-packages/django/contrib/gis/geos/geometry.py"
, line 11, in <module>

    from django.contrib.gis import gdal

  File 
"/app/.heroku/python/lib/python3.6/site-packages/django/contrib/gis/gdal/__init__.py"
, line 28, in <module>

    from django.contrib.gis.gdal.datasource import DataSource

  File 
"/app/.heroku/python/lib/python3.6/site-packages/django/contrib/gis/gdal/datasource.py"
, line 39, in <module>

    from django.contrib.gis.gdal.driver import Driver

  File 
"/app/.heroku/python/lib/python3.6/site-packages/django/contrib/gis/gdal/driver.py"
, line 5, in <module>

    from django.contrib.gis.gdal.prototypes import ds as vcapi, raster as 
rcapi

  File 
"/app/.heroku/python/lib/python3.6/site-packages/django/contrib/gis/gdal/prototypes/ds.py"
, line 9, in <module>

    from django.contrib.gis.gdal.libgdal import GDAL_VERSION, lgdal

  File 
"/app/.heroku/python/lib/python3.6/site-packages/django/contrib/gis/gdal/libgdal.py"
, line 49, in <module>

    lgdal = CDLL(lib_path)

  File "/app/.heroku/python/lib/python3.6/ctypes/__init__.py", line 348, in 
__init__

    self._handle = _dlopen(self._name, mode)

OSError: libjasper.so.1: cannot open shared object file: No such file or 
directory



-- 
You received this message because you are subscribed to the Google Groups 
"Django users" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to django-users+unsubscr...@googlegroups.com.
To post to this group, send email to django-users@googlegroups.com.
Visit this group at https://groups.google.com/group/django-users.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/django-users/fb70d9cb-6fe0-49e6-95bd-d5112d72f07d%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.

Reply via email to