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

fix: contract init stuck because of secret storage loading #668

Merged
merged 1 commit into from
Jul 8, 2024

Conversation

ppca
Copy link
Contributor

@ppca ppca commented Jul 3, 2024

secret storage loading value 1, which is the initial value, returns error instead of None, thus state progression is stuck

@ppca ppca linked an issue Jul 3, 2024 that may be closed by this pull request
@ppca ppca changed the title fix: secret storage loading value 1 failed node state progress fix: contract init stuck because of secret storage loading Jul 3, 2024
Comment on lines +69 to +74
if let Ok(persistent_node_data) = serde_json::from_slice(&data) {
Ok(Some(persistent_node_data))
} else {
tracing::info!("failed to convert stored data to key share, presuming it is missing");
Ok(None)
}
Copy link
Member

Choose a reason for hiding this comment

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

we should log the error just in case so we can debug what the exact cause was. We shouldn't include the actual data portion itself but should include things like the length of it just in case we made some incompatible version serialization changes to persistent node data

Copy link
Member

Choose a reason for hiding this comment

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

Good point on the case of debugging. I suggest to make the log level to warn. Current log information should be sufficient to debug (timestamp, node config's sk_share_secret_id), make it to warn maybe easier to track unexpected case in monitor.

@ppca ppca merged commit 92055e1 into develop Jul 8, 2024
1 of 3 checks passed
@ppca ppca deleted the xiangyi/fix_secret_storage_initial_load branch July 8, 2024 20:03
Copy link

github-actions bot commented Jul 8, 2024

Terraform Feature Environment Destroy (dev-668)

Terraform Initialization ⚙️success

Terraform Destroy success

Show Destroy Plan


No changes. No objects need to be destroyed.

Either you have not created any objects yet or the existing objects were
already deleted outside of Terraform.

Destroy complete! Resources: 0 destroyed.

Pusher: @ppca, Action: pull_request, Working Directory: ``, Workflow: Terraform Feature Env (Destroy)

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.

mainnet dev network initialization stuck
4 participants