Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
27 commits
Select commit Hold shift + click to select a range
4e402f7
update: mina -> #mesa
bleepbloopsify Dec 2, 2025
3808513
recommended actions to replace setFeePerSnarkCost
bleepbloopsify Dec 3, 2025
f9331a2
need my patch
bleepbloopsify Dec 3, 2025
8cc8499
nightly release for develop-3.0 and develop
Trivo25 Dec 7, 2025
89abe20
update package-lock for engine version
Trivo25 Dec 7, 2025
59bc753
change setFeePerSnarkCost dependency on total AUs
Trivo25 Dec 7, 2025
b73d098
auto update npmDepsHash
Trivo25 Dec 7, 2025
180568c
change setFeePerSnarkCost dependency on total AUs
Trivo25 Dec 7, 2025
e53d0e6
replace perSnarkCost with perAccountUpdate
Trivo25 Dec 7, 2025
2571259
fix changeog
Trivo25 Dec 7, 2025
c7c7154
fix test
Trivo25 Dec 7, 2025
1b927ae
fix constants
Trivo25 Dec 7, 2025
a30dfda
fix max AU tests
Trivo25 Dec 7, 2025
a02a7a9
fix v2 comp tests
Trivo25 Dec 7, 2025
0a39b39
dump new vks
Trivo25 Dec 7, 2025
1bed5b3
replace with proper shared constant
Trivo25 Dec 7, 2025
1ce643b
add mesa lightnet
Trivo25 Dec 7, 2025
6223010
Merge pull request #2668 from o1-labs/florian/fix-ci-tests
Trivo25 Dec 8, 2025
f5cb171
nightly release for develop-3.0 and develop
Trivo25 Dec 7, 2025
df8003d
update package-lock for engine version
Trivo25 Dec 7, 2025
c0ee722
change setFeePerSnarkCost dependency on total AUs
Trivo25 Dec 7, 2025
01a65d8
auto update npmDepsHash
Trivo25 Dec 7, 2025
3a3c933
Merge branch 'florian/3.0-nightly-release' of https://github.com/o1-l…
Trivo25 Dec 8, 2025
8fb7c5b
rename
Trivo25 Dec 8, 2025
1d58a99
rename newFeePerAccountUpdate
Trivo25 Dec 8, 2025
0c9c2dd
mina to 25697d4a1083e280eea2964e501064f3ab2a49af as base
Trivo25 Dec 8, 2025
e5011ff
Merge pull request #2666 from o1-labs/florian/3.0-nightly-release
Trivo25 Dec 8, 2025
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
41 changes: 38 additions & 3 deletions .github/workflows/checks.yml
Original file line number Diff line number Diff line change
Expand Up @@ -234,7 +234,7 @@

echo "Running tests from index $start_index to $end_index"

shopt -s globstar

Check warning on line 237 in .github/workflows/checks.yml

View workflow job for this annotation

GitHub Actions / Lint-Format-and-Typo-Check

Unknown word (shopt)

Check warning on line 237 in .github/workflows/checks.yml

View workflow job for this annotation

GitHub Actions / Lint-Format-and-Typo-Check

Unknown word (shopt)
test_files=(./dist/node/**/*.unit-test.js)

set -o pipefail
Expand Down Expand Up @@ -319,7 +319,7 @@
needs: [Prepare]
timeout-minutes: 45
runs-on: ubuntu-latest
if: github.event.pull_request.base.ref != 'develop'
if: github.event.pull_request.base.ref == 'develop'
services:
mina-local-network:
image: o1labs/mina-local-network:master-latest-lightnet
Expand Down Expand Up @@ -355,7 +355,7 @@
needs: [Prepare]
timeout-minutes: 45
runs-on: ubuntu-latest
if: github.event.pull_request.base.ref != 'develop'
if: github.event.pull_request.base.ref == 'main'
services:
mina-local-network:
image: o1labs/mina-local-network:compatible-latest-lightnet
Expand Down Expand Up @@ -421,4 +421,39 @@
- name: Use shared steps for live testing jobs
uses: ./.github/actions/live-tests-shared
with:
mina-branch-name: develop
mina-branch-name: develop
mesa:
needs: [Prepare]
timeout-minutes: 45
runs-on: ubuntu-latest
if: github.event.pull_request.base.ref == 'develop-3.0'
services:
mina-local-network:
image: o1labs/mina-local-network:mesa-latest-lightnet
env:
NETWORK_TYPE: 'single-node'
PROOF_LEVEL: 'none'
ports:
- 3085:3085
- 5432:5432
- 8080:8080
- 8181:8181
- 8282:8282
volumes:
- /tmp:/root/logs
steps:
- name: Checkout repository
uses: actions/checkout@v4
with:
repository: ${{ inputs.target_repo || github.repository }}
ref: ${{ inputs.target_ref || github.ref }}
- name: build
uses: ./.github/actions/build
with:
repository: ${{ inputs.target_repo || github.repository }}
ref: ${{ inputs.target_ref || github.ref }}
proof_systems_commit: ${{ inputs.proof_systems_commit }}
- name: Use shared steps for live testing jobs
uses: ./.github/actions/live-tests-shared
with:
mina-branch-name: mesa
2 changes: 2 additions & 0 deletions .github/workflows/pull_requests.yml
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,8 @@ on:
types: [assigned, opened, synchronize, reopened, labeled, unlabeled]
branches:
- main
- develop
- develop-3.0
jobs:
Check-Changelog:
name: Check Changelog Action
Expand Down
5 changes: 2 additions & 3 deletions .github/workflows/push_main.yml
Original file line number Diff line number Diff line change
Expand Up @@ -6,9 +6,8 @@
- completed
branches:
- main
- v1
- v2
- v3
- develop
- develop-3.0

