Closed nikochiko closed 4 years ago
Solved by
pip install --upgrade psycopg2-binary
@ChetanMadan I think the problem is that Ubuntu 18.04 is not supported by Fabrik. I was able to install it successfully on Ubuntu 16,04
I just finished setting it up the docker way on Ubuntu 18.04! It is working just fine. @nikochiko
@nikochiko , it would be easier to setup using docker/ docker-compose. Might take some time in building the images but once done, it should be a cake walk ..!
OS: Ubuntu 18.04 WSL running on Windows 10 Home Environment: Python2.7 virtualenv as described in readme installation instructions. Error occurred during: Installation (using virtualenv as described in the readme) At step 7: while executing the line
python manage.py makemigrations caffe_app
Description: While trying to install fabrik with the instructions mentioned, this error occurs:
Using Dev settings Traceback (most recent call last): File "manage.py", line 10, in
execute_from_command_line(sys.argv)
File "/root/Fabrik/local/lib/python2.7/site-packages/django/core/management/init.py", line 367, in execute_from_command_line
utility.execute()
File "/root/Fabrik/local/lib/python2.7/site-packages/django/core/management/init.py", line 341, in execute
django.setup()
File "/root/Fabrik/local/lib/python2.7/site-packages/django/init.py", line 27, in setup
apps.populate(settings.INSTALLED_APPS)
File "/root/Fabrik/local/lib/python2.7/site-packages/django/apps/registry.py", line 108, in populate
app_config.import_models(all_models)
File "/root/Fabrik/local/lib/python2.7/site-packages/django/apps/config.py", line 199, in import_models
self.models_module = import_module(models_module_name)
File "/usr/lib/python2.7/importlib/init.py", line 37, in import_module
import(name)
File "/home/wyz/projects/Dev/Fabrik/Fabrik/caffe_app/models.py", line 2, in
from django.contrib.auth.models import User
File "/root/Fabrik/local/lib/python2.7/site-packages/django/contrib/auth/models.py", line 4, in
from django.contrib.auth.base_user import AbstractBaseUser, BaseUserManager
File "/root/Fabrik/local/lib/python2.7/site-packages/django/contrib/auth/base_user.py", line 52, in
class AbstractBaseUser(models.Model):
File "/root/Fabrik/local/lib/python2.7/site-packages/django/db/models/base.py", line 119, in new
new_class.add_to_class('_meta', Options(meta, app_label))
File "/root/Fabrik/local/lib/python2.7/site-packages/django/db/models/base.py", line 316, in add_to_class
value.contribute_to_class(cls, name)
File "/root/Fabrik/local/lib/python2.7/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 "/root/Fabrik/local/lib/python2.7/site-packages/django/db/init.py", line 33, in getattr
return getattr(connections[DEFAULT_DB_ALIAS], item)
File "/root/Fabrik/local/lib/python2.7/site-packages/django/db/utils.py", line 211, in getitem
backend = load_backend(db['ENGINE'])
File "/root/Fabrik/local/lib/python2.7/site-packages/django/db/utils.py", line 115, in load_backend
return import_module('%s.base' % backend_name)
File "/usr/lib/python2.7/importlib/init.py", line 37, in import_module
import(name)
File "/root/Fabrik/local/lib/python2.7/site-packages/django/db/backends/postgresql/base.py", line 24, in
raise ImproperlyConfigured("Error loading psycopg2 module: %s" % e)
django.core.exceptions.ImproperlyConfigured: Error loading psycopg2 module: /root/Fabrik/local/lib/python2.7/site-packages/psycopg2/.libs/libresolv-2-c4c53def.5.so: symbol __res_maybe_init version GLIBC_PRIVATE not defined in file libc.so.6 with link time reference
I googled for the issue and found this.
It's a known bug in psycopg2 versions prior to 2.2 but the version I have is 2.7.3 (as per requirements/common.txt). Can't figure out the issue.