-
Notifications
You must be signed in to change notification settings - Fork 18
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
feat(nodeconfig)!: Default to Bech32 format for IOTA key pairs #4826
base: develop
Are you sure you want to change the base?
Conversation
The latest updates on your projects. Learn more about Vercel for Git ↗︎
|
Co-authored-by: DaughterOfMars <[email protected]>
Still don't like the module solution tbh, because |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
network_config_snapshot_matches
is failing
Co-authored-by: Thoralf-M <[email protected]>
@@ -6,11 +6,11 @@ validator_configs: | |||
- authority-key-pair: | |||
value: VTDx4HjVmRBqdqBWg2zN+zcFE20io3CrBchGy/iV1lo= | |||
protocol-key-pair: | |||
value: AH7M/Ot6iUd/Jj47r5aGmQROL24mxT4K8EF1Gvjhk0zT | |||
value: iotaprivkey1qplvel8t02y5wlex8ca6l95xnyzyutmwymznuzhsg963478pjdxdxvys9a8 |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Wondering, was the test failing because we create a config to compare to this one? Because if we read this snapshot, base64 should still work?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
As far as I understand snapshot based testing, it uses line by line string comparisons (i.e. line-by-line diffs). So the test was failing, because the old snapshot https://github.com/iotaledger/iota/blob/develop/crates/iota-swarm-config/tests/snapshots/snapshot_tests__network_config_snapshot_matches.snap
diffed from the new one because it was generated with the Base64 keypair format.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@thibault-martinez Can we resolve?
Description of change
Changes the custom serialization/deserialization methods to default to Bech32. Serializes always to Bech32, but tries to deserialize from Bech32 first and if that fails, attempts to deserialize from Base64.
Links to any relevant issues
fixes #3985
How the change has been tested
I checked through a separate python script that the swapped strings (Base32/Base64) in the
.snap
file actually represent the same private keys.