Machine: Mac OSX Python Version: 3.X, specifically 3.7.3
I was looking at the psycopg2 documentation, it said it was Python3 friendly. https://pypi.org/project/psycopg2/
It was saying that all i would need to do is to do something akin to: pip install psycopg2
but when I do it, setup.py install will give an error.
ERROR: Command "/usr/local/bin/python3.7 -u -c 'import setuptools, tokenize;file='"'"'/private/var/folders/r3/lv90w0yx6xq9t2p4qgb7yb1r0000gn/T/pip-install-66v9kpqs/psycopg2/setup.py'"'"';f=getattr(tokenize, '"'"'open'"'"', open)(file);code=f.read().replace('"'"'\r\n'"'"', '"'"'\n'"'"');f.close();exec(compile(code, file, '"'"'exec'"'"'))' install --record /private/var/folders/r3/lv90w0yx6xq9t2p4qgb7yb1r0000gn/T/pip-record-8anshmva/install-record.txt --single-version-externally-managed --compile" failed with error code 1 in /private/var/folders/r3/lv90w0yx6xq9t2p4qgb7yb1r0000gn/T/pip-install-66v9kpqs/psycopg2/
I was trying to figure out how to progress with this, in order to have psycopg2 be easily used within Python3.
I dont think i should be downloading the source and building it and likewise their website says I shouldnt use binaries for production.
The following gives the insight to use the binary on my mac, but not to use it for production. I can't install Psycopg2 with Python3 on Mac. I've installed Python3 and pip3 This gives me one caveat, I am not sure what my prod server will be. Usually it is unix, but i was thinking "wait, does mac have a prod server? How would i do it for there then?"
It wanted me to just implement: pip3 install psycopg2-binary
but like what the psycopg2 website said, that should not be a prod solution. Me personally, I dont like writing custom scripts for custom OS. I think that to give the best experience, the application should be cross-platform compatible, ESPECIALLY since this is python.
I cant seem to figure it out, has anyone figured out how to do this?
EDIT: Pip3 install seems to cause an error with GCC when compiling. The issue I saw was as follows:
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
I tested it and gcc is in my path, so it seems that it doesnt know what lssl is. why would that not be a valid statement. I figured pip3 would have tested against this?