8000 Improve leaf reconstruction error handling by JoseSK999 · Pull Request #539 · vinteumorg/Floresta · GitHub
[go: up one dir, main page]
More Web Proxy on the site http://driver.im/
Skip to content

Improve leaf reconstruction error handling #539

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

Merged

Conversation

JoseSK999
Copy link
Contributor

What is the purpose of this pull request?

  • Bug fix
  • Documentation update
  • New feature
  • Test
  • Other:

Which crates are being modified?

  • floresta-chain
  • floresta-cli
  • floresta-common
  • floresta-compact-filters
  • floresta-electrum
  • floresta-watch-only
  • floresta-wire
  • floresta
  • florestad
  • Other:

Description

Previously we were returning a simple Error enum with only one variant (EmptyStack) as leaf reconstruction error. This variant was used for cases where the script was actually not empty.

I added the remaining 2 variants, and then a higher level error type that we use at process_proof to provide context.

If we ever get any of these leaf errors, we will now see the error data debugged (the compact leaf we were trying to reconstruct, the txin, and the error kind).

@Davidson-Souza Davidson-Souza added code quality Generally improves code readability and maintainability labels Jun 25, 2025
Previously we were returning a simple `Error` enum with only one variant (`EmptyStack`) as leaf reconstruction error. This variant was used for cases where the script was actually not empty.

I added the remaining 2 variants, and then a higher level error type that we use at `process_proof` to provide context.

If we ever get any of these leaf errors, we will now see the error data debugged (the compact leaf we were trying to reconstruct, the txin, and the error kind).
@JoseSK999 JoseSK999 force-pushed the proof-util-error-rename branch from 74dc5d8 to bb34803 Compare July 1, 2025 23:12
@JoseSK999
Copy link
Contributor Author

Done!

Copy link
Contributor
@jaoleal jaoleal left a comment

Choose a reason for hiding this comment

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

ACK bb34803

Copy link
Collaborator
@Davidson-Souza Davidson-Souza left a comment

Choose a reason for hiding this comment

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

ACK bb34803

@jaoleal
Copy link
Contributor
jaoleal commented Jul 2, 2025

ACK bb34803

@Davidson-Souza Davidson-Souza merged commit d7ee13b into vinteumorg:master Jul 2, 2025
10 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
code quality Generally improves code readability and maintainability
Projects
None yet
Development

Successfully merging this pull request may c 3985 lose these issues.

3 participants
0