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

MFileZip fixes #1345

Merged
merged 9 commits into from
May 23, 2024
Merged

MFileZip fixes #1345

merged 9 commits into from
May 23, 2024

Conversation

tdrwenski
Copy link
Member

@tdrwenski tdrwenski commented May 22, 2024

Description of Changes

Several issues with MFileZip have come to light since it has been incorporated in the TDS as part of the zarr code. This PR fixes these and adds some unit tests.

  • Fix getLastModified and getLength for the root zip file to not return 0
  • Fix writeToStream to work the same as it would for a MFileOS
  • Allow the zip extension to be case insensitive
  • Add isZipFile to MFile interface. In the TDS, the fileServer should allow downloading zips but disallow downloading directories. MFileZips can be considered directories. So we need a way to distinguish between directories and zip files. This is what I came up with but we could also consider changing isDirectory or doing something else. See Fix issue with zip files being disallowed with fileServer tds#501 for proposed TDS change.

@tdrwenski tdrwenski marked this pull request as ready for review May 23, 2024 16:53
@haileyajohnson haileyajohnson merged commit fabaec0 into Unidata:maint-5.x May 23, 2024
10 checks passed
@tdrwenski tdrwenski deleted the mfilezip-fixes branch May 23, 2024 17:24
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants