feat: chain name overrides + ssh-safe project name - #7
Merged
Merged
Conversation
- chain-overrides.json takes precedence over chains.json for the network name. chainid.network still lists chain 999 as Wanchain Testnet although HyperEVM reuses that id, so the registry alone can't be right. - getProjectName() now parses git@github.com:org/repo.git remotes too; with an ssh remote the markdown heading rendered as an empty "# ". - chains.json refreshed from chainid.network (adds Robinhood Chain, Arc, Tempo, MegaETH, which rendered as "Chain N" in the deployments index). Co-Authored-By: Claude Fable 5.1 <noreply@anthropic.com>
Co-Authored-By: Claude Fable 5.1 <noreply@anthropic.com>
david-uniswap
marked this pull request as ready for review
September 21, 2026 16:34
Co-Authored-By: Claude Fable 5.1 <noreply@anthropic.com>
Lets a deployment record carry provenance or deprecation warnings that reach the published markdown. Co-Authored-By: Claude Fable 5.1 <noreply@anthropic.com>
gretzke
approved these changes
Sep 21, 2026
| @@ -0,0 +1,4 @@ | |||
| { | |||
| "_comment": "Chain names that take precedence over chains.json (a snapshot of chainid.network). Use when the public registry is stale or lists a different network under the same chain id.", | |||
| "999": "HyperEVM Mainnet" | |||
Collaborator
There was a problem hiding this comment.
The chains.json refresh also renames two rows that already exist in contracts/deployments/index.md: 143 "Monad Mainnet" becomes "Monad" and 11155111 "Sepolia" becomes "Ethereum Sepolia". Fine if intended, otherwise pin the old names here.
| // works for both https://github.com/org/repo.git and git@github.com:org/repo.git | ||
| const url = execSync("git remote get-url origin", { encoding: "utf-8" }).trim(); | ||
| return url | ||
| .replace(/\.git$/, "") |
Collaborator
There was a problem hiding this comment.
A remote with a trailing slash (https://github.com/Uniswap/contracts/ or .../contracts.git/) still yields an empty name. Strip trailing slashes before the .git replace.
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.
Three small fixes found while generating the HyperEVM (999) deployment markdown in Uniswap/contracts#164:
chain-overrides.jsonwins overchains.jsonfor the network name. chainid.network still lists chain 999 as "Wanchain Testnet" although HyperEVM reuses that id, so a refresh ofchains.jsoncan never fix it on its own. Seeded with999: HyperEVM Mainnet.getProjectName()handlesgit@github.com:org/repo.gitremotes. With an ssh remote it returned an empty string and the markdown heading rendered as#.chains.jsonrefreshed (just fetch-chains). Adds Robinhood Chain, Arc, Tempo and MegaETH, which currently render as "Chain N" indeployments/index.md.noterendering: a registry entry'snotefield renders as a blockquote under its heading, so provenance or deprecation warnings reach the published markdown (chronicles previously ignored the field).Tested from inside Uniswap/contracts with
node lib/forge-chronicles -c 999 --skip-json: heading# contracts, index rowHyperEVM Mainnet, other rows pick up their names, chain markdown body unchanged.🤖 Generated with Claude Code