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
Fix discarded datasets when importing history from file sources using tasks #14989
Fix discarded datasets when importing history from file sources using tasks #14989
Conversation
So, in this context (importing histories from file sources using tasks), it looks like we don't have a galaxy/lib/galaxy/model/store/__init__.py Line 626 in d2163c9
|
Hah, you've reached the limitations of Celery. Setting metadata is another celery task, and you're not supposed to call tasks from tasks. If at all possible I would create a chord, where the first task, |
fb2f00b
to
3404db4
Compare
Currently the test will fail because the imported datasets are in the "discarded" state.
Co-authored-by: mvdbeek <m.vandenbeek@gmail.com>
a9e500d
to
eed7911
Compare
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.
Thanks a lot for the test and the fixes.
Required for #14839
When importing a history archive from a file source using the tasks system with
/api/histories/from_store_async
all datasets appear asdiscarded
in the new history regardless of their real state.This adds test coverage to expose the bug. Currently investigating the fix... 🔍
Update
This PR tries to fix some issues found in this context:
tag_handler
instance was missing during import so it failed when items had tags.model_store_format
was not passed to the import model store and was always the defaulttgz
.discarded_data
in theImportOptions
was alwaysFORCE
which apparently treated every dataset as discarded independently of their realstate
.set_external_metadata_tool
in the context of tasks so, for now, we try to set the metadata directly withing the task... See 3404db4.How to test the changes?
License