Skip to content

fix(website): Fix applying file mappings for compressed metadata files - #7119

Draft
tombch wants to merge 4 commits into
mainfrom
fix-file-mapping-compressed-uploads
Draft

fix(website): Fix applying file mappings for compressed metadata files#7119
tombch wants to merge 4 commits into
mainfrom
fix-file-mapping-compressed-uploads

Conversation

@tombch

@tombch tombch commented Aug 20, 2026

Copy link
Copy Markdown
Collaborator

resolves #7120

Summary

  • Adjacent issue found from reviewing fix(website): report unreadable metadata files instead of hanging on "still being processed" #7108.
  • For organisms with files enabled, and for compressed metadata files with file uploads, the decompressed file was not passed by the file factory, leading to applyFileMappings to fail at writing to the file (as it cannot see the metadata headers) and the submission unable to continue.
  • This PR updates the file factory logic to also check if files are enabled, and if so, decompresses the file for applyFileMappings to later read correctly.
  • I also added an integration test for compressed metadata with files.

Notes

  • This is a simple fix but I feel like these functions need further refactoring. Ideally, the preparation of the metadata and sequence files should be in one place, rather than have some processing occur in the files factory in FormOrUploadWrapper, and further processing occur in the DataUploadForm's handleSubmit function, which silently depends on actions like making sure the file is decompressed in the files factory. So I'd be happy to expand on this if we don't think this is a sufficient fix for now.

Screenshot

PR Checklist

  • All necessary documentation has been adapted.
  • The implemented feature is covered by appropriate, automated tests.
  • Any manual testing that has been done is documented (i.e. what exactly was tested?)

🚀 Preview: Add preview label to enable

@claude claude Bot added the website Tasks related to the web application label Aug 20, 2026
filesColumnCell(Object.keys(FILES_SINGLE), ID_1),
],
],
isGzipped,

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

You could potentially parametrize this test over gzipped? (If it's a 1-1 of an existing non-gzipped test case)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

website Tasks related to the web application

Projects

None yet

Development

Successfully merging this pull request may close these issues.

If file sharing is enabled, bulk submission of compressed metadata with files is broken

2 participants