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

Validation Error as Error Code #965

Open
samuelmanzanera opened this issue Mar 29, 2023 · 0 comments
Open

Validation Error as Error Code #965

samuelmanzanera opened this issue Mar 29, 2023 · 0 comments
Labels
feature New feature request mining Involve transaction validation and mining serialization Involve message serialization transaction Involve transactions

Comments

@samuelmanzanera
Copy link
Member

samuelmanzanera commented Mar 29, 2023

Is your feature request related to a problem?

During transaction validation, the miners check the transaction and store the error reason in the validation state and the validation stamp. However, the validation stamp's error is meaningless if the validation's state is not given.
Moreover, to avoid recomputing the reason of the pending transaction validation, we should have a way to enhance the discoverability of the error reasons.

Describe the solution you'd like

We should then a list of error codes given by the pending transaction validation and for any further network issues, helping to reduce the network bandwidth and help to discover error's reason.

For example we might have:

  • INVALID_CONTRACT_CODE
  • MISSING_AUTHORIZED_KEY_CONTRACT
  • INVALID_CONTRACT_SIZE
  • INVALID_OWNERSHIP_SECRET
  • INVALID_OWNERSHIP_AUTHORIZED_KEYS
  • INVALID_TRANSFER_TX
  • INVALID_HOSTING_TX
  • INVALID_NODE_REWARD_TIME
  • INVALID_NODE_REWARD_TRANSFERS
  • INVALID_NODE_TX_CONTENT
  • INVALID_NODE_CERT
  • INVALID_NODE_ORIGIN
  • INVALID_NODE_IP
  • NODE_DUPLICATE
  • INVALID_ORIGIN_CERT
  • ORIGIN_KEY_DUPLICATE
  • INVALID_ORIGIN_TX_CONTENT
  • INVALID_SHARED_SECRETS_TX_CONTENT
  • INVALID_AUTHORIZED_NODES
  • INVALID_SHARED_SECRETS_TIME
  • INVALID_CODE_PROPOSAL
  • CODE_APPROVAL_DUPLICATE
  • CODE_APPROVAL_UNAUTH
  • CODE_PROPOSAL_NOT_FOUND
  • CODE_APPROVAL_NO_RECIPIENTS
  • INVALID_KEYCHAIN_TX
  • INVALID_KEYCHAIN_DID
  • MISSING_KEYCHAIN_ACCESS_PREV_KEY_AUTH
  • INVALID_KEYCHAIN_ACCESS_TX
  • INVALID_MINT_REWARDS_SUPPLY
  • INVALID_MINT_DUPLICATE
  • INVALID_ORACLE_TIME
  • INVALID_ORACLE_TX_CONTENT
  • INVALID_ORACLE_SUMMARY_TIME
  • INVALID_ORACLE_SUMMARY_TX_CONTENT
  • MISSING_CONTRACT_CODE
  • MISSING_DATA

Additional context

Epic: #306

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
feature New feature request mining Involve transaction validation and mining serialization Involve message serialization transaction Involve transactions
Projects
None yet
Development

No branches or pull requests

1 participant