fix(a12): decode real blockchain-config param values - #21
Merged
Merged
Conversation
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.
config.getread the real config dictionary but emittedvalue: "0"for every labeled fee param (18 storage, 20/21 gas, 24/25 fwd, 34 validators) — so A12 showed0for exactly the params that matter, and A9's storage-fee story had no real prices behind it.What this does
Decodes labeled params for real using
@ton/ton's own TL-B parsers — no hand-rolling:configParse18(storage prices), p20/p21configParseGasLimitsPrices, p24/p25configParseMsgPrices, p34parseValidatorSet.decodeConfigParam(id, cell)→{ label, value }[]; wrapped in try/catch so an unexpected tag falls back to the raw boc (never fabricated data). Raw boc is preserved for labeled params too. Theraw-param path is unchanged.Contract type (kept in lockstep)
Added
DecodedConfigField+ a namedConfigParaminterface torpc/contract.ts(valueunchanged; new optionalfields?). Updated bridge handler, mock-bridge (same shape, non-zero fixtures), andConfigPanel(renders decoded fields, Kind badge now usesparam.kind, filter/copy cover decoded values).Verification
pnpm tscgreen; bridge smokeALL OK.