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

[24.1] Fix config template validation for file sources and object store templates #19414

Conversation

davelopez
Copy link
Contributor

Fixes #19078

When the user provides only numbers for a config field (defined as a string in the Pydantic model) the Jinja templating renders the value as an integer which fails the model validation. This will coerce the value to a string when the field type is declared as a string.

How to test the changes?

(Select all options that apply)

License

  • I agree to license these and all my past contributions to the core galaxy codebase under the MIT license.

This will workaround an issue with jinja templates rendering a field composed only by numbers to be considered a number when the field is of type string, causing the config model validation to fail. Trying to cast the value to string using the jinja template itself did not work.
@jdavcs jdavcs merged commit d18ab54 into galaxyproject:release_24.1 Jan 17, 2025
47 of 52 checks passed
@davelopez davelopez deleted the 24.1_fix_config_templates_validation branch January 19, 2025 13:11
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants