Fix Starknet v4.0.1 docs - #237
Merged
Merged
Conversation
✅ Deploy Preview for openzeppelin-docs-v2 ready!
To edit notification comments on pull requests, go to your Netlify project configuration. |
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 subscribe to this conversation on GitHub.
Already have an account?
Sign in.
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.
Follow-up to #233, which landed the Starknet v4 docs. Fixes the defects review found in the merged pages, all of which are now live. 4.x only; one defect class per commit.
Broken example code — a markdown link path leaked into a macro arg (
erc4626.mdx); theUniversalDeployerBootstrappersnippet opened 8 braces and closed 7, withget_udc_addressdedented outside the impl (guides/deploy-udc.mdx); two imports that don't exist in v4 (udc.mdx,macros/with_components.mdx); the UDC address was a truncated0x04..., i.e. the legacy UDC, and now comes from a single{{udc_address}}constant.Wrong API signatures — 18 corrections against the cairo-contracts v4.0.1 sources, mostly in
api/governance.mdx(missingvoter/description_hash/proposal_idparams,queue_operations'u64return,CLOCK_MODE → ByteArray,executors: Span<ContractState>→Span<ContractAddress>). Elsewhere: the UDC preset'sdeploy_contractlisted theContractDeployedevent fields as parameters, camelCasetransferFromlostamount, both__validate_deploy__summaries showed(hash, signature),_token_royaltyreturnedu256s,RoleAdminChanged's admin roles were typedContractAddress,DefaultAdminDelayChangeCanceledhad no entry at all (six links dangling), and the dual IERC20/IERC20Camel listings included theIERC20Metadatafunctions.Rendering artifacts — literal
\{id\}and stripped braces inapi/erc1155.mdx, eight missing type colons, atoken_id/tokenIdmismatch, an Antora{ERC20Upgradeable-class-hash}leftover, four unbalanced escaped backticks, five backtick-wrapped links.Anchors — 85 broken fragment links, now zero. 74 headings used
[](#Some-Id)Heading, an empty link to an id rather than a definition of it, so the id was never emitted; they now use theHeading [#Some-Id]form used by the other 442 headings in the tree. The remaining 52 links were retargeted to ids that exist.Stale pins —
sncastv0.23.0 (May 2024) → v0.63.0, which required updating the commands:--urlis no longer a pre-subcommand flag,--typeis now required with--class-hash, and the fee wording changed. Also dropped a false callout claiming the JS examples need unreleasedstarknetjs@nextfeatures.Verification —
pnpm build(1049 pages) andpnpm lint:linksclean; anchors 85 → 0; signatures diffed against the v4.0.1 sources; rendered HTML spot-checked for the new anchors, the{id}text and the replacement tokens.Notes
src/lib/export-search-indexes.tsdeserves a look from whoever owns search — untouched here. Its exclusion list uses bare version substrings ("/3.x/","/4.x/"), so cairo 2.x stays indexed while 3.x is excluded, legacy overview pages leak in, one cairo carve-out line is dead, and a future"/5.x/"would silently drop Solidity's current docs.latestStable; happy to retrofit separately.span<Call>casing atapi/governance.mdx:264/:1633; the preset's undocumenteddeployContractand the related "replaced with" claim atudc.mdx:107; a secondsncastpin atguides/deploy-udc.mdx:170; andstark.estimatedFeeToMaxFeeataccounts.mdx:470, which starknet.js dropped after v6.