concurrency:
group: ${{ github.workflow }}-${{ github.ref }}
Expand Down Expand Up @@ -123,7 +122,7 @@
git tag $RELEASED_VERSION
git push origin $RELEASED_VERSION
- name: Create Release
uses: ncipollo/release-action@440c8c1cb0ed28b9f43e4d1d670870f059653174

Check warning on line 125 in .github/workflows/push_main.yml

View workflow job for this annotation

GitHub Actions / Lint-Format-and-Typo-Check

Unknown word (ncipollo)

Check warning on line 125 in .github/workflows/push_main.yml

View workflow job for this annotation

GitHub Actions / Lint-Format-and-Typo-Check

Unknown word (ncipollo)
if: success()
with:
token: ${{ secrets.GITHUB_TOKEN }}
Expand Down
6 changes: 6 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -18,6 +18,12 @@ This project adheres to

## [Unreleased](https://github.com/o1-labs/o1js/compare/c2e51a84...HEAD)

### Changed

- `Transaction.setFeePerSnarkCost` has been removed, since "snark cost" has been
removed in `mina`, replaced with `MAX_ZKAPP_SEGMENT_PER_TRANSACTION`,
simplifying calculations. Instead, use `setFeePerAccountUpdate`.

### Fixed

- Fixed an edge case that prevented the cache from being generated and read
Expand Down
2 changes: 1 addition & 1 deletion npmDepsHash
Original file line number Diff line number Diff line change
@@ -1 +1 @@
sha256-8CQBNNFXIromQdOyvdjGQIb1RNdZfevXPcu89uv0C94=
sha256-oIzUIF4Rtgjx3rPh7W4XrnldUYtVINX3cxcxdVfH/Ng=
2 changes: 1 addition & 1 deletion package-lock.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion src/lib/mina/v1/constants.ts
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@ export namespace TransactionLimits {
}

