docs: style pass — modern test pattern, realloc/resize note, American English, lint#16
Merged
Merged
Conversation
43515d1 to
f34b3d9
Compare
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, enable autofix in the Cursor dashboard.
Reviewed by Cursor Bugbot for commit f34b3d9. Configure here.
c1db94c to
2256758
Compare
Docs and config-cleanup style pass across the repo. The only behavior-affecting code change is anchor.ts in the Token-2022 NFT metadata-pointer Next.js client, which moves a leaked API key out of source into .env.local. The other non-.md edits (make_offer.rs, update_fee.rs, hello.ts, one Anchor.toml) are pure URL/dead-config cleanup in comments and config metadata — no runtime behavior changes. Highlights: - Modernized test guidance in CONTRIBUTING and per-example READMEs: pnpm, Biome, node:test via npx tsx, solana-kite, @solana/kit, Codama clients. - New basics/realloc/README.md noting AccountInfo::realloc is deprecated in favor of AccountInfo::resize (anchor#4526) while #[account(realloc=...)] is unchanged. - Deletionist prose pass: removed filler phrases, dead Seahorse notes, and personal RPC plugs from the largest READMEs. - American English standardization (behavior, initialize, etc.). Code identifiers and CLI commands unchanged. - Markdown hygiene: one H1 per file, fenced code blocks tagged, readme.md / readme.MD renamed to README.md where casing was inconsistent. - Broken / stale URL sweep: solanacookbook.com → solana.com/developers/ cookbook, docs.anza.xyz transactions → solana.com/docs/core/transactions, docs.rs/solana-program system instructions → solana-system-interface (post-monolith-split), github.com/febo/pinocchio → anza-xyz/pinocchio (org transfer), magicblock-labs/gum-program-library → session-keys (rename), Metaplex Shank/Solita docs → GitHub repos (pages retired), Pyth/Next.js/Anchor docs path updates, Switchboard vrf-flip delinked (archived). Dead [registry] block (anchor.projectserum.com, Project Serum shut down 2022) removed from one Anchor.toml. - Moved a leaked Helius API key out of NFT metadata-pointer source into NEXT_PUBLIC_METAPLEX_READAPI_RPC env var (.env.local.example added).
2256758 to
75b1ad9
Compare
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.

Docs and config-cleanup style pass across the repo. The only behavior-affecting code change is
anchor.tsin the Token-2022 NFT metadata-pointer Next.js client, which moves a leaked API key out of source into.env.local. The other handful of non-.mdedits (make_offer.rs,update_fee.rs,hello.ts, oneAnchor.toml) are pure URL/dead-config cleanup in comments and config metadata — no runtime behavior changes. No tests, lockfiles, CI workflows, or production-relevantCargo.toml/package.jsonfiles were touched.Summary of changes
CONTRIBUTING.mdrewritten to reflect the actual toolchain:pnpm, Biome,node:testvianpx tsx --test --test-reporter=spec,solana-kite,@solana/kit, Codama clients. Removed references tots-mocha,mocha,anchor test --validator legacy,solana-test-validator,anchor.workspace, andprogram.methods.X().rpc(). Staleyarnandyarn add ts-mochainstructions in per-example READMEs were replaced withpnpm install/pnpm test.realloc→resizenote. Added a newbasics/realloc/README.mdexplaining thatAccountInfo::reallocis deprecated in favor ofAccountInfo::resize(see solana-foundation/anchor#4526), while noting that the macro-level#[account(realloc = ...)]constraint is not renamed and is still correct. The pre-existingtokens/.../tests-rs/README.mdwas already accurate onresizeand is left as-is.tokens/token-swap/,tokens/nft-operations/anchor/,tokens/token-fundraiser/anchor/,tokens/token-extensions/nft-meta-data-pointer/anchor-example/, several transfer-hook READMEs). Removed filler phrases ("Welcome to the world of...", "Let the exploration begin!", "TLDR/TRDR"), trailing whitespace blocks, dead Seahorse notes, and "Personal preference: Helius RPCs" provider plugs — replaced with neutral, factual setup instructions.pblock-list/README.md's repo-layout bullet (Solana has programs, not smart contracts). Changed "instruction" to "instruction handler" (or "handler") in prose where the sentence describes what a Rust function does, not what an on-chain instruction message contains — e.g. "thepull_leverinstruction does a CPI" → "thepull_leverinstruction handler does a CPI". Section headers## Instructionsthat list handlers and what they do are now## Instruction handlers(inpblock-list/README.mdandtoken-swap/README.md). Instances where "instruction" correctly refers to the on-chain object (e.g. "the program receives one instruction at a time", "Smaller instructions touch fewer accounts", the Token-2022 transfer-hookexecuteinstruction name, the Solana Sysvar Instructions account) are left as-is. Code identifiers (process_instruction,sysvar_instruction,instructions/init.rspaths) are untouched.rust,typescript,bash,toml,text). Trailing whitespace removed; double-blank-line runs collapsed. Renamedreadme.MD/readme.mdtoREADME.mdfortokens/nft-operations/anchor/,tokens/token-fundraiser/anchor/, and four transfer-hook READMEs so the casing is consistent.solanacookbook.com→solana.com/developers/cookbook(domain retired),docs.anza.xyz/developing/programming-model/transactions→solana.com/docs/core/transactions,docs.rs/solana-program/.../system_instruction/create_account→solana-system-interfacecrate (post-monolith split),github.com/febo/pinocchio→github.com/anza-xyz/pinocchio(org transfer),github.com/magicblock-labs/gum-program-library→magicblock-labs/session-keys(repo rename), Metaplex Shank / Solita doc pages → GitHub repos (Metaplex retired the pages), Pyth Solana docs path update, Next.js docs path update, Anchor docs path update. Switchboardvrf-fliplink removed (repo archived). Each replacement was verified with HTTP status + body inspection.NEXT_PUBLIC_METAPLEX_READAPI_RPCenv var read from.env.local, added a.env.local.exampledocumenting all three env vars, and updated the app README to mention the setup step..env*.localis already in the repo's.gitignore. The original key remains in the upstream repo's git history; worth a follow-up notification to upstream so it can be rotated.Two related cleanup PRs landed separately and this branch has been rebased onto current
mainto incorporate them:pblock-list/pino/subtree (merged).pblock-list/pinocchio/subdir (merged).Things I intentionally did not change
Cargo.toml/package.json/Anchor.toml. Exceptions are deliberate and limited:anchor.tswas changed to remove a leaked API key (env-var refactor, see above);make_offer.rs,update_fee.rs, andpages/api/hello.tshad URLs in code comments updated as part of the broken-URL sweep; oneAnchor.tomlhad a dead[registry]block (https://anchor.projectserum.com, Project Serum shut down 2022) replaced with a comment noting why it was removed.#[account(realloc = ..., realloc::payer = ..., realloc::zero = ...)]macro constraint stays asrealloc. The runtime methodAccountInfo::reallocwas the only thing renamed in anchor#4526..reference/ANCHOR-1.0-MIGRATION.md. Historical migration notes — left untouched.README.mdresolve on GitHub but not on disk; that's expected.tokens/.assets/{nft,spl-token}.json(Homer Simpson image 500, Solana coin PNG 403 hotlink) — both files are orphans in this repo; every test that uses these fixtures fetches them from the upstream mirror, so patching local copies would diverge from upstream without changing any test outcome.compression/cutils/anchorstill pins Anchor 0.26.0 due to mpl-bubblegum constraints — the README now mentions this, but the upstream pin itself wasn't changed.package.jsonfiles still referencets-mocha/solana-test-validator(didn't audit individually — out of scope).basics/counter/mpl-stackexample still requires a manual edit tots/generated/accounts/Counter.tsline 58; documented as a temporary workaround in the README.Testing
Effectively a docs-only PR. The only behavior-affecting change is the env-var refactor in
anchor.tsto remove a leaked API key; all other non-.mdedits are URL-in-comment updates or dead-config removal. Nothing to run beyond the existing CI on the base branch. Markdown link sweep showed only the expected GitHub-relative badge links as "broken" on disk (they resolve correctly on GitHub).