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

Installation in virtualenv via pip fails #1190

Closed
raymondEhlers opened this issue May 5, 2020 · 2 comments
Closed

Installation in virtualenv via pip fails #1190

raymondEhlers opened this issue May 5, 2020 · 2 comments
Assignees

Comments

@raymondEhlers
Copy link

raymondEhlers commented May 5, 2020

When trying to install xrootd in a virtualenv on Ubuntu 18.04.4 with python 3.7 via pyenv, the installation fails at the last step with python3.7: command not found.

The abridged error is:

$ pip install xrootd
.......
    -- Installing: /clusterfs4/rehlers/software/pyenv/versions/3.7.6/lib/python3.7/site-packages/pyxrootd/include/xrootd/private/XrdCl/XrdClFileSystemOperations.hh
    ./install.sh: line 35: cd: ../bindings/python: No such file or directory
    pyenv: python3.7: command not found

    The `python3.7' command exists in these Python versions:
      3.7.6

    Note: See 'pyenv help global' for tips on allowing both
          python2 and python3 to be found.
    Traceback (most recent call last):
      File "<string>", line 1, in <module>
      File "/tmp/pip-install-zyixqehl/xrootd/setup.py", line 137, in <module>
        'bdist_wheel': CustomWheelGen
      File "/clusterfs4/rehlers/software/pyenv/versions/3.7.6/lib/python3.7/site-packages/setuptools/__init__.py", line 145, in setup
        return distutils.core.setup(**attrs)
      File "/clusterfs4/rehlers/software/pyenv/versions/3.7.6/lib/python3.7/distutils/core.py", line 148, in setup
        dist.run_commands()
      File "/clusterfs4/rehlers/software/pyenv/versions/3.7.6/lib/python3.7/distutils/dist.py", line 966, in run_commands
        self.run_command(cmd)
      File "/clusterfs4/rehlers/software/pyenv/versions/3.7.6/lib/python3.7/distutils/dist.py", line 985, in run_command
        cmd_obj.run()
      File "/tmp/pip-install-zyixqehl/xrootd/setup.py", line 97, in run
        raise Exception( 'Install step failed!' )
    Exception: Install step failed!
    ----------------------------------------
ERROR: Command errored out with exit status 1: /clusterfs4/rehlers/software/pyenv/versions/3.7.6/bin/python -u -c 'import sys,
setuptools, tokenize; sys.argv[0] = '"'"'/tmp/pip-install-zyixqehl/xrootd/setup.py'"'"'; __file__='"'"'/tmp/pip-install-zyixqeh
l/xrootd/setup.py'"'"';f=getattr(tokenize, '"'"'open'"'"', open)(__file__);code=f.read().replace('"'"'\r\n'"'"', '"'"'\n'"'"');
f.close();exec(compile(code, __file__, '"'"'exec'"'"'))' install --record /tmp/pip-record-mqmugb95/install-record.txt --single-
version-externally-managed --compile Check the logs for full command output.

I added a symlink in env/bin from python3 -> python3.7and then was able to install successfully. Edit: I spoke too soon. With the symlink, I actually get:

    ./install.sh: line 35: cd: ../bindings/python: No such file or directory
    python3.7: can't open file 'setup.py': [Errno 2] No such file or directory

Since I have to use pyenv on this system, I suspected that it might be the underlying issue, but it seems to work with pyenv if I'm not in a virtualenv. Since it fails on changing the directory, I guess it must be related to finding files in the virtualenv.

Thanks!

@raymondEhlers
Copy link
Author

When I install it outside of my virtualenv instead, I get a library issue:

>>> from XRootD import client
Traceback (most recent call last):
  File "<stdin>", line 1, in <module>
  File "/clusterfs4/rehlers/install/lib/python3.7/site-packages/XRootD/client/__init__.py", line 3, in <module>
    from .glob_funcs import glob, iglob
  File "/clusterfs4/rehlers/install/lib/python3.7/site-packages/XRootD/client/glob_funcs.py", line 26, in <module>
    from XRootD.client.filesystem import FileSystem
  File "/clusterfs4/rehlers/install/lib/python3.7/site-packages/XRootD/client/filesystem.py", line 26, in <module>
    from pyxrootd import client
ImportError: libXrdXml.so.2: cannot open shared object file: No such file or directory
>>>

@abh3
Copy link
Member

abh3 commented Nov 19, 2020

I believe this was fixed as part of our Debian focused release.

@abh3 abh3 closed this as completed Nov 19, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

3 participants