feat(abstract-utxo): enhance output handling and fix address comparison#7977
Merged
OttoAllmendinger merged 6 commits intomasterfrom Jan 27, 2026
Merged
Conversation
Move outputDifference test file from transaction/descriptor/ to transaction/ directory to match the source file location structure. Issue: BTC-2962 Co-authored-by: llm-git <llm-git@ttll.de>
The `preprocessBuildParams` method was missing the `override` keyword, which is now added to correctly indicate that this method overrides a method from the parent class. Issue: BTC-2962 Co-authored-by: llm-git <llm-git@ttll.de>
…saction Move toCanonicalTransactionRecipient out of the AbstractUtxoCoin class into the parseTransaction module where it's used, removing it from the public API. Issue: BTC-2962 Co-authored-by: llm-git <llm-git@ttll.de>
When comparing addresses, normalize them to a standard script format to ensure accurate matching regardless of address representation. We can now pass `txParams.txRecipients` to `parseOutputs`. It previously passed `expectedOutputs`, which did multiple things at once: - Normalize the address format for comparison (which is what we wanted) - Append the changeAddress in certain cases (which is not desired in parseOutput) This allows us to change the `toExpectedOutputs` function. Issue: BTC-2962 Co-authored-by: llm-git <llm-git@ttll.de>
Add optional flag to ExpectedOutput type for outputs that can be excluded. Update output difference logic to filter non-optional outputs when determining missing outputs. Issue: BTC-2962 Co-authored-by: llm-git <llm-git@ttll.de>
Fix the way we handle `allowExternalChangeAddress` when verifying transactions with external change addresses. Use the new ExpectedOutput interface to mark the change address as optional, as it's not required to exist in the transaction. Issue: BTC-2962 Co-authored-by: llm-git <llm-git@ttll.de>
72db9aa to
d79d95a
Compare
davidkaplanbitgo
approved these changes
Jan 27, 2026
lcovar
approved these changes
Jan 27, 2026
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.
This PR adds optional expected outputs support and fixes several issues in
address handling and transaction parsing:
Issue: BTC-2962