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 export_remote include/exclude metadata flag #18659

Conversation

davelopez
Copy link
Contributor

Fixes #18564

We were passing 'false' to --export-metadata-files, but it was considered True (non-zero length string), and the metadata was always included in the export.

How to test the changes?

License

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

@github-actions github-actions bot added this to the 23.2 milestone Aug 7, 2024
@davelopez
Copy link
Contributor Author

Should I target an older branch?

@mvdbeek
Copy link
Member

mvdbeek commented Aug 7, 2024

I think 24.1 would be fine ? This is so niche that no-one ran into this before, and as you can see those old tests are a mess.

We were passing 'false' to --export-metadata-files, but it was considered True (non-zero length string)

Are you saying type=bool acts as a flag ? In that case I think the slightly better fix is

diff --git a/tools/data_export/export_remote.xml b/tools/data_export/export_remote.xml
index ef5450cc55..77d72802ed 100644
--- a/tools/data_export/export_remote.xml
+++ b/tools/data_export/export_remote.xml
@@ -10,7 +10,9 @@ python '$__tool_directory__/export_remote.py'
     --file-sources '$file_sources'
     --directory-uri '$d_uri'
     --files-to-export '$files_to_export'
-    --export-metadata-files $include_metadata_files
+#if $include_metadata_files:
+    --export-metadata-files
+#end if
     > '$out'
     ]]></command>
     <configfiles>

We were passing 'false' to --export-metadata-files, but it was
considered True (non-zero length string), and the metadata was
always included in the export.

Co-authored-by: Marius van den Beek <m.vandenbeek@gmail.com>
@davelopez davelopez force-pushed the fix_remote_export_tool_exclude_metadata branch from 7051019 to 7d00202 Compare August 7, 2024 12:48
@davelopez davelopez changed the base branch from release_23.1 to release_24.1 August 7, 2024 12:48
@davelopez davelopez changed the title [23.1] Fix export_remote include/exclude metadata flag [24.1] Fix export_remote include/exclude metadata flag Aug 7, 2024
@mvdbeek mvdbeek merged commit e059a16 into galaxyproject:release_24.1 Aug 8, 2024
49 of 55 checks passed
@davelopez davelopez deleted the fix_remote_export_tool_exclude_metadata branch August 8, 2024 15:30
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