2

我已经在我的机器(Mac OS)上安装了 Postgres 和 Django,但是当我运行 Django 服务器时,我得到了这个错误

50>>
Traceback (most recent call last):
  File "/Library/Python/2.7/site-packages/django/core/management/commands/runserver.py", line 91, in inner_run
    self.validate(display_num_errors=True)
  File "/Library/Python/2.7/site-packages/django/core/management/base.py", line 266, in validate
    num_errors = get_validation_errors(s, app)
  File "/Library/Python/2.7/site-packages/django/core/management/validation.py", line 23, in get_validation_errors
    from django.db import models, connection
  File "/Library/Python/2.7/site-packages/django/db/__init__.py", line 40, in <module>
    backend = load_backend(connection.settings_dict['ENGINE'])
  File "/Library/Python/2.7/site-packages/django/db/__init__.py", line 34, in __getattr__
    return getattr(connections[DEFAULT_DB_ALIAS], item)
  File "/Library/Python/2.7/site-packages/django/db/utils.py", line 92, in __getitem__
    backend = load_backend(db['ENGINE'])
  File "/Library/Python/2.7/site-packages/django/db/utils.py", line 24, in load_backend
    return import_module('.base', backend_name)
  File "/Library/Python/2.7/site-packages/django/utils/importlib.py", line 35, in import_module
    __import__(name)
  File "/Library/Python/2.7/site-packages/django/db/backends/postgresql_psycopg2/base.py", line 13, in <module>
    from django.db.backends.postgresql_psycopg2.creation import DatabaseCreation
  File "/Library/Python/2.7/site-packages/django/db/backends/postgresql_psycopg2/creation.py", line 1, in <module>
    import psycopg2.extensions
  File "/Library/Python/2.7/site-packages/psycopg2/__init__.py", line 67, in <module>
    from psycopg2._psycopg import BINARY, NUMBER, STRING, DATETIME, ROWID
ImportError: dlopen(/Library/Python/2.7/site-packages/psycopg2/_psycopg.so, 2): Library not loaded:
@loader_path/../lib/libssl.dylib
  Referenced from: /usr/lib/libpq.5.dylib
  Reason: Incompatible library version: libpq.5.dylib requires version 1.0.0 or later, but libssl.0.9.8.dylib provides version
0.9.8

请问我在这里错过了什么。

4

0 回答 0