rez
rez copied to clipboard
Rez Suites load implicit packages from context
Rez Suites load implicit packages from the context that they were set up in.
Environment
- OS: linux rocky 8.7
- Rez version: 2.113.0
- Rez python version: Python 3.11.2
To Reproduce
-
rez-suite --create mysuite
-
rez-env maya-2016.2 --output maya.rxt
- Pretend this was done on a different OS by editing maya.rxt and changing an implicit package.
-
rez-suite --add maya.rxt --context maya mysuite
-
./mysuite/bin/maya +i
Expected behavior I would expect the suite to load the implicit packages of it's own context.
Actual behavior The suite loads the implicit packages of the context.
Possible Solutions
-
rez-env --output
should not output implicit packages. This will only work on newly created contexts and won't fix existing suites. -
rez-suite --add
should strip implicit packages. This will only work on newly created suites and won't fix existing suites. -
_FWD__invoke_suite_tool_alias
removes implicit packages. This might fix the problem with suites but might not fix other issues as it's such a targeted fix. -
ResolvedContext.from_dict
doesn't load implicit packages. This fixes the underlying issue but might lead to issues if the user would require a truly frozen context.