Skip to content
This repository has been archived by the owner on Aug 31, 2022. It is now read-only.

Fails installation via pip #4

Closed
dhmspector opened this issue Aug 31, 2015 · 3 comments
Closed

Fails installation via pip #4

dhmspector opened this issue Aug 31, 2015 · 3 comments

Comments

@dhmspector
Copy link

Was trying to install the API in my virtual env, and got the following failure, other packages install and work just fine. Any suggestions?

(datamanager) Zeitgeist:datamanager spector$ pip install sodapy
Collecting sodapy
Using cached sodapy-0.1.6.tar.gz
Complete output from command python setup.py egg_info:
Traceback (most recent call last):
File "", line 20, in
File "/private/var/folders/kh/q9217zqs1wdf6g7yzczz09br0000gn/T/pip-build-jkmfj12g/sodapy/setup.py", line 4, in
execfile("sodapy/version.py")
NameError: name 'execfile' is not defined

----------------------------------------

Command "python setup.py egg_info" failed with error code 1 in /private/var/folders/kh/q9217zqs1wdf6g7yzczz09br0000gn/T/pip-build-jkmfj12g/sodapy

@xmunoz
Copy link
Owner

xmunoz commented Aug 31, 2015

You might be using python3? In this case. Here are the instructions for building this project from source:

Setup and activate your python3 virtualenv

virtualenv --no-site-packages -p python3 venv_py3
source venv_py3/bin/activate

Install future.

pip3 install future

Clone the repo, checkout the python3 branch, and build the source.

git clone git@github.com:xmunoz/sodapy.git
cd sodapy/
git checkout python3
python3 setup.py install
python3 setup.py install

That last line is not a typo. For some reason you need to install twice, it dies the first time on requests, and succeeds the second time. I don't know why...

Once it's finished, the binaries should be moved into the correct location (in your virtualenv), so you can clean up the source.

cd ..
rm -rf sodapy/

I've been meaning to write this all down for a minute. Thanks for giving me a good reason.

@xmunoz
Copy link
Owner

xmunoz commented Sep 3, 2015

Did this solve your problem @dhmspector?

@dhmspector
Copy link
Author

Yes, it did! Thank you!

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants