fix(docs): update webapp-tutorial to current wallets/PXE API + fix vite polyfill resolution#23908
Merged
Merged
Conversation
…te polyfill resolution
Thunkar
approved these changes
Jun 8, 2026
Thunkar
left a comment
Collaborator
There was a problem hiding this comment.
Cleaned up a few unfortunate comments and fmt
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.
Why
The
docsjob on themerge-train/fairies-v5→v5-nextmerge queue fails invalidate-webapp-tutorial(docs/examples/bootstrap.sh). That step rewrites the tutorial'spackage.jsontolink:the in-repo@aztec/*packages, wipesyarn.lock, does a freshyarn install, thentsc -b --noEmit+vite buildagainst current HEAD. Nothing is pinned, so the tutorial has silently drifted from the live@aztec/wallets/ PXE API and now fails to build. (Failing run: 27014367195.)Two distinct breakages, both fixed here:
1. Fatal: vite/rollup can't resolve the node-polyfill shim
vite-plugin-node-polyfillsinjects…/shims/bufferimports into modules that use theBufferglobal. Because@aztec/*arelink:ed into the monorepo, that specifier resolves from the linked package dir (where the plugin isn't installed) and fails. Fixed by adding the samenodePolyfillsFixresolveIdwrapper already used inplayground/vite.config.ts(davidmyersdev/vite-plugin-node-polyfills#81), redirecting the shim specifiers to this project's installed copy. Verifiedshims/{buffer}/dist/index.cjsexists in the pinnedvite-plugin-node-polyfills@^0.22.0.2. Type drift vs the current wallets/PXE API
EmbeddedWallet.completeFeeOptionsused the old positional signature(from, feePayer?, gasSettings?); the baseBaseWallet.completeFeeOptionsnow takes a singleCompleteFeeOptionsConfig. The override is rewritten to the new signature and now delegates tosuper.completeFeeOptions(config)(which handles gas settings, fee padding, congestion and account options), only swapping inSponsoredFeePaymentMethodwhen nofeePayerwas provided. This also drops the removedGasSettings.default(...)call.TS2684/ "connectTestAccount/getConnectedAccountdo not exist onNodeEmbeddedWallet" errors inTwoPlayerLocal.tsx/WalletConnect.tsx: it made the subclass structurally incompatible with the base constructor, soEmbeddedWallet.create()could no longer infer the subclass type. Fixing the override resolves those without touching the components.config.tssetconfig.l1Contracts = await aztecNode.getL1ContractAddresses(), butPXEConfigno longer hasl1ContractsandcreatePXEalready fetches L1 addresses from the node. Removed the line.Note on verification
I couldn't run the full linked-package docs build locally (it needs the whole
yarn-projecttoolchain built). Changes were validated against the current API source for each symbol used; thedocsjob in the merge queue is the gate. The tutorial is also identically stale onnext/v5-next, so the same fix is worth forward-porting there.Created by claudebox · group:
slackbot