Skip to content

Fix proto_024 ManagerMetadata missing ManagerOperationMetadata methods#14

Merged
jevonearth merged 1 commit intov2from
fix/proto024-manager-metadata-interface
Mar 3, 2026
Merged

Fix proto_024 ManagerMetadata missing ManagerOperationMetadata methods#14
jevonearth merged 1 commit intov2from
fix/proto024-manager-metadata-interface

Conversation

@jevonearth
Copy link
Copy Markdown
Contributor

Summary

  • proto_024_PtTALLiN.ManagerMetadata was defined as a new struct (can't alias proto_023's because it uses proto_024's own InternalOperationResult with AddressRegistryDiff) but was missing GetResult() and GetInternalOperationResults()
  • Without these, *ManagerMetadata[T] doesn't satisfy core.ManagerOperationMetadata, so collectMilligasAndStorage silently returns (0, 0) and teztool.Fill sets gas_limit=0 / storage_limit=0 on all operations
  • Added compile-time interface satisfaction check (var _) to prevent this class of regression

Verification

Decoded an actual run_operation binary response from PtTALLiNt shadownet (https://shadownet.tezos.ecadinfra.com). Confirmed variant tag is 0x00 (with metadata, not variant 1 as initially suspected), and consumed_milligas = 2168755 is now correctly extracted.

Test plan

  • go build ./... passes
  • go test ./... passes
  • Compile-time check catches the bug (verified by temporarily removing GetResult())
  • End-to-end decode of live shadownet run_operation response extracts consumed_milligas correctly

…ethods

proto_024_PtTALLiN.ManagerMetadata was defined as a new struct (needed
because it uses proto_024's own InternalOperationResult type) but was
missing GetResult() and GetInternalOperationResults(). Without these,
*ManagerMetadata[T] does not satisfy core.ManagerOperationMetadata, so
collectMilligasAndStorage silently returns (0, 0) and teztool.Fill
sets gas_limit=0 and storage_limit=0 on all operations.

Add the missing methods and a compile-time interface satisfaction check
to prevent this class of regression.

Verified against live PtTALLiNt shadownet run_operation response:
consumed_milligas now correctly extracted.
@jevonearth jevonearth merged commit 314edca into v2 Mar 3, 2026
1 check passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant