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

[bugfix] Upgrade pip before pip-installing reframe for CPU autodetection #3025

Merged

Conversation

vkarak
Copy link
Contributor

@vkarak vkarak commented Oct 20, 2023

Closes #3023.

@casparvl Could you test if this work for your case?

@codecov
Copy link

codecov bot commented Oct 20, 2023

Codecov Report

All modified and coverable lines are covered by tests ✅

Comparison is base (314ef82) 86.70% compared to head (81f1d96) 86.70%.
Report is 1 commits behind head on master.

Additional details and impacted files
@@           Coverage Diff           @@
##           master    #3025   +/-   ##
=======================================
  Coverage   86.70%   86.70%           
=======================================
  Files          61       61           
  Lines       11996    11996           
=======================================
  Hits        10401    10401           
  Misses       1595     1595           
Files Coverage Δ
reframe/frontend/autodetect.py 56.25% <ø> (ø)

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

@casparvl
Copy link

Works like a charm for me!

Detecting topology of remote partition 'Magic_Castle:aarch64-neoverse-N1-16c-32gb': this may take some time...
submitting detection script
--- /home/casparvl/test-suite/CI/rfm.dra1x0fe/rfm-detect-job.sh ---
#!/bin/bash
#SBATCH --job-name="rfm-detect-job"
#SBATCH --ntasks=1
#SBATCH --output=rfm-detect-job.out
#SBATCH --error=rfm-detect-job.err
#SBATCH --partition=aarch64-neoverse-n1-node
#SBATCH --export=NONE

_onerror()
{
    exitcode=$?
    echo "-reframe: command \`$BASH_COMMAND' failed (exit code: $exitcode)"
    exit $exitcode
}

trap _onerror ERR

python3 -m venv venv.reframe
source venv.reframe/bin/activate
pip install --upgrade pip
pip install reframe-hpc==4.4.0
reframe --detect-host-topology=topo.json
deactivate
...
--- /home/casparvl/test-suite/CI/rfm.dra1x0fe/rfm-detect-job.out ---
Collecting pip
  Using cached https://files.pythonhosted.org/packages/a4/6d/6463d49a933f547439d6b5b98b46af8742cc03ae83543e4d7688c2420f8b/pip-21.3.1-py3-none-any.whl
Installing collected packages: pip
  Found existing installation: pip 9.0.3
    Uninstalling pip-9.0.3:
      Successfully uninstalled pip-9.0.3
Successfully installed pip-21.3.1
Collecting reframe-hpc==4.4.0
  Downloading ReFrame_HPC-4.4.0-py3-none-any.whl (286 kB)
Collecting jsonschema
  Using cached jsonschema-3.2.0-py2.py3-none-any.whl (56 kB)
Collecting PyYAML
  Using cached PyYAML-6.0.1-cp36-cp36m-manylinux_2_17_aarch64.manylinux2014_aarch64.whl (669 kB)
Collecting requests
  Using cached requests-2.27.1-py2.py3-none-any.whl (63 kB)
Collecting lxml
  Using cached lxml-4.9.3-cp36-cp36m-manylinux_2_17_aarch64.manylinux2014_aarch64.whl (7.1 MB)
Collecting semver
  Using cached semver-2.13.0-py2.py3-none-any.whl (12 kB)
Collecting archspec
  Using cached archspec-0.2.1-py3-none-any.whl (53 kB)
Collecting argcomplete
  Using cached argcomplete-3.1.2-py3-none-any.whl (41 kB)
Collecting importlib-metadata<7,>=0.23
  Using cached importlib_metadata-4.8.3-py3-none-any.whl (17 kB)
Collecting pyrsistent>=0.14.0
  Using cached pyrsistent-0.18.0-cp36-cp36m-linux_aarch64.whl
Requirement already satisfied: setuptools in ./venv.reframe/lib/python3.6/site-packages (from jsonschema->reframe-hpc==4.4.0) (39.2.0)
Collecting attrs>=17.4.0
  Using cached attrs-22.2.0-py3-none-any.whl (60 kB)
Collecting six>=1.11.0
  Using cached six-1.16.0-py2.py3-none-any.whl (11 kB)
Collecting urllib3<1.27,>=1.21.1
  Using cached urllib3-1.26.18-py2.py3-none-any.whl (143 kB)
Collecting charset-normalizer~=2.0.0
  Using cached charset_normalizer-2.0.12-py3-none-any.whl (39 kB)
Collecting idna<4,>=2.5
  Using cached idna-3.4-py3-none-any.whl (61 kB)
Collecting certifi>=2017.4.17
  Using cached certifi-2023.7.22-py3-none-any.whl (158 kB)
Collecting typing-extensions>=3.6.4
  Using cached typing_extensions-4.1.1-py3-none-any.whl (26 kB)
Collecting zipp>=0.5
  Using cached zipp-3.6.0-py3-none-any.whl (5.3 kB)
Installing collected packages: zipp, typing-extensions, urllib3, six, pyrsistent, importlib-metadata, idna, charset-normalizer, certifi, attrs, semver, requests, PyYAML, lxml, jsonschema, arg
complete, archspec, reframe-hpc
Successfully installed PyYAML-6.0.1 archspec-0.2.1 argcomplete-3.1.2 attrs-22.2.0 certifi-2023.7.22 charset-normalizer-2.0.12 idna-3.4 importlib-metadata-4.8.3 jsonschema-3.2.0 lxml-4.9.3 pyr
sistent-0.18.0 reframe-hpc-4.4.0 requests-2.27.1 semver-2.13.0 six-1.16.0 typing-extensions-4.1.1 urllib3-1.26.18 zipp-3.6.0
--- /home/casparvl/test-suite/CI/rfm.dra1x0fe/rfm-detect-job.err ---
Cache entry deserialization failed, entry ignored
You are using pip version 21.3.1, however version 23.3.1 is available.
You should consider upgrading via the 'pip install --upgrade pip' command.

--- /home/casparvl/test-suite/CI/rfm.dra1x0fe/rfm-detect-job.err ---
saved topology in '/home/casparvl/.reframe/topology/Magic_Castle-aarch64-neoverse-N1-16c-32gb/processor.json'

Not entirely sure why it seems to have upgraded to 21.3.1 and then mentions 23.3.1 is available, but... well. It gives at least a recent pip and my original issue is resolved :)

@vkarak
Copy link
Contributor Author

vkarak commented Oct 23, 2023

Not entirely sure why it seems to have upgraded to 21.3.1 and then mentions 23.3.1 is available, but... well. It gives at least a recent pip and my original issue is resolved :)

I've seen that too, I will try updating as follows:

python -m pip install --upgrade pip

@vkarak
Copy link
Contributor Author

vkarak commented Oct 23, 2023

Even with the second approach, the second upgrade message is issues. So leaving it as it is now.

@vkarak vkarak merged commit 7dd781b into reframe-hpc:master Oct 23, 2023
18 checks passed
@vkarak vkarak deleted the enhancement/upgrade-pip-autodetect branch October 23, 2023 20:25
@vkarak vkarak linked an issue Oct 23, 2023 that may be closed by this pull request
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
Status: Done
Development

Successfully merging this pull request may close these issues.

CPU autodetect failing due to failing pip install reframe-hpc==4.3.3
3 participants