Closed mdavezac closed 7 years ago
@daniellefenech to solve this error you need to update setuptools from within casapy
from pip import main as pip
pip(['install', '--user', '--upgrade', 'setuptools'])
Could you check if that solution works on your end? I'm testing it with different environments (linux, mac) and configurations. I will update the documentation accordingly.
Hi @dpshelio, I've tried doing the above, but I'm still getting the same error as posted when I try to install PURIFY.
@daniellefenech - is it exactly the same error? remember to quit and start casapy
after installing setuptools
, also, the above error message suggests you to upgrade pip
too. So I would do:
from pip import main as pip
pip(['install', '--user', '--upgrade', 'pip'])
exit and start casapy again
from pip import main as pip
pip(['install', '--user', '--upgrade', 'setuptools'])
exit and start casapy again, and install purify
.
I would expect you find a different error as I'm getting at the moment, while I'm trying to install it in a system without permissions... something (in the middle of all the traceback) like:
/usr/bin/ld: cannot find -lpython2.7
collect2: ld returned 1 exit status
@dpshelio. Sorry I should have said, I updated pip already. When I tried the code above, I ran it as you suggested, then exited casapy and restarted and then ran the following code to install purify
pip(['install', '--user','-b','/home/dmf/TEMP/','--no-use-wheel','git+https://github.com/astro-informatics/purify.git'])
and my output is the following:
Collecting git+https://github.com/astro-informatics/purify.git
Cloning https://github.com/astro-informatics/purify.git to /tmp/pip-Dpcg8g-build
Username for 'https://github.com': daniellefenech
Password for 'https://daniellefenech@github.com':
Complete output from command python setup.py egg_info:
Traceback (most recent call last):
File "<string>", line 1, in <module>
File "/tmp/pip-Dpcg8g-build/setup.py", line 345, in <module>
long_description=long_description
File "/usr/local/bin/CASA/casa-release-4.5.0-el6/lib/python2.7/distutils/core.py", line 112, in setup
_setup_distribution = dist = klass(attrs)
File "/usr/local/bin/CASA/casa-release-4.5.0-el6/lib/python2.7/site-packages/setuptools/dist.py", line 265, in __init__
self.fetch_build_eggs(attrs.pop('setup_requires'))
File "/usr/local/bin/CASA/casa-release-4.5.0-el6/lib/python2.7/site-packages/setuptools/dist.py", line 289, in fetch_build_eggs
parse_requirements(requires), installer=self.fetch_build_egg
File "/usr/local/bin/CASA/casa-release-4.5.0-el6/lib/python2.7/site-packages/pkg_resources.py", line 631, in resolve
requirements.extend(dist.requires(req.extras)[::-1])
File "/usr/local/bin/CASA/casa-release-4.5.0-el6/lib/python2.7/site-packages/pkg_resources.py", line 2489, in requires
dm = self._dep_map
File "/usr/local/bin/CASA/casa-release-4.5.0-el6/lib/python2.7/site-packages/pkg_resources.py", line 2700, in _dep_map
self.__dep_map = self._compute_dependencies()
File "/usr/local/bin/CASA/casa-release-4.5.0-el6/lib/python2.7/site-packages/pkg_resources.py", line 2733, in _compute_dependencies
common = frozenset(reqs_for_extra(None))
File "/usr/local/bin/CASA/casa-release-4.5.0-el6/lib/python2.7/site-packages/pkg_resources.py", line 2730, in reqs_for_extra
if req.marker_fn(override={'extra':extra}):
File "/usr/local/bin/CASA/casa-release-4.5.0-el6/lib/python2.7/site-packages/_markerlib/markers.py", line 109, in marker_fn
return eval(compiled_marker, environment)
File "<environment marker>", line 1, in <module>
NameError: name 'sys_platform' is not defined
----------------------------------------
Command "python setup.py egg_info" failed with error code 1 in /tmp/pip-Dpcg8g-build
Out[7]: 1
It's possible the error you get is related to the bit of the install to do with cython that I've told it not to do? I can have a try without the '--no-use-wheel' and see if that changes anything.
Okay I tried that and I still get the same error.
Out of scope since we are removing the old python bindings.
Danielle gets this error: