【问题标题】:difficulty with psycopg2 on macOS Catalina 10.15.5 [duplicate]macOS Catalina 10.15.5 上 psycopg2 的困难 [重复]
【发布时间】:2020-12-28 08:46:09
【问题描述】:

我有一个已完成的简单 django 博客应用程序,正在部署到 heroku。

我现在有一个实时应用程序,但我的静态 css 文件不包括在内。我认为我已经在我的 settings.py 文件中发现了(部分)问题,其中 django_heroku 无法导入。

当我尝试 pip install django-heroku 时,我在 psycopg2 处出错:

    ld: library not found for -lssl
    clang: error: linker command failed with exit code 1 (use -v to see invocation)
    error: command 'gcc' failed with exit status 1

我似乎安装了自制软件,并且安装了最新版本的 gcc、openssl 和 xcode。

有人对我下一步可以尝试什么有任何建议吗?

【问题讨论】:

标签: python django xcode heroku psycopg2


【解决方案1】:

我过去曾遇到过有关 psycopg2 和 MacOS 的问题。你试过安装预编译的版本吗?

pip install psycopg2-binary

这通常会为我解决问题!

【讨论】:

    猜你喜欢
    • 2020-11-02
    • 1970-01-01
    • 2020-04-23
    • 2020-09-28
    • 2020-09-22
    • 1970-01-01
    • 1970-01-01
    • 1970-01-01
    • 1970-01-01
    相关资源
    最近更新 更多