Skip to content
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

[20.05] Error in 'Manual Data Manager' hook 'exec_before_job' #10023

Closed
abretaud opened this issue Jul 22, 2020 · 3 comments
Closed

[20.05] Error in 'Manual Data Manager' hook 'exec_before_job' #10023

abretaud opened this issue Jul 22, 2020 · 3 comments
Labels

Comments

@abretaud
Copy link
Contributor

Hi,
Found an error with latest data_manager_manual and galaxy 20.05 while testing biomaj2galaxy with 20.05:

galaxy.jobs.runners ERROR 2020-07-22 15:15:32,060 (1) Failure preparing job
Traceback (most recent call last):
  File "/galaxy-central/lib/galaxy/jobs/runners/__init__.py", line 236, in prepare_job
    job_wrapper.prepare()
  File "/galaxy-central/lib/galaxy/jobs/__init__.py", line 1096, in prepare
    tool_evaluator.set_compute_environment(compute_environment, get_special=get_special)
  File "/galaxy-central/lib/galaxy/tools/evaluation.py", line 119, in set_compute_environment
    out_data=out_data, tool=self.tool, param_dict=incoming)
  File "/galaxy-central/lib/galaxy/tools/__init__.py", line 1838, in call_hook
    return code(*args, **kwargs)
  File "/galaxy-central/database/shed_tools/toolshed.g2.bx.psu.edu/repos/iuc/data_manager_manual/0bed5ee5b74a/data_manager_manual/data_manager/data_manager_manual.py", line 61, in exec_before_job
    target_dir, tool_path, relative_target_dir = tdtm.get_target_install_dir(tool_shed_repository)
  File "/galaxy-central/lib/galaxy/tool_shed/tools/data_table_manager.py", line 112, in get_target_install_dir
    tool_path, relative_target_dir = tool_shed_repository.get_tool_relative_path(self.app)
  File "/galaxy-central/lib/galaxy/model/tool_shed_install/__init__.py", line 103, in get_tool_relative_path
    shed_conf_dict = self.get_shed_config_dict(app)
  File "/galaxy-central/lib/galaxy/model/tool_shed_install/__init__.py", line 95, in get_shed_config_dict
    if self.shed_config_filename:
  File "/galaxy-central/lib/galaxy/model/tool_shed_install/__init__.py", line 84, in shed_config_filename
    return self.metadata.get('shed_config_filename')
  File "/galaxy_venv/lib/python3.7/site-packages/sqlalchemy/orm/attributes.py", line 286, in __get__
    return self.impl.get(instance_state(instance), dict_)
  File "/galaxy_venv/lib/python3.7/site-packages/sqlalchemy/orm/attributes.py", line 720, in get
    value = callable_(state, passive)
  File "/galaxy_venv/lib/python3.7/site-packages/sqlalchemy/orm/strategies.py", line 439, in __call__
    return strategy._load_for_state(state, passive)
  File "/galaxy_venv/lib/python3.7/site-packages/sqlalchemy/orm/strategies.py", line 412, in _load_for_state
    % (orm_util.state_str(state), self.key)
sqlalchemy.orm.exc.DetachedInstanceError: Error in 'Manual Data Manager' hook 'exec_before_job', original message: Parent instance <ToolShedRepository at 0x7fb5b70a2c88> is not bound to a Session; deferred load operation of attribute 'metadata' cannot proceed (Background on this error at: http://sqlalche.me/e/bhk3)

I guess Galaxy has problems executing this code: https://github.com/galaxyproject/tools-iuc/blob/master/data_managers/data_manager_manual/data_manager/data_manager_manual.py#L35
Any idea if it's a data_manager_manual or galaxy problem?

@nsoranzo
Copy link
Member

nsoranzo commented Jul 22, 2020

@mvdbeek I think you solved a similar issue somewhere else? E.g. #8933

@abretaud
Copy link
Contributor Author

I just stumble upon this again, any clue on where it could come from?

@mvdbeek
Copy link
Member

mvdbeek commented Oct 30, 2021

I think we've fixed this for good in #12390, which will be part of 21.09. I'm gonna close this but feel free to open again if you see this after updating to 21.09.

@mvdbeek mvdbeek closed this as completed Oct 30, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

3 participants