fix: a multi-glyph reveal reported one glyph's metadata as the whole tx's (#577) - #588
Merged
Merged
Conversation
…tx's (#577) `find_reveal_metadata` returns the FIRST input carrying a decodable `gly` payload, and that single payload was surfaced as the transaction's metadata. Multi-glyph reveals are real and not rare on Radiant mainnet: one observed reveal mints 35 refs from 36 inputs, another 5 from 7. In the first case thirty-four refs were being shown a different token's name, description and media — with nothing in the output hinting that other payloads existed. ADDITIVE, not a shape change, because `inspect --json` has consumers: - `metadata` still carries the first payload and the `input_index` it came from, and now also `of_n_payloads` when there is more than one, so a caller reading only that key cannot mistake one glyph's fields for the tx's. - `metadata_inputs` lists every input carrying a payload: index, classification, name, ticker. Enough to see which name belongs where, without duplicating each full payload. AND IT REACHES A HUMAN. The CLI printed a bare "Reveal metadata (from input N)" heading, which reads as describing the transaction. It now says "1 of N glyphs minted here" and prints the others. A JSON key nobody renders is not a fix for someone reading a terminal, which is where this renderer is read. Not addressed here: joining each payload to the specific REF it mints (commit vout n is spent by reveal vin n). That needs the ref-to-outpoint resolution and is worth doing, but the reporting defect is that the other payloads were invisible, and that is what this closes. Plant-verified: restricting the scan back to the first input fails 4 of the 5 new cases. CI-equivalent: 10,928 passed, 192 skipped, 1 xfailed. Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com>
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 #577.
find_reveal_metadatareturns the first input carrying a decodableglypayload, and that single payload was surfaced as the transaction's metadata.Multi-glyph reveals are real on mainnet — one observed reveal mints 35 refs from 36 inputs, another 5 from 7. So thirty-four refs were being shown a different token's name, description and media, with nothing in the output hinting other payloads existed.
Additive, not a shape change
inspect --jsonhas consumers, so nothing existing moved:metadatainput_index— plusof_n_payloadswhen there is more than onemetadata_inputsAnd it reaches a human
The CLI printed a bare
Reveal metadata (from input N), which reads as describing the transaction. It now says "1 of N glyphs minted here" and prints the others. A JSON key nobody renders is not a fix for the person reading a terminal.Deliberately not in scope
Joining each payload to the specific ref it mints (commit vout n is spent by reveal vin n) needs the ref-to-outpoint resolution and is worth doing separately. The defect here is that the other payloads were invisible, and that is what this closes.
Verification
Plant-verified — restricting the scan back to the first input fails 4 of the 5 new cases. Cases include the 35-of-36 shape, a payload on a later input (funding inputs commonly come first), and a single-glyph case asserting the common path gained no noise.
CI-equivalent locally: 10,928 passed, 192 skipped, 1 xfailed, no unexpected skips.
🤖 Generated with Claude Code