-
Notifications
You must be signed in to change notification settings - Fork 211
Update fake module for each extension installed #4868
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
Merged
boegel
merged 16 commits into
easybuilders:develop
from
lexming:fake-module-per-extension
May 18, 2025
Merged
Update fake module for each extension installed #4868
boegel
merged 16 commits into
easybuilders:develop
from
lexming:fake-module-per-extension
May 18, 2025
Conversation
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
…e fake module for the whole extenions installation step
…module_environment context
…eck with fake_module_environment context
c055fbd
to
6697207
Compare
… test_toy_multi_deps
663f247
to
c840ea9
Compare
boegel
approved these changes
May 18, 2025
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
lgtm
This was referenced May 20, 2025
This was referenced May 21, 2025
This was referenced Jun 7, 2025
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
The extension step generates a single fake module before the first extension is installed and uses that same fake module across the installation of all extensions.
This break the installations of easyconfigs with extensions that rely on files installed by previous extensions in the same easyconfig and that make use of search paths to find those files. Since the resolution of paths in
module_load_environment
only happens before extensions are installed, no search paths are added to the fake module as those paths/globs are empty.We added a quick workaround in #4809 that skips path resolution for fake modules to avoid this issue. However, this workaround has broken installation of easyconfigs that have search paths with globs that must be expanded in their sanity checks. One example is MATSim-15.0-Java-17.eb, which has
modextrapaths = {'CLASSPATH': 'libs/*'}
.This PR fixes this issue for good by generating a new fake module for each extension installed. This ensures that path/glob resolution can happen and new files from previous extensions will be accounted.
Moreover, I'm adding a new context manager to handle fake modules and a new unit test to test this particular case.