Open
Conversation
Add stable kind accessors for receiver output substitution and input contribution failures and preserve the duplicate input outpoint across the FFI boundary. Bindings currently only see opaque error wrappers for these paths, which forces callers to branch on display strings even though core already distinguishes actionable failure classes. This keeps the internal enums private while making receiver integrations able to react to invalid drain scripts, disabled output substitutions, duplicate inputs, and value-too-low contributions.
Collaborator
Pull Request Test Coverage Report for Build 23355439112Details
💛 - Coveralls |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Closes #1277.
This PR makes receiver-side output substitution and input contribution failures inspectable over FFI. Core already distinguished these cases internally, but the FFI preserved them as opaque wrappers, which meant bindings had to parse display strings to tell apart substitution policy failures from contributed-input failures like duplicate inputs or insufficient contributed value.
The change adds stable classifications for
OutputSubstitutionErrorandInputContributionError, and exposes the duplicate-input outpoint as structured data. On the FFI side, the old transparent wrappers are replaced with stable snapshot objects that expose the error kind, message, and duplicate-input detail where it exists.The result is that bindings can now branch on receiver modification failures in a usable way and surface actionable diagnostics without relying on string parsing. This keeps the same accessor-based pattern established for the other receiver-side error work.