Skip to content

Conversation

@bickelj
Copy link
Collaborator

@bickelj bickelj commented Jun 27, 2023

Without this change there would be two CSV reading libraries in use and two scripts would continue to have race conditions. We do not need the sophistication of a stream API because we have yet to see any CSVs larger than a few MiB. This change uses the technique already present in the postProposalVersions.ts script in the older two scripts.

Because there would be repeated boilerplate otherwise, a new csv.ts has the commonly used type and type assertion guard.

Issue #25 Race between row and EOF events for forms and proposals

@bickelj bickelj requested a review from jasonaowen June 27, 2023 20:13
@bickelj
Copy link
Collaborator Author

bickelj commented Dec 2, 2025

More than two years later, no review. We have a different bulk upload strategy now. This may or may not be broken at this point, but I believe it is less broken than that which preceded it.

Without this change there would be two CSV reading libraries in use
and two scripts would continue to have race conditions. We do not need
the sophistication of a stream API because we have yet to see any CSVs
larger than a few MiB. This change uses the technique already present in
the `postProposalVersions.ts` script in the older two scripts.

Because there would be repeated boilerplate otherwise, a new `csv.ts`
has the commonly used type and type assertion guard.

Issue #25 Race between row and EOF events for forms and proposals
@bickelj bickelj force-pushed the use-csv-parse-sync branch from b107355 to 4e807a4 Compare December 2, 2025 17:20
@bickelj bickelj merged commit 84156ef into main Dec 2, 2025
4 checks passed
@bickelj bickelj deleted the use-csv-parse-sync branch December 2, 2025 17:23
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.

2 participants