Fix for issue #1791: by pretty printing mangled platform_map codeblock in seed-canonical-heads.mjs#1792
Open
drQedwards wants to merge 2 commits intoMetaMask:masterfrom
Open
Fix for issue #1791: by pretty printing mangled platform_map codeblock in seed-canonical-heads.mjs#1792drQedwards wants to merge 2 commits intoMetaMask:masterfrom
drQedwards wants to merge 2 commits intoMetaMask:masterfrom
Conversation
Mangled code block now looks readable.
There was a problem hiding this comment.
Cursor Bugbot has reviewed your changes and found 1 potential issue.
❌ Bugbot Autofix is OFF. To automatically fix reported issues with cloud agents, have a team admin enable autofix in the Cursor dashboard.
Reviewed by Cursor Bugbot for commit 036802d. Configure here.
This resolves Cursor’s bug it caught while maintaining form .
Author
|
See? The bug is resolved. As I mentioned, issue #1792 only gets resolved and closed after merging this PR . Only then can the bigger issue of the mismatch error in the metadata and labeling directories for bip122 Bitcoin can be fixed and addressed. |
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.


Mangled platform_map code block now looks readable with its canonical constants to align and look like the constants for the canonical_head_group code block.
this closes and resolves issue #1791 only after this PR gets merged.
Only then can we begin fixing the issues we the mismatch errors in CAIP-2 in the metadata and labels directory when it comes to bip122, aka bitcoin having a mismatch where it is labeled in the metadata directory coherently, but not coded in the labels.
Note
High Risk
Changes the seeding script’s platform-to-CAIP mapping structure and lookup logic, which can affect how CAIP-19 IDs are generated and written to label files. It also introduces TypeScript-style annotations in a
.mjsscript, which may break runtime execution if the script is run directly by Node without transpilation.Overview
Refactors
scripts/seed-canonical-heads.mjsto make the CoinGeckoPLATFORM_MAPreadable by converting it from an object lookup into an array and updatingplatformToCaip19to use.find()(with a new warning when a platform has no mapping).Adds type annotations and minor log/summary formatting tweaks while keeping the seeding behavior the same otherwise (creating/updating
canonicalHeadentries in label JSON files).Reviewed by Cursor Bugbot for commit 2d65f8c. Bugbot is set up for automated code reviews on this repo. Configure here.