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

6873 shapefiles zip folders #7279

Merged
merged 4 commits into from
Sep 22, 2020
Merged

6873 shapefiles zip folders #7279

merged 4 commits into from
Sep 22, 2020

Conversation

landreev
Copy link
Contributor

What this PR does / why we need it:
Preserves folders found in shape file zip archives.

Which issue(s) this PR closes:

Closes #6873

Special notes for your reviewer:
The changes to FileUtil.java are mostly tabs and whitespaces - the formatting of the method I had to change was seriously off, I couldn't resist fixing it; actual code changes are relatively small there.

Suggestions on how to test this:
There's a test file provided in the issue: https://github.com/IQSS/dataverse/files/4588466/files.zip . It has 4 files constituting a shape set, plus 2 extra files. All files are in subfolders, that would be dropped by the application as it is now, but should be preserved by the code in the PR.

Does this PR introduce a user interface change? If mockups are available, please link/include them here:

Is there a release notes update needed for this change?:

Additional documentation:

@coveralls
Copy link

coveralls commented Sep 22, 2020

Coverage Status

Coverage increased (+0.01%) to 19.487% when pulling 06eb9b6 on 6873-shapefiles-zip-folders into 2d9562a on develop.

@djbrooke djbrooke added this to the 5.1 milestone Sep 22, 2020
@pdurbin pdurbin self-assigned this Sep 22, 2020
Copy link
Member

@pdurbin pdurbin left a comment

Choose a reason for hiding this comment

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

Looks good. I'm very happy to see a test has been added to test the functionality. I'm also glad to see the whitespace cleaned up. WorldMapTokenTest.testTokenValues failed in the Jenkins run but that test fails for no reason from time to time.

@pdurbin pdurbin removed their assignment Sep 22, 2020
@landreev
Copy link
Contributor Author

@pdurbin

I'm also glad to see the whitespace cleaned up.

I often hesitate to fix existing formatting, because it "inflates" the diff and makes it harder to see the actual functional changes in the commit... But there were so many random extra tabs in that method - in some, but not all lines - that it was hard to view in Netbeans.

@pdurbin
Copy link
Member

pdurbin commented Sep 22, 2020

@landreev yeah, what I'd rather see eventually is some sort of enforcement of a house style but for now with whitespace changes come in I make use of this button in GitHub to hide them while reviewing:

Screen Shot 2020-09-22 at 11 33 33 AM

@kcondon kcondon self-assigned this Sep 22, 2020
@kcondon kcondon merged commit c85a76d into develop Sep 22, 2020
@kcondon kcondon deleted the 6873-shapefiles-zip-folders branch September 22, 2020 19:02
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.

Dataverse not saving uploaded zip file's directory structure when the zip file contains shapefiles
5 participants