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

Python fails to install in OpenSuse 15.1 #1957

Closed
kserradell opened this issue Feb 12, 2020 · 8 comments
Closed

Python fails to install in OpenSuse 15.1 #1957

kserradell opened this issue Feb 12, 2020 · 8 comments
Milestone

Comments

@kserradell
Copy link

Python fails to install with this error

== 2020-02-12 15:59:50,754 build_log.py:169 ERROR EasyBuild crashed with an error (at easybuild/opensuse-leap/15.1/x86_64/software/EasyBuild/4.1.1/lib/python2.7/site-packages/easybuild/base/exceptions.py:124 in __init__): cmd " ulimit -s unlimited &&   /shared/earth/easybuild/opensuse-leap/15.1/x86_64/software/Python/2.7.16-GCCcore-8.3.0/bin/python setup.py build " exited with exit code 1 and output:
Could not find platform dependent libraries <exec_prefix>
Consider setting $PYTHONHOME to <prefix>[:<exec_prefix>]
Traceback (most recent call last):
  File "setup.py", line 9, in <module>
    import setuptools
  File "/tmp/eb-build/Python/2.7.16/GCCcore-8.3.0/setuptools/setuptools-41.2.0/setuptools/__init__.py", line 5, in <module>
    import functools
  File "/shared/earth/easybuild/opensuse-leap/15.1/x86_64/software/Python/2.7.16-GCCcore-8.3.0/lib/python2.7/functools.py", line 10, in <module>
    from _functools import partial, reduce
ImportError: No module named _functools
 (at easybuild/opensuse-leap/15.1/x86_64/software/EasyBuild/4.1.1/lib/python2.7/site-packages/easybuild/tools/run.py:529 in parse_cmd_output)

The error is related to this bug.

Workaround from @boegel and @omula

installopts = " && cd %(installdir)s && ln -s ../../lib64/python2.7/lib-dynload lib/python2.7/lib-dynload"
@boegel
Copy link
Member

boegel commented Feb 18, 2020

@kserradell Should be fixed with #1966, please test (you can download the updated easyblock from the PR, and use eb --include-easyblocks python.py to use it).

@kserradell
Copy link
Author

@boegel Of course. I'll try to do it today or tomorrow.

@kserradell
Copy link
Author

@boegel The installation crashes...

eadmin@bscearth408:~> eb Python-2.7.15-GCCcore-8.3.0.eb --include-easyblocks python.py
== temporary log file in case of crash /tmp/eb-UOdSDa/easybuild-8hazZX.log
== processing EasyBuild easyconfig /home/eadmin/Python-2.7.15-GCCcore-8.3.0.eb
== building and installing Python/2.7.15-GCCcore-8.3.0...
== fetching files...
== creating build dir, resetting environment...
== unpacking...
== patching...
== preparing...
== configuring...
== building...
== testing...
== installing...
== taking care of extensions...
== installing extension setuptools 41.2.0 (1/79)...
== installing extension pip 19.2.3 (2/79)...
== installing extension wheel 0.33.6 (3/79)...
== installing extension nose 1.3.7 (4/79)...
== installing extension blist 1.3.6 (5/79)...
== installing extension paycheck 1.0.2 (6/79)...
== installing extension pbr 5.4.3 (7/79)...
== installing extension Cython 0.29.13 (8/79)...
== installing extension six 1.12.0 (9/79)...
== installing extension setuptools_scm 3.3.3 (10/79)...
== installing extension python-dateutil 2.8.0 (11/79)...
== installing extension deap 1.3.0 (12/79)...
== installing extension decorator 4.4.0 (13/79)...
== installing extension liac-arff 2.4.0 (14/79)...
== installing extension pycrypto 2.6.1 (15/79)...
== installing extension ecdsa 0.13.2 (16/79)...
== installing extension enum34 1.1.6 (17/79)...
== installing extension ipaddress 1.0.22 (18/79)...
== installing extension asn1crypto 0.24.0 (19/79)...
== installing extension idna 2.8 (20/79)...
== installing extension pycparser 2.19 (21/79)...
== installing extension cffi 1.12.3 (22/79)...
== installing extension cryptography 2.7 (23/79)...
== installing extension pyasn1 0.4.7 (24/79)...
== installing extension PyNaCl 1.3.0 (25/79)...
== installing extension bcrypt 3.1.7 (26/79)...
== installing extension paramiko 2.6.0 (27/79)...
== installing extension pyparsing 2.4.2 (28/79)...
== installing extension netifaces 0.10.9 (29/79)...
== installing extension netaddr 0.7.19 (30/79)...
== installing extension funcsigs 1.0.2 (31/79)...
== installing extension mock 3.0.5 (32/79)...
== installing extension pytz 2019.2 (33/79)...
== installing extension bitstring 3.1.6 (34/79)...
== installing extension virtualenv 16.7.5 (35/79)...
== installing extension docopt 0.6.2 (36/79)...
== installing extension joblib 0.13.2 (37/79)...
== installing extension chardet 3.0.4 (38/79)...
== installing extension certifi 2019.9.11 (39/79)...
== installing extension urllib3 1.25.3 (40/79)...
== installing extension requests 2.22.0 (41/79)...
== installing extension xlrd 1.2.0 (42/79)...
== installing extension py_expression_eval 0.3.9 (43/79)...
== installing extension tabulate 0.8.3 (44/79)...
== installing extension ujson 1.35 (45/79)...
== installing extension atomicwrites 1.3.0 (46/79)...
== installing extension py 1.8.0 (47/79)...
== installing extension scandir 1.10.0 (48/79)...
== installing extension pathlib2 2.3.4 (49/79)...
== installing extension zipp 0.6.0 (50/79)...
== installing extension configparser 4.0.2 (51/79)...
== installing extension contextlib2 0.5.5 (52/79)...
== installing extension importlib_metadata 0.22 (53/79)...
== installing extension pluggy 0.13.0 (54/79)...
== installing extension more-itertools 5.0.0 (55/79)...
== installing extension attrs 19.1.0 (56/79)...
== installing extension wcwidth 0.1.7 (57/79)...
== installing extension pytest 4.6.5 (58/79)...
== installing extension MarkupSafe 1.1.1 (59/79)...
== installing extension Jinja2 2.10.1 (60/79)...
== installing extension packaging 19.1 (61/79)...
== installing extension sphinxcontrib-websupport 1.1.2 (62/79)...
== installing extension Pygments 2.4.2 (63/79)...
== installing extension imagesize 1.1.0 (64/79)...
== installing extension docutils 0.15.2 (65/79)...
== installing extension snowballstemmer 1.9.1 (66/79)...
== installing extension Babel 2.7.0 (67/79)...
== installing extension alabaster 0.7.12 (68/79)...
== installing extension typing 3.7.4.1 (69/79)...
== installing extension Sphinx 1.8.5 (70/79)...
== installing extension Click 7.0 (71/79)...
== installing extension psutil 5.6.3 (72/79)...
== installing extension future 0.17.1 (73/79)...
== installing extension singledispatch 3.4.0.3 (74/79)...
== installing extension networkx 2.2 (75/79)...
== installing extension saga-python 0.60.1 (76/79)...
== installing extension pydotplus 2.0.2 (77/79)...
== installing extension xxhash 1.4.3 (78/79)...
== installing extension openpyxl 3.0.3 (79/79)...
== FAILED: Installation ended unsuccessfully (build directory: /tmp/eb-build/Python/2.7.15/GCCcore-8.3.0): build failed (first 300 chars): cmd " pip install --prefix=/shared/earth/easybuild/opensuse-leap/15.1/x86_64/software/Python/2.7.15-GCCcore-8.3.0  --no-deps  --ignore-installed  --no-build-isolation  ." exited with exit code 1 and output:
DEPRECATION: Python 2.7 will reach the end of its life on January 1st, 2020. Please upgrade y (took 17 min 48 sec)
== Results of the build can be found in the log file(s) /tmp/eb-UOdSDa/easybuild-Python-2.7.15-20200219.171500.vPlkt.log
ERROR: Build of /home/eadmin/Python-2.7.15-GCCcore-8.3.0.eb failed (err: 'build failed (first 300 chars): cmd " pip install --prefix=/shared/earth/easybuild/opensuse-leap/15.1/x86_64/software/Python/2.7.15-GCCcore-8.3.0  --no-deps  --ignore-installed  --no-build-isolation  ." exited with exit code 1 and output:\nDEPRECATION: Python 2.7 will reach the end of its life on January 1st, 2020. Please upgrade y')

easybuild-Python-2.7.15-20200219.171500.vPlkt.log

@boegel
Copy link
Member

boegel commented Feb 19, 2020

@kserradell I had to fix some import issues that I overlooked in #1966, did you fix those yourself too, or are you using the wrong python.py?

Also, it looks like a different issue now...

Processing /tmp/eb-build/Python/2.7.15/GCCcore-8.3.0/openpyxl/openpyxl-3.0.3
    ERROR: Command errored out with exit status 1:
     command: /shared/earth/easybuild/opensuse-leap/15.1/x86_64/software/Python/2.7.15-GCCcore-8.3.0/bin/python -c 'import sys, setuptools, tokenize; sys.argv[0] = '"'"'/tmp/eb-UOdSDa/pip-req-build-wcUysv/setup.py'"'"'; __file__='"'"'/tmp/eb-UOdSDa/pip-req-build-wcUysv/setup.py'"'"';f=getattr(tokenize, '"'"'open'"'"', open)(__file__);code=f.read().replace('"'"'\r\n'"'"', '"'"'\n'"'"');f.close();exec(compile(code, __file__, '"'"'exec'"'"'))' egg_info --egg-base pip-egg-info
         cwd: /tmp/eb-UOdSDa/pip-req-build-wcUysv/
    Complete output (5 lines):
    Traceback (most recent call last):
      File "<string>", line 1, in <module>
      File "/tmp/eb-UOdSDa/pip-req-build-wcUysv/setup.py", line 28, in <module>
        from importlib.util import module_from_spec, spec_from_file_location
    ImportError: No module named util
    ----------------------------------------
ERROR: Command errored out with exit status 1: python setup.py egg_info Check the logs for full command output.

Do you have an importlib/util.* in your Python installation (/shared/earth/easybuild/opensuse-leap/15.1/x86_64/software/Python/2.7.15-GCCcore-8.3.0)?

@boegel
Copy link
Member

boegel commented Mar 29, 2020

@kserradell Any updates on the last issue?

@boegel
Copy link
Member

boegel commented Apr 7, 2020

re-opening, #1966 is only a partial fix for the issues reported by @kserradell ...

@boegel boegel reopened this Apr 7, 2020
@kserradell
Copy link
Author

Sorry @boegel for my late reply. I'm quite busy in the office with all this mess with the virus. I'll try to take a look as soon as possible.

@boegel boegel added this to the 4.x milestone May 26, 2021
@boegel
Copy link
Member

boegel commented Mar 13, 2022

I was able to install both Python-2.7.18-GCCcore-11.2.0.eb and Python-3.9.6-GCCcore-11.2.0.eb in an openSUSE 15.3 container image using current develop (so somewhere in between EasyBuild v4.5.3 and whatever version is released after that), so this should be good to close...

@boegel boegel closed this as completed Mar 13, 2022
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

2 participants