-
Notifications
You must be signed in to change notification settings - Fork 984
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
Job metadata scripts should not run in conda environment #3238
Comments
@bgruening this is the issue about the environment conflict involving conda which I reported to you earlier. |
What version of galaxy are you using?
in the job_conf.xml's destination section resolve the issue? In that case we could rework the default job_script to do this. |
This has never happened in my testing, but there have been multiple reports of Conda crafting environments for the set metadata tool that include Python. When this happens Galaxy's Python environment is lost and the tool cannot function properly. Fixes galaxyproject#3238. Fixes galaxyproject#3224. Fixes https://biostar.usegalaxy.org/p/20865/.
The scripts to handle job metadata should not run in a conda environment. Currently
__handle_metadata
builds a command that runs inside a conda environment by passingresolve_metadata_dependencies
asTrue
(as that's whatjob_wrapper.commands_in_new_shell
evaluates to).This is a problem because the job might need to run in an environment in which Python is available. Running the metadata handler inside of this environment would make the scripts use the Python variant from the job's conda environment, including its PYTHONPATH. This causes the metadata scripts to fail unless Galaxy's Python dependencies are installed in the job's conda environment (but they should not).
Setting
resolve_metadata_dependencies = False
in__handle_metadata
oflib/galaxy/jobs/command_factory.py
fixes the behaviour in this case as the job itself continues to run in the conda environment while the metadata scripts run in the server's environment (where Galaxy dependencies are available).The text was updated successfully, but these errors were encountered: