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

Use text columns for OCaml unsigned 64-bit values #11037

Merged
merged 3 commits into from
May 23, 2022

Conversation

psteckler
Copy link
Member

In the archive database, for columns representing OCaml unsigned 64-bit ints, use the Postgresql text type, to prevent any possibility of overflow. We retain the bigint type for values representing unsigned 32-bit values (slots and nonces).

Update the replayer and extract-blocks apps accordingly. For the replayer test data, ran ALTER COLUMN .. TYPE text on the affected columns, made sure the test succeeded locally.

Tested by running a local network, making sure payments and a zkApp were archived.

Part of #9182.

@psteckler psteckler requested review from a team as code owners May 20, 2022 22:50
@psteckler psteckler added the ci-build-me Add this label to trigger a circle+buildkite build for this branch label May 20, 2022
| [ s ] ->
(Currency.Amount.of_string s, Sgn.Pos)
| [ _; s ] ->
(Currency.Amount.of_string s, Sgn.Neg)
Copy link
Member

Choose a reason for hiding this comment

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

Nit: sanity-check with a literal pattern ""?

Copy link
Contributor

@mitschabaude mitschabaude left a comment

Choose a reason for hiding this comment

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

LGTM!

@psteckler psteckler merged commit d155b36 into develop May 23, 2022
@psteckler psteckler deleted the feature/text-for-uint64-archive-db branch May 23, 2022 18:35
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
ci-build-me Add this label to trigger a circle+buildkite build for this branch
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants