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
[23.1] Fix DataResult type #17639
[23.1] Fix DataResult type #17639
Conversation
None isn't valid for `List[Any]`. Fixes: ``` ValidationError 1 validation error for DataResult data Input should be a valid list [type=list_type, input_value=None, input_type=NoneType] For further information visit https://errors.pydantic.dev/2.5/v/list_type ```
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.
Ouch... I wonder why mypy didn't complain about this... 🤔
Sorry about that.
It is still possible to get this error:
in case
produces |
I don't know, what's the stack trace ? It's probably a good idea to raise a RequestInvalidException or something like this if there's no indexer for a given dataset. |
For the api call:
You get:
I think at the very least, we should raise the |
Sounds good to me, thank you! |
In case a dataset does not have an indexer, raise an exception. Fixes the bug mentioned in galaxyproject#17639 (comment)
None isn't valid for
List[Any]
.Fixes:
from https://sentry.galaxyproject.org/share/issue/ed6da4c9029649cc9cc4b9a30e5144fe/
How to test the changes?
(Select all options that apply)
License