Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
107 commits
Select commit Hold shift + click to select a range
708e131
Specifying False for a version removes the dep
edmondac Nov 27, 2020
81bcf13
handle different types of dependecy (tuple, dict, ...)
edmondac Nov 27, 2020
11aa3fe
tame hound
edmondac Nov 27, 2020
52bc90e
Update easybuild/framework/easyconfig/easyconfig.py
edmondac Jan 4, 2021
dc9d1d7
Add create_unused_dir to create a directory which does not yet exist
Flamefire Jan 22, 2021
73055d0
Avoid module use in LMod if possible to allow faster execution
Flamefire Feb 2, 2021
e30995a
Create CUDA cache (for JIT compiled PTX code) in build dir instead of…
Flamefire Feb 8, 2021
26b0ef0
Fix test_prefix_option not being run
Flamefire Feb 9, 2021
2a15533
Limit amount of attempts and test error conditions
Flamefire Feb 15, 2021
2f079a6
Change unit of cuda-cache-size to MiB and add cuda_cache_dir
Flamefire Feb 15, 2021
3f84e06
fix BLAS_LIB_MT for OpenBLAS
Feb 20, 2021
f12e4d9
fix test
Feb 20, 2021
21b1a70
Merge pull request #3584 from smoors/20210220112115_new_pr_TrqhoKkfqv
akesandgren Feb 22, 2021
95442b4
Merge pull request #3506 from bear-rsg/disable-dep-with-version-false
akesandgren Feb 22, 2021
53e560c
bump version to 4.3.4dev
boegel Feb 23, 2021
96bff22
fix typo in release notes
boegel Feb 23, 2021
90f41d6
Merge pull request #3591 from boegel/develop
akesandgren Feb 24, 2021
99a95fa
add pick_default_branch function to clean up duplicate code in tools/…
boegel Feb 24, 2021
58061a9
Merge pull request #3592 from boegel/pick_default_branch
akesandgren Feb 24, 2021
f854941
use '--opt=val' for passing settings from config file to option parse…
boegel Feb 25, 2021
35c6a98
Merge pull request #3594 from boegel/fix_cfgfile_dash_option
wpoely86 Feb 25, 2021
b7f4835
Add "Citing" section to module files
Feb 25, 2021
c71c13e
Clean up formatting
Feb 25, 2021
78fecef
Update module fulltxt test
Feb 25, 2021
5b9c014
Fix too much underlining
Feb 25, 2021
a935247
avoid raised exception when getting output from interactive command i…
boegel Feb 25, 2021
719063b
Merge pull request #3599 from boegel/run_cmd_qa_fix
vanzod Feb 25, 2021
2bdf602
add test to check behaviour for dependencies with False version
boegel Mar 1, 2021
7ba5c4f
add support for using fallback 'arch=*' key in dependency version spe…
boegel Mar 1, 2021
257df8e
extend test for dependencies with False version to cover use of 'arch=*'
boegel Mar 1, 2021
5c1cfc6
improve error message for pick_dep_version + check error handling in …
boegel Mar 1, 2021
a86e314
actually control arch we check with in test_false_dep_version
boegel Mar 1, 2021
bc42f6f
Merge pull request #3596 from ocaisa/cite
bartoldeman Mar 3, 2021
37d90d9
ensure sorted keys in error message produced by pick_dep_version
boegel Mar 3, 2021
3c1eb7f
fix order of builddependencies vs dependencies in test easyconfig in …
boegel Mar 3, 2021
00b1c75
Merge pull request #3600 from boegel/false_dep
akesandgren Mar 4, 2021
98f7829
also check for pending change requests in check_pr_eligible_to_merge
migueldiascosta Mar 9, 2021
0697c2c
also check mergeable_state in check_pr_eligible_to_merge
migueldiascosta Mar 9, 2021
ca330ea
Merge pull request #3604 from migueldiascosta/check_reviews_in_merge_pr
boegel Mar 11, 2021
ca29ca9
ignore undismissed 'changes requested' review if there is an 'approve…
migueldiascosta Mar 11, 2021
963d6f1
Merge pull request #3607 from migueldiascosta/ignore_undismissed_revi…
boegel Mar 12, 2021
8cb4f40
filter duplicates in changes_requested_by
migueldiascosta Mar 12, 2021
ee06900
Merge pull request #3608 from migueldiascosta/filter_duplicates_in_ch…
boegel Mar 12, 2021
987599c
Sort output of eb --search in natural order (respecting numbers)
Flamefire Mar 12, 2021
5f76976
Add utilities_test.py
Flamefire Mar 12, 2021
9b23d0c
Add test for natural_keys
Flamefire Mar 12, 2021
e8d859d
Don't load index when it is ignored
Flamefire Mar 12, 2021
e1f744e
Avoid additional work handling the common prefix of paths
Flamefire Mar 12, 2021
724b8a9
add tests for 'eb' command
boegel Mar 9, 2021
b9af38c
enhance 'eb' command to ensure that easybuild.main can be imported be…
boegel Mar 14, 2021
d6fd180
Merge pull request #3610 from boegel/eb_enhancements
akesandgren Mar 15, 2021
dbf9d28
include utilities_test subsuite in overall test suite (+ trivial code…
boegel Mar 16, 2021
644dcd9
Merge pull request #3609 from Flamefire/naturalSortSearch
boegel Mar 16, 2021
4929b7b
added configuration option to define the env command to use for shebangs
mboisson Mar 16, 2021
00f8e79
removed extra blank line
mboisson Mar 16, 2021
ccde372
reuse DEFAULT_ENV_FOR_SHEBANG
mboisson Mar 16, 2021
4a498d9
pass custom env command in test_fix_shebang via --env-for-shebang com…
boegel Mar 16, 2021
babe523
Merge pull request #24 from boegel/configurable_env_for_shebang
mboisson Mar 16, 2021
4038b80
Merge pull request #3613 from ComputeCanada/configurable_env_for_shebang
boegel Mar 16, 2021
16d19bc
Add option to write file from file-like object and use in download_file
Flamefire Mar 17, 2021
d32e203
make sure we copy the entire file when a file-like object is passed t…
boegel Mar 17, 2021
401cdd3
let caller decide whether or not to copy whole file + determine wheth…
boegel Mar 17, 2021
1d502d5
Merge pull request #3614 from Flamefire/downloadFileChunked
boegel Mar 17, 2021
824f37d
Refactor the CI script to use inclusion instead of exclusion
Flamefire Mar 18, 2021
af0b3b6
bump to latest Lmod in test suite configurations
boegel Mar 18, 2021
1b23831
Avoid repetition of module tool versions
Flamefire Mar 19, 2021
3fef34c
Make sure that path to eb is always found by tests
Mar 19, 2021
8ee9b92
Tweak test that actually checks EB_SCRIPT_PATH
Mar 19, 2021
d68a495
Improve comment
Mar 19, 2021
8999ed1
Add/Improve comments
Flamefire Mar 22, 2021
6a5fca3
Merge pull request #3617 from ocaisa/set-EB_SCRIPT_PATH-in_tests
bartoldeman Mar 23, 2021
c3674a8
Add templates for architecture independent Python wheels
Flamefire Mar 24, 2021
c26e302
Show the easyblocks repo and PR number when uploading a test report a…
Flamefire Mar 29, 2021
f5f9c12
Handle errors on delete and reduce default verbosity
Flamefire Mar 29, 2021
4aac576
Don't overwrite default log level
Flamefire Mar 29, 2021
f215ae5
Merge pull request #3616 from Flamefire/improve_gha
boegel Mar 31, 2021
90bbe8c
Merge branch 'develop' into whlTemplates
boegel Apr 5, 2021
245e67a
Merge branch 'develop' into improveGists
boegel Apr 5, 2021
40ff9dd
fix typo in docstring of goblf toolchain definition
boegel Apr 5, 2021
56dcefa
use develop branch when testing push access in --check-github (fixes …
boegel Apr 5, 2021
ff05a37
deprecate --accept-eula, rename to --accept-eula-for
boegel Apr 5, 2021
c33acc2
add support for using regular expression pattern to speicfy software …
boegel Apr 5, 2021
7c3c13f
Merge pull request #3628 from boegel/goblf_fix_typo
akesandgren Apr 5, 2021
4012ecb
rename eb_pr_nrs to easyblock_pr_nrs
boegel Apr 5, 2021
da38b85
Merge branch 'develop' into cuda_cache
boegel Apr 5, 2021
01bcca0
rename setup_cuda_cache method to set_up_cuda_cache + minor tweaks to…
boegel Apr 5, 2021
ed0d6ae
Merge branch 'develop' into create_unused_dir
boegel Apr 5, 2021
14b99ef
flesh out duplicate code from mkdir and create_unused_dir functions i…
boegel Apr 5, 2021
832010c
Merge branch 'develop' into avoid_module_use
boegel Apr 5, 2021
5293218
extend test for 'module use', also test 'module unuse'
boegel Apr 5, 2021
a45763f
also load module when testing use/unuse
boegel Apr 5, 2021
89ca410
Merge pull request #3630 from boegel/accept_eula_for
Micket Apr 5, 2021
568dca1
Merge pull request #3618 from Flamefire/whlTemplates
boegel Apr 5, 2021
aded444
Merge pull request #3622 from Flamefire/improveGists
boegel Apr 5, 2021
aea60d7
Merge pull request #3569 from Flamefire/cuda_cache
boegel Apr 5, 2021
9082054
Merge pull request #3551 from Flamefire/create_unused_dir
boegel Apr 5, 2021
89a1808
Merge pull request #3557 from Flamefire/avoid_module_use
boegel Apr 5, 2021
15f1d82
Merge pull request #3629 from boegel/check_github_develop
migueldiascosta Apr 6, 2021
5509a09
update validate_github_token function to accept GitHub token in new f…
boegel Apr 6, 2021
b5e154c
Avoid module call for unuse() for LMod and set $MODULEPATH directly
Flamefire Apr 6, 2021
3262fc6
Add test for adding to non-existing MODULEPATH and removing it
Flamefire Apr 6, 2021
21083d3
Test special cases for LMod only
Flamefire Apr 6, 2021
57b59bf
Merge pull request #3632 from boegel/github_token_new_format
Apr 6, 2021
b7fcb79
Merge pull request #3633 from Flamefire/mlUnuse
boegel Apr 6, 2021
34a6c85
prepare release notes for EasyBuild v4.3.4 + bump version to 4.3.4
migueldiascosta Apr 7, 2021
2dc85b4
tweak framework release notes for EasyBuild v4.3.4
boegel Apr 7, 2021
cdb4bf4
Merge pull request #3635 from migueldiascosta/eb434
boegel Apr 7, 2021
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
88 changes: 88 additions & 0 deletions .github/workflows/eb_command.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,88 @@
# documentation: https://help.github.com/en/articles/workflow-syntax-for-github-actions
name: Tests for the 'eb' command
on: [push, pull_request]
jobs:
test-eb:
runs-on: ubuntu-18.04
strategy:
matrix:
python: [2.7, 3.5, 3.6, 3.7, 3.8, 3.9]
fail-fast: false
steps:
- uses: actions/checkout@v2

- name: set up Python
uses: actions/setup-python@v2
with:
python-version: ${{matrix.python}}
architecture: x64

- name: install OS & Python packages
run: |
# check Python version
python -V
# update to latest pip, check version
pip install --upgrade pip
pip --version
# install packages required for modules tool
sudo apt-get install lua5.2 liblua5.2-dev lua-filesystem lua-posix tcl tcl-dev
# fix for lua-posix packaging issue, see https://bugs.launchpad.net/ubuntu/+source/lua-posix/+bug/1752082
# needed for Ubuntu 18.04, but not for Ubuntu 20.04, so skipping symlinking if posix.so already exists
if [ ! -e /usr/lib/x86_64-linux-gnu/lua/5.2/posix.so ] ; then
sudo ln -s /usr/lib/x86_64-linux-gnu/lua/5.2/posix_c.so /usr/lib/x86_64-linux-gnu/lua/5.2/posix.so
fi

- name: install modules tool
run: |
# avoid downloading modules tool sources into easybuild-framework dir
cd $HOME
export INSTALL_DEP=$GITHUB_WORKSPACE/easybuild/scripts/install_eb_dep.sh
# install Lmod
source $INSTALL_DEP Lmod-8.4.26 $HOME
# changes in environment are not passed to other steps, so need to create files...
echo $MOD_INIT > mod_init
echo $PATH > path
if [ ! -z $MODULESHOME ]; then echo $MODULESHOME > moduleshome; fi

- name: install EasyBuild framework
run: |
# install from source distribution tarball, to test release as published on PyPI
python setup.py sdist
ls dist
export PREFIX=/tmp/$USER/$GITHUB_SHA
pip install --prefix $PREFIX dist/easybuild-framework*tar.gz

- name: run tests for 'eb' command
env:
EB_VERBOSE: 1
run: |
# run tests *outside* of checked out easybuild-framework directory,
# to ensure we're testing installed version (see previous step)
cd $HOME
# initialize environment for modules tool
if [ -f $HOME/moduleshome ]; then export MODULESHOME=$(cat $HOME/moduleshome); fi
source $(cat $HOME/mod_init); type module
# make sure 'eb' is available via $PATH, and that $PYTHONPATH is set (some tests expect that);
# also pick up changes to $PATH set by sourcing $MOD_INIT
export PREFIX=/tmp/$USER/$GITHUB_SHA
export PATH=$PREFIX/bin:$(cat $HOME/path)
export PYTHONPATH=$PREFIX/lib/python${{matrix.python}}/site-packages:$PYTHONPATH
# run --version, capture (verbose) output
eb --version | tee eb_version.out 2>&1
# determine active Python version
pymajver=$(python -c 'import sys; print(sys.version_info[0])')
pymajminver=$(python -c 'import sys; print(".".join(str(x) for x in sys.version_info[:2]))')
# check patterns in verbose output
for pattern in "^>> Considering .python.\.\.\." "^>> .python. version: ${pymajminver}\.[0-9]\+, which matches Python ${pymajver} version requirement" "^>> 'python' is able to import 'easybuild.main', so retaining it" "^>> Selected Python command: python \(.*/bin/python\)" "^This is EasyBuild 4\.[0-9.]\+"; do
echo "Looking for pattern \"${pattern}\" in eb_version.out..."
grep "$pattern" eb_version.out
done
# also check when specifying Python command via $EB_PYTHON
for eb_python in "python${pymajver}" "python${pymajminver}"; do
export EB_PYTHON="${eb_python}"
eb --version | tee eb_version.out 2>&1
for pattern in "^>> Considering .${eb_python}.\.\.\." "^>> .${eb_python}. version: ${pymajminver}\.[0-9]\+, which matches Python ${pymajver} version requirement" "^>> '${eb_python}' is able to import 'easybuild.main', so retaining it" "^>> Selected Python command: ${eb_python} \(.*/bin/${eb_python}\)" "^This is EasyBuild 4\.[0-9.]\+"; do
echo "Looking for pattern \"${pattern}\" in eb_version.out..."
grep "$pattern" eb_version.out
done
done
95 changes: 52 additions & 43 deletions .github/workflows/unit_tests.yml
Original file line number Diff line number Diff line change
Expand Up @@ -2,61 +2,70 @@
name: EasyBuild framework unit tests
on: [push, pull_request]
jobs:
setup:
runs-on: ubuntu-latest
outputs:
lmod7: Lmod-7.8.22
lmod8: Lmod-8.4.27
modulesTcl: modules-tcl-1.147
modules3: modules-3.2.10
modules4: modules-4.1.4
steps:
- run: "true"
build:
needs: setup
runs-on: ubuntu-18.04
strategy:
matrix:
python: [2.7, 3.5, 3.6, 3.7, 3.8, 3.9]
modules_tool: [Lmod-7.8.22, Lmod-8.2.9, modules-tcl-1.147, modules-3.2.10, modules-4.1.4]
python: [2.7, 3.6]
modules_tool:
# use variables defined by 'setup' job above, see also
# https://docs.github.com/en/actions/reference/context-and-expression-syntax-for-github-actions#needs-context
- ${{needs.setup.outputs.lmod7}}
- ${{needs.setup.outputs.lmod8}}
- ${{needs.setup.outputs.modulesTcl}}
- ${{needs.setup.outputs.modules3}}
- ${{needs.setup.outputs.modules4}}
module_syntax: [Lua, Tcl]
lc_all: [""]
# exclude some configuration for non-Lmod modules tool:
# - don't test with Lua module syntax (only supported in Lmod)
# - exclude Python 3.x versions other than 3.6, to limit test configurations
# don't test with Lua module syntax (only supported in Lmod)
exclude:
- modules_tool: modules-tcl-1.147
- modules_tool: ${{needs.setup.outputs.modulesTcl}}
module_syntax: Lua
- modules_tool: modules-3.2.10
- modules_tool: ${{needs.setup.outputs.modules3}}
module_syntax: Lua
- modules_tool: modules-4.1.4
- modules_tool: ${{needs.setup.outputs.modules4}}
module_syntax: Lua
- modules_tool: modules-tcl-1.147
python: 3.5
- modules_tool: modules-tcl-1.147
python: 3.7
- modules_tool: modules-tcl-1.147
python: 3.8
- modules_tool: modules-tcl-1.147
python: 3.9
- modules_tool: modules-3.2.10
python: 3.5
- modules_tool: modules-3.2.10
python: 3.7
- modules_tool: modules-3.2.10
python: 3.8
- modules_tool: modules-3.2.10
python: 3.9
- modules_tool: modules-4.1.4
python: 3.5
- modules_tool: modules-4.1.4
python: 3.7
- modules_tool: modules-4.1.4
python: 3.8
- modules_tool: modules-4.1.4
python: 3.9
- modules_tool: Lmod-7.8.22
python: 3.5
- modules_tool: Lmod-7.8.22
python: 3.7
- modules_tool: Lmod-7.8.22
python: 3.8
- modules_tool: Lmod-7.8.22
python: 3.9
# There may be encoding errors in Python 3 which are hidden when an UTF-8 encoding is set
# Hence run the tests (again) with LC_ALL=C and Python 3.6 (or any < 3.7)
include:
# Test different Python 3 versions with Lmod 8.x (with both Lua and Tcl module syntax)
- python: 3.5
modules_tool: ${{needs.setup.outputs.lmod8}}
module_syntax: Lua
- python: 3.5
modules_tool: ${{needs.setup.outputs.lmod8}}
module_syntax: Tcl
- python: 3.7
modules_tool: ${{needs.setup.outputs.lmod8}}
module_syntax: Lua
- python: 3.7
modules_tool: ${{needs.setup.outputs.lmod8}}
module_syntax: Tcl
- python: 3.8
modules_tool: ${{needs.setup.outputs.lmod8}}
module_syntax: Lua
- python: 3.8
modules_tool: ${{needs.setup.outputs.lmod8}}
module_syntax: Tcl
- python: 3.9
modules_tool: ${{needs.setup.outputs.lmod8}}
module_syntax: Lua
- python: 3.9
modules_tool: ${{needs.setup.outputs.lmod8}}
module_syntax: Tcl
# There may be encoding errors in Python 3 which are hidden when an UTF-8 encoding is set
# Hence run the tests (again) with LC_ALL=C and Python 3.6 (or any < 3.7)
- python: 3.6
modules_tool: Lmod-8.2.9
modules_tool: ${{needs.setup.outputs.lmod8}}
module_syntax: Lua
lc_all: C
fail-fast: false
Expand Down
37 changes: 36 additions & 1 deletion RELEASE_NOTES
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,40 @@ For more detailed information, please see the git log.
These release notes can also be consulted at https://easybuild.readthedocs.io/en/latest/Release_notes.html.


v4.3.4 (April 9th 2021)
-----------------------

update/bugfix release

- various enhancements, including:
- add support for filtering dependencies by using False as version (#3506)
- add create_unused_dir function to create a directory which does not yet exist (#3551)
- avoid running expensive 'module use' and 'module unuse' commands when using Lmod as modules tool, update $MODULEPATH directly instead (#3557, #3633)
- create CUDA cache (for JIT compiled PTX code) in build dir instead of $HOME (#3569)
- add "Citing" section to module files (#3596)
- add support for using fallback 'arch=*' key in dependency version specified as arch->version mapping (#3600)
- also check for pending change requests and mergeable_state in check_pr_eligible_to_merge (#3604)
- ignore undismissed 'changes requested' review if there is an 'approved' review by the same user (#3607, #3608)
- sort output of 'eb --search' in natural order (respecting numbers) (#3609)
- enhance 'eb' command to ensure that easybuild.main can be imported before settling on python* command to use (#3610)
- add --env-for-shebang configuration option to define the env command to use for shebangs (#3613)
- add templates for architecture independent Python wheels (#3618)
- mention easyblocks PR in gist when uploading test report for it + fix clean_gists.py script (#3622)
- also accept regular expression value for --accept-eula-for (#3630)
- update validate_github_token function to accept GitHub token in new format (#3632)
- various bug fixes, including:
- fix $BLAS_LIB_MT for OpenBLAS, ensure -lpthread is included (#3584)
- use '--opt=val' for passing settings from config file to option parser to avoid error for values starting with '-' or '--' (#3594)
- avoid raised exception when getting output from interactive command in run_cmd_qa (#3599)
- add option to write file from file-like object and use in download_file (#3614)
- make sure that path to eb is always found by tests (#3617)
- other changes:
- add pick_default_branch function to clean up duplicate code in tools/github.py (#3592)
- refactor the CI configuration to use inclusion instead of exclusion (#3616)
- use develop branch when testing push access in --check-github (#3629)
- deprecate --accept-eula, rename to --accept-eula-for (#3630)


v4.3.3 (February 23rd 2021)
---------------------------

Expand All @@ -17,7 +51,7 @@ update/bugfix release
- detect 'SYSTEM' toolchain as special case in easystack files (#3543)
- enhance extract_cmd function to use 'cp -a' for shell scripts (.sh) (#3545)
- allow use of alternate envvar(s) to $HOME for user modules (#3558)
- use https://sources/easybuild.io as fallback source URL (#3572, #3576)
- use https://sources.easybuild.io as fallback source URL (#3572, #3576)
- add toolchain definition for iibff toolchain (#3574)
- add %(cuda_cc_space_sep)s and %(cuda_cc_semicolon_sep)s templates (#3578)
- add support for intel-compiler toolchain (>= 2021.x versions, oneAPI) (#3581, #3582)
Expand All @@ -34,6 +68,7 @@ update/bugfix release
- other changes:
- rename EasyBlock._skip_step to EasyBlock.skip_step, to make it part of the public API (#3561)
- make symlinking of posix_c.so to posix.so in test suite configuration conditional (#3570)
- use 'main' rather than 'master' branch in GitHub integration functionality (#3589)


v4.3.2 (December 10th 2020)
Expand Down
3 changes: 1 addition & 2 deletions easybuild/base/generaloption.py
Original file line number Diff line number Diff line change
Expand Up @@ -1376,8 +1376,7 @@ def parseconfigfiles(self):
configfile_values[opt_dest] = newval
else:
configfile_cmdline_dest.append(opt_dest)
configfile_cmdline.append("--%s" % opt_name)
configfile_cmdline.append(val)
configfile_cmdline.append("--%s=%s" % (opt_name, val))

# reparse
self.log.debug('parseconfigfiles: going to parse options through cmdline %s' % configfile_cmdline)
Expand Down
33 changes: 29 additions & 4 deletions easybuild/framework/easyblock.py
Original file line number Diff line number Diff line change
Expand Up @@ -1034,6 +1034,27 @@ def make_dir(self, dir_name, clean, dontcreateinstalldir=False):

mkdir(dir_name, parents=True)

def set_up_cuda_cache(self):
"""Set up CUDA PTX cache."""

cuda_cache_maxsize = build_option('cuda_cache_maxsize')
if cuda_cache_maxsize is None:
cuda_cache_maxsize = 1 * 1024 # 1 GiB default value
else:
cuda_cache_maxsize = int(cuda_cache_maxsize)

if cuda_cache_maxsize == 0:
self.log.info("Disabling CUDA PTX cache since cache size was set to zero")
env.setvar('CUDA_CACHE_DISABLE', '1')
else:
cuda_cache_dir = build_option('cuda_cache_dir')
if not cuda_cache_dir:
cuda_cache_dir = os.path.join(self.builddir, 'eb-cuda-cache')
self.log.info("Enabling CUDA PTX cache of size %s MiB at %s", cuda_cache_maxsize, cuda_cache_dir)
env.setvar('CUDA_CACHE_DISABLE', '0')
env.setvar('CUDA_CACHE_PATH', cuda_cache_dir)
env.setvar('CUDA_CACHE_MAXSIZE', str(cuda_cache_maxsize * 1024 * 1024))

#
# MODULE UTILITY FUNCTIONS
#
Expand Down Expand Up @@ -1655,8 +1676,8 @@ def check_accepted_eula(self, name=None, more_info=None):
if name is None:
name = self.name

accepted_eulas = build_option('accept_eula') or []
if self.cfg['accept_eula'] or name in accepted_eulas:
accepted_eulas = build_option('accept_eula_for') or []
if self.cfg['accept_eula'] or name in accepted_eulas or any(re.match(x, name) for x in accepted_eulas):
self.log.info("EULA for %s is accepted", name)
else:
error_lines = [
Expand All @@ -1667,7 +1688,7 @@ def check_accepted_eula(self, name=None, more_info=None):

error_lines.extend([
"You should either:",
"- add --accept-eula=%(name)s to the 'eb' command;",
"- add --accept-eula-for=%(name)s to the 'eb' command;",
"- update your EasyBuild configuration to always accept the EULA for %(name)s;",
"- add 'accept_eula = True' to the easyconfig file you are using;",
'',
Expand Down Expand Up @@ -2163,6 +2184,10 @@ def prepare_step(self, start_dir=True, load_tc_deps_modules=True):
self.log.info("Loading extra modules: %s", extra_modules)
self.modules_tool.load(extra_modules)

# Setup CUDA cache if required. If we don't do this, CUDA will use the $HOME for its cache files
if get_software_root('CUDA') or get_software_root('CUDAcore'):
self.set_up_cuda_cache()

# guess directory to start configure/build/install process in, and move there
if start_dir:
self.guess_start_dir()
Expand Down Expand Up @@ -2367,7 +2392,7 @@ def fix_shebang(self):
if isinstance(fix_shebang_for, string_type):
fix_shebang_for = [fix_shebang_for]

shebang = '#!/usr/bin/env %s' % lang
shebang = '#!%s %s' % (build_option('env_for_shebang'), lang)
for glob_pattern in fix_shebang_for:
paths = glob.glob(os.path.join(self.installdir, glob_pattern))
self.log.info("Fixing '%s' shebang to '%s' for files that match '%s': %s",
Expand Down
1 change: 1 addition & 0 deletions easybuild/framework/easyconfig/default.py
Original file line number Diff line number Diff line change
Expand Up @@ -194,6 +194,7 @@

# MODULES documentation easyconfig parameters
# (docurls is part of MANDATORY)
'citing': [None, "Free-form text that describes how the software should be cited in publications", MODULES],
'docpaths': [None, "List of paths for documentation relative to installation directory", MODULES],
'examples': [None, "Free-form text with examples on using the software", MODULES],
'site_contacts': [None, "String/list of strings with site contacts for the software", MODULES],
Expand Down
13 changes: 8 additions & 5 deletions easybuild/framework/easyconfig/easyconfig.py
Original file line number Diff line number Diff line change
Expand Up @@ -702,10 +702,13 @@ def parse(self):
# parse dependency specifications
# it's important that templating is still disabled at this stage!
self.log.info("Parsing dependency specifications...")
self['dependencies'] = [self._parse_dependency(dep) for dep in self['dependencies']]
self['hiddendependencies'] = [
self._parse_dependency(dep, hidden=True) for dep in self['hiddendependencies']
]

def remove_false_versions(deps):
return [dep for dep in deps if not (isinstance(dep, dict) and dep['version'] is False)]

self['dependencies'] = remove_false_versions(self._parse_dependency(dep) for dep in self['dependencies'])
self['hiddendependencies'] = remove_false_versions(self._parse_dependency(dep, hidden=True) for dep in
self['hiddendependencies'])

# need to take into account that builddependencies may need to be iterated over,
# i.e. when the value is a list of lists of tuples
Expand All @@ -715,7 +718,7 @@ def parse(self):
builddeps = [[self._parse_dependency(dep, build_only=True) for dep in x] for x in builddeps]
else:
builddeps = [self._parse_dependency(dep, build_only=True) for dep in builddeps]
self['builddependencies'] = builddeps
self['builddependencies'] = remove_false_versions(builddeps)

# keep track of parsed multi deps, they'll come in handy during sanity check & module steps...
self.multi_deps = self.get_parsed_multi_deps()
Expand Down
13 changes: 13 additions & 0 deletions easybuild/framework/easyconfig/templates.py
Original file line number Diff line number Diff line change
Expand Up @@ -155,6 +155,19 @@
('SOURCE_%s' % suffix, '%(name)s-%(version)s.' + ext, "Source .%s bundle" % ext),
('SOURCELOWER_%s' % suffix, '%(namelower)s-%(version)s.' + ext, "Source .%s bundle with lowercase name" % ext),
]
for pyver in ('py2.py3', 'py2', 'py3'):
if pyver == 'py2.py3':
desc = 'Python 2 & Python 3'
name_infix = ''
else:
desc = 'Python ' + pyver[-1]
name_infix = pyver.upper() + '_'
TEMPLATE_CONSTANTS += [
('SOURCE_%sWHL' % name_infix, '%%(name)s-%%(version)s-%s-none-any.whl' % pyver,
'Generic (non-compiled) %s wheel package' % desc),
('SOURCELOWER_%sWHL' % name_infix, '%%(namelower)s-%%(version)s-%s-none-any.whl' % pyver,
'Generic (non-compiled) %s wheel package with lowercase name' % desc),
]

# TODO derived config templates
# versionmajor, versionminor, versionmajorminor (eg '.'.join(version.split('.')[:2])) )
Expand Down
Loading