Skip to content

chore(docs-examples): migrate to @solana/kit 8 and add transaction v1 examples - #2094

Merged
amilz merged 6 commits into
mainfrom
docs/txv1-examples-kit8
Sep 15, 2026
Merged

amilz merged 6 commits into
mainfrom
docs/txv1-examples-kit8

Conversation

@amilz

@amilz amilz commented Sep 12, 2026 •

Copy link
Copy Markdown
Contributor

Stack 1/4. Prerequisite for the v1 doc snippets in #2095.

  • Bumps @solana/kit 6 → 8 plus the kit plugins and @solana-program/* clients, which all target kit 8 now. Two real API changes: estimateComputeUnitLimitFactory → estimateResourceLimitsFactory, and token.instructions.createMint now returns a plan that must be awaited.
  • Test harness spawns the surfpool CLI instead of surfpool-sdk, whose latest release can't deserialize v1. Also drops the port-proxy indirection.
  • Adds two tested v1 examples (build/read, estimate-by-simulation).

66/66 examples pass. Hold until v1 activates on mainnet.

@vercel

vercel Bot commented Sep 12, 2026 •

Copy link
Copy Markdown

The latest updates on your projects. Learn more about Vercel for GitHub.

6 Skipped Deployments
Project Deployment Actions Updated
solana-com Skipped Skipped Sep 14, 2026 8:08pm UTC
solana-com-accelerate Skipped Skipped Sep 14, 2026 8:08pm UTC
solana-com-breakpoint-2 Skipped Skipped Sep 14, 2026 8:08pm UTC
solana-com-docs Skipped Skipped Sep 14, 2026 8:08pm UTC
solana-com-media Skipped Skipped Sep 14, 2026 8:08pm UTC
templates Skipped Skipped Sep 14, 2026 8:08pm UTC

Request Review

… examples

Transaction v1 APIs require kit 8, so the package moves off kit 6 along with
the kit plugins and the @solana-program/* clients whose current releases all
target kit 8. Two call sites needed changes: estimateComputeUnitLimitFactory
became estimateResourceLimitsFactory, and token createMint now returns a plan
that must be awaited.

The test harness moves from surfpool-sdk to @solana/surfpool, the package the
SDK was renamed to. surfpool-sdk stopped at 1.2.0, whose embedded runtime
cannot deserialize v1 transactions; @solana/surfpool 1.5.0 embeds the same
runtime as the 1.5.0 CLI and executes the v1 examples.

Running the whole cookbook in parallel against one embedded instance lets the
block height outrun a loaded runtime, expiring blockhashes mid-example, so the
surfnet takes a longer slot time to give every example wall-clock headroom.
@vercel
vercel Bot temporarily deployed to Preview – solana-com September 14, 2026 18:50 Inactive
@vercel
vercel Bot temporarily deployed to Preview – solana-com-docs September 14, 2026 18:50 Inactive
@vercel
vercel Bot temporarily deployed to Preview – solana-com-accelerate September 14, 2026 18:50 Inactive
@vercel
vercel Bot temporarily deployed to Preview – solana-com-breakpoint-2 September 14, 2026 18:50 Inactive
@vercel
vercel Bot temporarily deployed to Preview – templates September 14, 2026 18:50 Inactive
@amilz
amilz marked this pull request as ready for review September 14, 2026 19:05
@greptile-apps

greptile-apps Bot commented Sep 14, 2026 •

Copy link
Copy Markdown
Contributor

RetriggerConfidence Score: 5/5

The PR appears safe to merge once its explicitly stated transaction-v1 activation prerequisite is satisfied.

Summary

Migrates the documentation examples to @solana/kit 8, replaces the Surfpool test integration, and adds tested transaction-v1 build, read, and resource-estimation examples.

  • Updates Solana program clients and Kit plugins for Kit 8 compatibility.
  • Adds transaction-v1 documentation and executable examples.
  • Updates documentation to reflect v1 activation and behavior.
  • Stops the embedded Surfnet during test teardown.
  • Converts one media hero image from PNG to WebP.

Reviews (5) · Last reviewed commit: "fix(docs-examples): stop the surfnet on ..."

Comment thread packages/docs-examples/test/global-setup.ts
The v1 transaction examples had no page to render on, so nothing in the
cookbook transcluded them. The versions page already covers legacy and v0, so
v1 joins it there rather than getting a page of its own.

The version list becomes a comparison table, since the three formats now differ
along enough axes (size limit, address lookup tables, where resource limits
live) that a bullet per version no longer reads. Two jump links follow it: the
v0 heading is renamed to give the v0 link an anchor, and its body is unchanged.

The new section transcludes the three regions across the two example files:
building a message with explicit limits, measuring those limits by simulation,
and reading a v1 transaction back off the RPC.
@vercel
vercel Bot temporarily deployed to Preview – solana-com-media September 14, 2026 19:37 Inactive
@vercel
vercel Bot temporarily deployed to Preview – templates September 14, 2026 19:37 Inactive
@vercel
vercel Bot temporarily deployed to Preview – solana-com September 14, 2026 19:37 Inactive
@vercel
vercel Bot temporarily deployed to Preview – solana-com-accelerate September 14, 2026 19:37 Inactive
* docs: describe transaction v1 in the present tense

v1 activates on mainnet at epoch 1035, so the pages that framed it as upcoming
now describe it as live, and the RPC pages drop the 'once active' hedging.

Adds tested Kit snippets to the versioned transactions page for building a v1
message, sizing its limits by simulation, and reading one back. Also repoints
the cross-page links from #v1-message-format, an anchor that never existed, to
the #v1-format heading they were meant to target.

* docs(cookbook): describe transaction v1 in the present tense (#2096)

Drops the 'upcoming' framing now that v1 activates on mainnet, and repoints the
links from #v1-message-format, an anchor that never existed, to #v1-format.

* chore: update language
@vercel
vercel Bot temporarily deployed to Preview – solana-com-breakpoint-2 September 14, 2026 19:48 Inactive
@vercel
vercel Bot temporarily deployed to Preview – templates September 14, 2026 19:48 Inactive
@vercel
vercel Bot temporarily deployed to Preview – solana-com September 14, 2026 19:48 Inactive
@vercel
vercel Bot temporarily deployed to Preview – solana-com-accelerate September 14, 2026 19:48 Inactive
@vercel
vercel Bot temporarily deployed to Preview – solana-com-media September 14, 2026 19:48 Inactive
@vercel
vercel Bot temporarily deployed to Preview – solana-com-breakpoint-2 September 14, 2026 19:58 Inactive
@vercel
vercel Bot temporarily deployed to Preview – solana-com-accelerate September 14, 2026 19:58 Inactive
@vercel
vercel Bot temporarily deployed to Preview – templates September 14, 2026 19:58 Inactive
@vercel
vercel Bot temporarily deployed to Preview – solana-com September 14, 2026 19:58 Inactive
@vercel
vercel Bot temporarily deployed to Preview – solana-com-media September 14, 2026 19:58 Inactive
The embedded runtime owns HTTP and WebSocket servers that outlive the reference
to it, so clearing the variable left them bound. Vitest tore the process down
before it mattered for a one-shot run, but watch mode leaked an instance per
run and eventually failed to bind the proxied ports.

The proxies still close first, so the runtime sees no in-flight client sockets
while it shuts down.
@vercel
vercel Bot temporarily deployed to Preview – templates September 14, 2026 20:08 Inactive
@vercel
vercel Bot temporarily deployed to Preview – solana-com September 14, 2026 20:08 Inactive
@vercel
vercel Bot temporarily deployed to Preview – solana-com-docs September 14, 2026 20:08 Inactive
@vercel
vercel Bot temporarily deployed to Preview – solana-com-accelerate September 14, 2026 20:08 Inactive
@vercel
vercel Bot temporarily deployed to Preview – solana-com-breakpoint-2 September 14, 2026 20:08 Inactive
@vercel
vercel Bot temporarily deployed to Preview – solana-com-media September 14, 2026 20:08 Inactive
@amilz amilz self-assigned this Sep 14, 2026
@amilz
amilz requested review from Woody4618 and catmcgee September 14, 2026 20:45
@amilz amilz changed the title [DO NOT MERGE] chore(docs-examples): migrate to @solana/kit 8 and add transaction v1 examples chore(docs-examples): migrate to @solana/kit 8 and add transaction v1 examples Sep 15, 2026
@amilz
amilz merged commit c9dfb42 into main Sep 15, 2026
29 checks passed
@amilz
amilz deleted the docs/txv1-examples-kit8 branch September 15, 2026 01:29

This branch was previously deployed

6 inactive deployments
Preview – solana-com-media — 7213c256 Deployed Sep 14, 2026 by vercel[bot]
Preview – solana-com-breakpoint-2 — 7213c256 Deployed Sep 14, 2026 by vercel[bot]
Preview – solana-com-accelerate — 7213c256 Deployed Sep 14, 2026 by vercel[bot]
Preview – solana-com-docs — 7213c256 Deployed Sep 14, 2026 by vercel[bot]
Preview – solana-com — 7213c256 Deployed Sep 14, 2026 by vercel[bot]
Preview – templates — 7213c256 Deployed Sep 14, 2026 by vercel[bot]
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants