Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

traceback that is seen if casapy is not present as an alias to the CASA.app #6

Open
trhunter opened this issue Apr 10, 2014 · 1 comment

Comments

@trhunter
Copy link

[oakenshield:~/Downloads] thunter% python setup_casapy_pip.py
Traceback (most recent call last):
  File "setup_casapy_pip.py", line 222, in <module>
    python_version = get_python_version_mac()
  File "setup_casapy_pip.py", line 42, in get_python_version_mac
    casapy_path = get_casapy_path()
  File "setup_casapy_pip.py", line 38, in get_casapy_path
    return os.path.realpath(find_executable('casapy'))
  File "/opt/local/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/posixpath.py", line 367, in realpath
    path, ok = _joinrealpath('', filename, {})
  File "/opt/local/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/posixpath.py", line 373, in _joinrealpath
    if isabs(rest):
  File "/opt/local/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/posixpath.py", line 61, in isabs
    return s.startswith('/')
AttributeError: 'NoneType' object has no attribute 'startswith'
[oakenshield:~/Downloads] thunter% which casapy
casapy: Command not found.
@keflavich
Copy link
Contributor

The problem is that casapy isn't found; we should catch this error and report it sensibly. This can happen even if /usr/bin/casapy exists if it is a symlink to a nonexistent location. This bug has occurred at least once (in @trhunter's case) because CASA.app was first run from within the DMG-mounted filesystem (i.e., the thing that comes up if you double-click on a dmg file).

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

No branches or pull requests

2 participants