export namespace ZkappConstants {
export const MAX_ZKAPP_STATE_FIELDS = 8 as const;
export const MAX_ZKAPP_STATE_FIELDS = 32 as const;
export const ACCOUNT_ACTION_STATE_BUFFER_SIZE = 5 as const;
export const ACCOUNT_CREATION_FEE = 1000000000n as const;
}
2 changes: 1 addition & 1 deletion src/lib/mina/v1/local-blockchain.ts
Original file line number Diff line number Diff line change
Expand Up @@ -261,7 +261,7 @@ async function LocalBlockchain({ proofsEnabled = true, enforceTransactionLimits
errors,
transaction: txn.transaction,
setFee: txn.setFee,
setFeePerSnarkCost: txn.setFeePerSnarkCost,
setFeePerAccountUpdate: txn.setFeePerAccountUpdate,
hash,
toJSON: txn.toJSON,
toPretty: txn.toPretty,
Expand Down
31 changes: 14 additions & 17 deletions src/lib/mina/v1/mina-instance.ts
Original file line number Diff line number Diff line change
@@ -1,36 +1,35 @@
/**
* This module holds the global Mina instance and its interface.
*/
import { Field } from '../../provable/wrapped.js';
import { UInt64, UInt32 } from '../../provable/int.js';
import type { NetworkId } from '../../../mina-signer/src/types.js';
import { PublicKey } from '../../provable/crypto/signature.js';
import { UInt32, UInt64 } from '../../provable/int.js';
import { Field } from '../../provable/wrapped.js';
import type { EventActionFilterOptions } from '././../../mina/v1/graphql.js';
import type { NetworkId } from '../../../mina-signer/src/types.js';
import type { Account } from './account.js';
import type { NetworkValue } from './precondition.js';
import type * as Fetch from './fetch.js';
import type { TransactionPromise, PendingTransactionPromise, Transaction } from './transaction.js';
import type { NetworkValue } from './precondition.js';
import type { PendingTransactionPromise, Transaction, TransactionPromise } from './transaction.js';

export {
Mina,
FeePayerSpec,
ActionStates,
FeePayerSpec,
Mina,
NetworkConstants,
defaultNetworkConstants,
activeInstance,
setActiveInstance,
ZkappStateLength,
currentSlot,
defaultNetworkConstants,
fetchActions,
fetchEvents,
getAccount,
hasAccount,
getActions,
getBalance,
getNetworkId,
getNetworkConstants,
getNetworkId,
getNetworkState,
fetchEvents,
fetchActions,
getActions,
getProofsEnabled,
hasAccount,
setActiveInstance,
};

const defaultAccountCreationFee = 1_000_000_000;
Expand All @@ -40,8 +39,6 @@ const defaultNetworkConstants: NetworkConstants = {
accountCreationFee: UInt64.from(defaultAccountCreationFee),
};

const ZkappStateLength = 8;

/**
* Allows you to specify information about the fee payer account and the transaction.
*/
Expand Down
29 changes: 23 additions & 6 deletions src/lib/mina/v1/mina.network.unit-test.ts
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
import { UInt64, Mina, AccountUpdate, PublicKey, Field, TokenId, PrivateKey } from 'o1js';
import { describe, it, before, beforeEach, afterEach } from 'node:test';
import { expect } from 'expect';
import { afterEach, before, beforeEach, describe, it } from 'node:test';
import { AccountUpdate, Field, Mina, PrivateKey, PublicKey, TokenId, UInt64 } from 'o1js';
import { TransactionLimits } from './constants.js';

const defaultNetwork = Mina.Network({
networkId: 'testnet',
Expand Down Expand Up @@ -69,7 +70,11 @@ describe('Test default network', () => {

it('More than limit account update', async () => {
let txn = await Mina.transaction(async () => {
for (let index = 0; index < 12; index++) {
for (
let index = 0;
index < TransactionLimits.MAX_ZKAPP_SEGMENT_PER_TRANSACTION + 1;
index++
) {
const accountUpdateBob = AccountUpdate.create(bobAccount, Field.from(index));
accountUpdateBob.account.balance.requireEquals(UInt64.zero);
accountUpdateBob.balance.addInPlace(UInt64.one);
Expand Down Expand Up @@ -114,7 +119,11 @@ describe('Test enforced network', () => {

it('More than limit account update', async () => {
let txn = await Mina.transaction(async () => {
for (let index = 0; index < 12; index++) {
for (
let index = 0;
index < TransactionLimits.MAX_ZKAPP_SEGMENT_PER_TRANSACTION + 1;
index++
) {
const accountUpdateBob = AccountUpdate.create(bobAccount, Field.from(index));
accountUpdateBob.account.balance.requireEquals(UInt64.zero);
accountUpdateBob.balance.addInPlace(UInt64.one);
Expand Down Expand Up @@ -159,7 +168,11 @@ describe('Test unlimited network', () => {

it('More than limit account update', async () => {
let txn = await Mina.transaction(async () => {
for (let index = 0; index < 12; index++) {
for (
let index = 0;
index < TransactionLimits.MAX_ZKAPP_SEGMENT_PER_TRANSACTION + 1;
index++
) {
const accountUpdateBob = AccountUpdate.create(bobAccount, Field.from(index));
accountUpdateBob.account.balance.requireEquals(UInt64.zero);
accountUpdateBob.balance.addInPlace(UInt64.one);
Expand Down Expand Up @@ -252,7 +265,11 @@ describe('Test network with headers', () => {

it('More than limit account update', async () => {
let txn = await Mina.transaction(async () => {
for (let index = 0; index < 12; index++) {
for (
let index = 0;
index < TransactionLimits.MAX_ZKAPP_SEGMENT_PER_TRANSACTION + 1;
index++
) {
const accountUpdateBob = AccountUpdate.create(bobAccount, Field.from(index));
accountUpdateBob.account.balance.requireEquals(UInt64.zero);
accountUpdateBob.balance.addInPlace(UInt64.one);
Expand Down
Loading
Loading