enhance PythonPackage & PythonBundle easyblock to consider $EBPYTHONPREFIXES for test installs and path configuration files#3953
Conversation
… installs and path configuration files
Hopefully handled by easybuilders/easybuild-easyblocks#3953 Signed-off-by: Jan André Reuter <[email protected]>
|
@boegelbot please test @ jsc-zen3 |
|
@Thyre: Request for testing this PR well received on jsczen3l1.int.jsc-zen3.fz-juelich.de PR test command '
Test results coming soon (I hope)... Details- notification for comment with ID 3391772202 processed Message to humans: this is just bookkeeping information for me, |
|
Test report by @boegelbot Overview of tested easyconfigs (in order)
Build succeeded for 2 out of 2 (2 easyconfigs in total) |
|
@boegel This is the output now for Agreed that this helps. I also applied your other suggestions 👍 |
$EBPYTHONPREFIXES for test installs and path configuration files
(created using
eb --new-pr)There are rare cases where a Python package provides path configuration files to set-up some state for the package to work correctly. One such example was recently encountered in easybuilders/easybuild-easyconfigs#24081:
numba-cuda.Numba has deprecated their CUDA bindings. Instead, NVIDIA provides bindings which hook into
numba. The installation is entirely separate. However, they provide a path configuration file (.pth) which basically overwrites the include fornumba.cuda.Typically, these files only work when they are in a system directory checked by Python. This is the case in a
venvor in a user/system wide installation. In EasyBuild however, this fails. Writing our ownsitecustomize.pyfornumba-cudawould shadow the one provided in EasyBuild. For this to work, we requireEBPYTHONPREFIXES, as oursitecustomize.pyadds the directories to the site dir, therefore being considered by Pythoneasybuild-easyblocks/easybuild/easyblocks/p/python.py
Lines 114 to 117 in 2e5a227
This PR implements these changes:
EBPYTHONPREFIXESinto its own functionusing_ebpythonprefixesmake_module_extraandtest_stepto check if we needEBPYTHONPREFIXES.Marked as draft until I was able to verify that these changes work. Unfortunately, none of my systems are using
EBPYTHONPREFIXES, making test reports like easybuilders/easybuild-easyconfigs#24081 (comment) harder to reproduce.