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

Collection download crashes if hda has no extension #18383

Open
galaxyproject-sentryintegration bot opened this issue Jun 12, 2024 · 0 comments
Open

Collection download crashes if hda has no extension #18383

galaxyproject-sentryintegration bot opened this issue Jun 12, 2024 · 0 comments
Assignees
Labels
area/database Galaxy's database or data access layer area/datatype-framework kind/bug

Comments

@galaxyproject-sentryintegration

This happens if tools don't define an output format. It's a tool bug, but I think falling back to data as a default extension is reasonable.

Sentry Issue: GALAXY-MAIN-YRR

ExceptionGroup: unhandled errors in a TaskGroup
  File "starlette/_utils.py", line 87, in collapse_excgroups
    yield
  File "starlette/middleware/base.py", line 190, in __call__
    async with anyio.create_task_group() as task_group:
  File "anyio/_backends/_asyncio.py", line 678, in __aexit__
    raise BaseExceptionGroup(

AttributeError: 'NoneType' object has no attribute 'endswith'
(29 additional frame(s) were not displayed)
...
  File "galaxy/webapps/galaxy/services/history_contents.py", line 482, in get_dataset_collection_archive_for_download
    return self.__stream_dataset_collection(trans, dataset_collection_instance)
  File "galaxy/webapps/galaxy/services/history_contents.py", line 501, in __stream_dataset_collection
    archive = hdcas.stream_dataset_collection(
  File "galaxy/managers/hdcas.py", line 39, in stream_dataset_collection
    write_dataset_collection(dataset_collection_instance, archive)
  File "galaxy/managers/hdcas.py", line 50, in write_dataset_collection
    for file_path, relpath in hda.datatype.to_archive(dataset=hda, name=name):
  File "galaxy/datatypes/data.py", line 451, in to_archive
    if dataset.datatype.composite_type or dataset.extension.endswith("html"):
mvdbeek added a commit to mvdbeek/tools-iuc that referenced this issue Jun 12, 2024
We can find them with
```
planemo lint -s command,tool_xsd,tests,general,help,inputs,citations,xml_order  --recursive
```
If we don't set an output format the hda extension becomes null in the
database, and we fail at various places in the galaxy codebase.
We can make Galaxy more resilient to it, but this is an easy fix here.
Galaxy issue is here: galaxyproject/galaxy#18383
mvdbeek added a commit to mvdbeek/galaxytools that referenced this issue Jun 12, 2024
Add mising format attributes

We can find them with
```
planemo lint -s command,tool_xsd,tests,general,help,inputs,citations,xml_order  --recursive
```
If we don't set an output format the hda extension becomes null in the
database, and we fail at various places in the galaxy codebase.
We can make Galaxy more resilient to it, but this is an easy fix here.
Galaxy issue is here: galaxyproject/galaxy#18383
@mvdbeek mvdbeek self-assigned this Jun 12, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
area/database Galaxy's database or data access layer area/datatype-framework kind/bug
Projects
None yet
Development

No branches or pull requests

1 participant