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

change ballot package location on USB #4142

Merged
merged 5 commits into from
Oct 31, 2023
Merged

Conversation

adghayes
Copy link
Collaborator

@adghayes adghayes commented Oct 30, 2023

Overview

Closes #3935. Previously, ballot packages would be exported to a USB drive like so:

./ballot-packages/sample-county_example-primary-election_06414087b1__2023-10-30_12-57-46.zip

Now, we export them like this:

./sample-county_example-primary-election_06414087b1/ballot-packages/ballot-package__2023-10-30_12-56-55.zip

This means that all of our in-system files are being exported in the same way, to a top-level election directory, a file type subdirectory, then a filename. I kept ballot-package in the file name for the ballot package so that it wouldn't be just a date if it got out of context. Could add file hash in too if desirable.

Testing Plan

  • updated automated testing, added a test
  • manually tested exporting from VxAdmin and loading into VxMark

@adghayes adghayes force-pushed the drew/ballot-package-location branch 3 times, most recently from 44db019 to dceb6ed Compare October 31, 2023 07:21
- changes directory structure that VxAdmin creates
- removes a lot of unused file naming helpers from libs/utils
@@ -168,46 +161,6 @@ test("if there's only one precinct in the election, it's selected automatically
});
});

test('configures using the most recently created ballot package on the usb drive', async () => {
Copy link
Collaborator Author

Choose a reason for hiding this comment

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

this is tested in libs/backend and doesn't need to be tested here too

@adghayes adghayes marked this pull request as ready for review October 31, 2023 07:29
@adghayes adghayes requested a review from a team as a code owner October 31, 2023 07:29
@adghayes adghayes requested review from jonahkagan, kshen0 and arsalansufi and removed request for a team and jonahkagan October 31, 2023 07:29
@adghayes
Copy link
Collaborator Author

@arsalansufi or @kshen0 tagging either of you for review as I've discussed this change with both of you on Slack.

Copy link
Contributor

@arsalansufi arsalansufi left a comment

Choose a reason for hiding this comment

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

LGTM!

/**
* Generate the directory name for the cast vote record report.
*
* @deprecated
Copy link
Contributor

Choose a reason for hiding this comment

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

Thanks for removing these! Forgot about them when I was cleaning up old CVR code

@adghayes adghayes enabled auto-merge (squash) October 31, 2023 18:03
@adghayes adghayes merged commit adee7f0 into main Oct 31, 2023
50 checks passed
@adghayes adghayes deleted the drew/ballot-package-location branch October 31, 2023 18:54
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.

Export files to USB in consistent directory structure
2 participants