Skip to content

is there any way to make this scheme work with a virtual python environment? #10

@trhunter

Description

@trhunter

Would it be possible to be able to import astropy into CASA in the following situation, which is what I have on my NRAO workstation:

  1. casa is installed at /usr/bin/casapy, and owned by root
  2. python is installed at /usr/local/bin/python2.7, and owned by root
  3. virtualenv installed in my area and owned by me, and set up such that the python I get is python2.7
[venv] [thunter@yildun ~]$ which python
/users/thunter/venv/bin/python

I then hacked setup_casapy_pip.py sot that it can find my virtual python, but then it fails later at this point:

[venv] [thunter@yildun ~]$ python setup_casapy_pip.py
Determined Python version in CASA... 2.7
Creating casa-python script...
Downloading setuptools...
Installing setuptools...
setuptools-3.4.3/
...
setuptools-3.4.3/_markerlib/markers.py
setuptools-3.4.3/_markerlib/__init__.py
/users/thunter/.casa/bin/casa-python: line 17: /users/thunter/venv//lib64/casapy/bin/python: No such file or directory
/users/thunter/.casa/bin/casa-python: line 17: exec: /users/thunter/venv//lib64/casapy/bin/python: cannot execute: No such file or directory
Traceback (most recent call last):
  File "setup_casapy_pip.py", line 261, in <module>
    url=SETUPTOOLS_URL, md5_checksum=SETUPTOOLS_MD5)
  File "setup_casapy_pip.py", line 139, in install_package
    raise SystemError("{0} installation failed!".format(packagename))
SystemError: setuptools installation failed!

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions