Closed jiaminlim closed 1 year ago
I had the same error on Ubuntu, and was able to fix by first doing:
sudo apt-get install libpq-dev
sudo ln -s /bin/gcc /bin/gcc-5
After that, .venv/bin/python -m pip install -e .
installed everything correctly for me.
So, might be worth trying that. (I got that solution somewhere on stackoverflow; apologies to the unnamed user I'm failing to credit)
This sounds like the kind of thing that happens when pip tries to compile psycopg2 for you from source, which you can also solve by installing the binary which is in pip as psycopg2[binary]
EG:
source .venv/bin/activate
pip install psycopg2[binary]
git clone https://github.com/unitedstates/congressional-record.git
cd congressional-record
python3 -m venv .venv
.venv/bin/python -m pip install -e .
.venv/bin/python -m congressionalrecord.cli -h
The fourth line above yields the following:
Based on the above, I installed the 'psycopg2-binary' package using pip install, but I reran the fourth line and am getting the same error.
Then when running the 5th line - I get this error:
Any advice/guidance would be much appreciated.