Repository navigation
Scaffold projects with o1js 3.1 (Mesa) - #785
Open
izzetemredemir wants to merge 1 commit into
Open
izzetemredemir wants to merge 1 commit into
izzetemredemir wants to merge 1 commit into
Conversation
Template, UI scaffolds and the CLI depend on o1js ^3.1.0 instead of ^2.*. Raise engines.node to >=22.19.5 (o1js 3.1.0's floor) and move the generated project's and this repository's CI to Node 22 and 24. Make the template's coverage script use node --test --experimental-test-coverage and drop the unused Jest/Babel leftovers (o1-labs#761).
Contributor
|
Hey @izzetemredemir. Thanks for this contribution. I have one big ask to split this PR as IMHO it tackles 3 different things (though bump of node can be considered as precondition to bump o1js). I would recommend introducing 3 pr:
Thanks ! |
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.
Closes #784. Fixes #761.
Problem
New projects, examples and UI scaffolds depend on o1js
^2.*. After Mesa, the networks only accept transactions and verification keys from o1js 3.x. Details are in #784.Changes
templates/project-ts/package.json,src/lib/project.js(UI scaffolds) and the CLI'spackage.json:o1js^2.*→^3.1.0.package-lock.json: regenerated withnpm install --package-lock-only. Only the o1js subtree changes (o1js 2.0.0 → 3.1.0 and its dependencies).engines.node→>=22.19.5in the template and the CLI, the floor o1js 3.1.0 declares. README requirement updated.test-and-publish,nightly-e2e-ci-testsandpkg-pr-new-publishworkflows move from Node 18/20 to 22 (unit tests, publish) and 22/24 (E2E).release.ymlonly runsnpm versionand stays on 18.npm run coveragefails in boilerplate repo #761: the template'scoveragescript runsnode --test --experimental-test-coverageliketest. The unused@babel/*andts-jestdevDependencies,babel.config.cjsand thejestESLint env are removed. If you'd rather takenpm run coveragefails in boilerplate repo #761 separately, I can drop this part.mina-signerstays on^3.0.7. The CLI only uses it forgenKeys(), which doesn't depend on the network.Tests
On o1js 3.1.0:
npm cifrom the new lockfile,npm run build,npm run coverage. 9 suites, 247/247 on Node 22.19.0 and 24.21.0.eslint .reports no problems.prettier --checkpasses on the changed files.src/lib/constants.jsalready failsprettier --checkonmain, and this PR doesn't touch it.zk project o1js3check --ui none: installs o1js 3.1.0.npm run build,npm test(2/2:AddZkProgramproof settled onAdd),npm run coverage(2/2) andnpm run lintpass.zk example sudokuandzk example tictactoe, as the CI jobs run them:npm run test(2/2 each),npm run buildandnpm run startpass.Not run locally: the Next.js/SvelteKit/Nuxt scaffolds and the Lightnet E2E suites. The Next.js scaffold aliases
node_modules/o1js/dist/web/index.js, and that file is still there in 3.1.0. The smoke E2E jobs use thecompatible-latest-lightnetandmaster-latest-lightnetimages, and o1js 3 transactions need those images to run Mesa. I couldn't check that.This PR and #782 (Release v0.23.1) both touch
CHANGELOG.mdandpackage-lock.json. Whichever lands second will need a rebase, and I'll do it on this side.