Repository navigation
Conversation
They have no address, so reviewing a PSBT with one raised before anything was shown (selfcustody#965).
qlrd
reviewed
Nov 3, 2026
qlrd
left a comment
Member
There was a problem hiding this comment.
Doubt: what happens when the OP_RETURN is too big? could it be break UI/UX or even give it an attack if it is a malicious one?
Data over 80 bytes pushed the output amount off the smallest screen.
Author
This branch has not been deployed
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.

What is this PR for?
Fixes #965.
Reviewing a PSBT with an OP_RETURN output raised a TypeError in
get_policy(), and past that a ValueError fromaddress().OP_RETURN outputs are now counted as spends and shown on their own "OP_RETURN:" screen, with the amount and the data in hex.
When the script is a single push the push opcode is dropped; otherwise every byte after OP_RETURN is shown.
There was no reply on the issue yet, so I went with showing them rather than refusing the PSBT.
I'm happy to switch to refusing instead if you prefer.
#968 keeps this fix separate, so this PR only covers the review crash.
The sat/vB estimate still leaves these outputs out, as it already does for script types it does not know.
uv run poe pre-commitpasses. Not tested on a device.Changes made to:
Did you build the code and tested on device?
What is the purpose of this pull request?