Skip to content

starknet_os_flow_tests: cover all proof versions and program hashes#14042

Merged
Yoni-Starkware merged 1 commit into
mainfrom
05-10-starknet_os_flow_tests_test_tx_per_proof_version_and_program_hash
May 20, 2026
Merged

starknet_os_flow_tests: cover all proof versions and program hashes#14042
Yoni-Starkware merged 1 commit into
mainfrom
05-10-starknet_os_flow_tests_test_tx_per_proof_version_and_program_hash

Conversation

@Yoni-Starkware
Copy link
Copy Markdown
Collaborator

Summary

  • Cairo1 flow test that submits an invoke for every (ProofVersion, allowed_virtual_os_program_hash) pair.
  • Exercises the PROOF_VERSION_V0 / PROOF_VERSION_V1 acceptance path in check_proof_facts.

Test plan

  • cargo test -p starknet_os_flow_tests test_proof_facts_versions_and_program_hashes

🤖 Generated with Claude Code

@cursor
Copy link
Copy Markdown

cursor Bot commented May 17, 2026

PR Summary

Medium Risk
Moderate risk because it changes scraper error handling for L1 reorgs and updates integration-test node shutdown semantics, which can affect runtime behavior and test stability.

Overview
Adds a new starknet_os_flow_tests case that submits invokes covering all ProofVersion variants and all allowed virtual-OS program hashes.

Stabilizes and hardens test/infra: makes IntegrationTestManager::shutdown_nodes async and waits for task cancellation/port release, makes the preconfirmed block writer test deterministic via Notify instead of sleeps, and adds expect-test–backed assertions for CASM V2 (Blake) hash-estimation constants (including new blockifier testing feature dep).

Operational tweaks: increases CI cargo-deny timeout, improves Grafana panels’ log queries (and adds log queries for L1 scraper errors/reorgs), treats L1ReorgDetected as a distinct warning+early-return in the L1 events scraper, adjusts gas-price scraper error logging, removes legacy compiler-binary install/build-script paths, and bumps cairo-lang from 0.14.3a1 to 0.14.3a2 (including the prover Dockerfile and requirements).

Reviewed by Cursor Bugbot for commit 375c852. Bugbot is set up for automated code reviews on this repo. Configure here.

@reviewable-StarkWare
Copy link
Copy Markdown

This change is Reviewable

@Yoni-Starkware Yoni-Starkware force-pushed the 05-10-workspace_starknet_proof_verifier_bump_privacy-prove_and_privacy-circuit-verify_to_69ed219_add_legacy_alias_dispatch_v0_to_legacy branch from b5abe57 to e90b356 Compare May 17, 2026 15:45
@Yoni-Starkware Yoni-Starkware force-pushed the 05-10-starknet_os_flow_tests_test_tx_per_proof_version_and_program_hash branch from de6cd6b to 552cdef Compare May 17, 2026 15:47
Copy link
Copy Markdown
Contributor

@AvivYossef-starkware AvivYossef-starkware left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Do we have any negative tests?
One for not virual os hash and one for proof version?

@AvivYossef-starkware reviewed 1 file and all commit messages, and made 2 comments.
Reviewable status: all files reviewed, 1 unresolved discussion (waiting on Yoni-Starkware).


crates/starknet_os_flow_tests/src/tests.rs line 3032 at r1 (raw file):

    let test_contract = FeatureContract::TestContract(CairoVersion::Cairo1(RunnableCairo1::Casm));
    let (mut test_builder, [test_contract_address]) =
        TestBuilder::create_standard([(test_contract, calldata![Felt::ZERO, Felt::ZERO])]).await;

what is it?

Code quote:

calldata![Felt::ZERO, Felt::ZERO]

@Yoni-Starkware Yoni-Starkware force-pushed the 05-10-workspace_starknet_proof_verifier_bump_privacy-prove_and_privacy-circuit-verify_to_69ed219_add_legacy_alias_dispatch_v0_to_legacy branch 4 times, most recently from 32350e2 to 6fcaefc Compare May 18, 2026 13:54
@Yoni-Starkware Yoni-Starkware force-pushed the 05-10-starknet_os_flow_tests_test_tx_per_proof_version_and_program_hash branch from 552cdef to 3210a0e Compare May 18, 2026 14:08
Copy link
Copy Markdown
Collaborator Author

@Yoni-Starkware Yoni-Starkware left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@Yoni-Starkware made 1 comment.
Reviewable status: 0 of 1 files reviewed, 1 unresolved discussion (waiting on AvivYossef-starkware).


crates/starknet_os_flow_tests/src/tests.rs line 3032 at r1 (raw file):

Previously, AvivYossef-starkware wrote…

what is it?

Args for the constructor. Same pattern as in other tests here

@Yoni-Starkware Yoni-Starkware changed the base branch from 05-10-workspace_starknet_proof_verifier_bump_privacy-prove_and_privacy-circuit-verify_to_69ed219_add_legacy_alias_dispatch_v0_to_legacy to main May 18, 2026 14:10
Copy link
Copy Markdown
Collaborator Author

@Yoni-Starkware Yoni-Starkware left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

We don't have negative tests for the OS. We have negative unit tests for the blockifier
I added negative tests for the VIRTUAL OS since it's user-facing

@Yoni-Starkware made 1 comment.
Reviewable status: 0 of 1 files reviewed, 1 unresolved discussion (waiting on AvivYossef-starkware).

@Yoni-Starkware Yoni-Starkware force-pushed the 05-10-starknet_os_flow_tests_test_tx_per_proof_version_and_program_hash branch from 3210a0e to 5d66a74 Compare May 19, 2026 07:08
@github-actions
Copy link
Copy Markdown

github-actions Bot commented May 19, 2026

Artifacts upload workflows:

@Yoni-Starkware Yoni-Starkware changed the base branch from main to 05-10-workspace_starknet_proof_verifier_bump_privacy-prove_and_privacy-circuit-verify_to_69ed219_add_legacy_alias_dispatch_v0_to_legacy May 19, 2026 07:09
@Yoni-Starkware Yoni-Starkware force-pushed the 05-10-workspace_starknet_proof_verifier_bump_privacy-prove_and_privacy-circuit-verify_to_69ed219_add_legacy_alias_dispatch_v0_to_legacy branch from 80f6045 to 0bd2e48 Compare May 19, 2026 10:36
@Yoni-Starkware Yoni-Starkware force-pushed the 05-10-starknet_os_flow_tests_test_tx_per_proof_version_and_program_hash branch from 5d66a74 to b22c491 Compare May 19, 2026 10:37
@Yoni-Starkware Yoni-Starkware force-pushed the 05-10-workspace_starknet_proof_verifier_bump_privacy-prove_and_privacy-circuit-verify_to_69ed219_add_legacy_alias_dispatch_v0_to_legacy branch from 0bd2e48 to af06eb0 Compare May 19, 2026 11:39
@Yoni-Starkware Yoni-Starkware force-pushed the 05-10-starknet_os_flow_tests_test_tx_per_proof_version_and_program_hash branch from b22c491 to ac8abb5 Compare May 19, 2026 11:40
Adds a Cairo1 flow test that submits an invoke transaction for every
(ProofVersion, allowed_virtual_os_program_hash) pair, exercising the
PROOF_VERSION_V0/V1 acceptance path through check_proof_facts.

Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
@Yoni-Starkware Yoni-Starkware force-pushed the 05-10-starknet_os_flow_tests_test_tx_per_proof_version_and_program_hash branch from ac8abb5 to 375c852 Compare May 19, 2026 12:12
@Yoni-Starkware Yoni-Starkware changed the base branch from 05-10-workspace_starknet_proof_verifier_bump_privacy-prove_and_privacy-circuit-verify_to_69ed219_add_legacy_alias_dispatch_v0_to_legacy to main May 19, 2026 12:19
Copy link
Copy Markdown
Contributor

@AvivYossef-starkware AvivYossef-starkware left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

:lgtm:

@AvivYossef-starkware reviewed 1 file and all commit messages, made 1 comment, and resolved 1 discussion.
Reviewable status: :shipit: complete! all files reviewed, all discussions resolved (waiting on Yoni-Starkware).

Copy link
Copy Markdown
Contributor

@AvivYossef-starkware AvivYossef-starkware left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@AvivYossef-starkware made 1 comment.
Reviewable status: all files reviewed, 1 unresolved discussion (waiting on Yoni-Starkware).


crates/starknet_os_flow_tests/src/tests.rs line 3032 at r3 (raw file):

    let test_contract = FeatureContract::TestContract(CairoVersion::Cairo1(RunnableCairo1::Casm));
    let (mut test_builder, [test_contract_address]) =
        TestBuilder::create_standard([(test_contract, calldata![Felt::ZERO, Felt::ZERO])]).await;

follow up PR

Code quote:

[Felt::ZERO, Felt::ZERO])]

@Yoni-Starkware Yoni-Starkware enabled auto-merge May 19, 2026 16:00
Copy link
Copy Markdown
Collaborator Author

@Yoni-Starkware Yoni-Starkware left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@Yoni-Starkware resolved 1 discussion.
Reviewable status: :shipit: complete! all files reviewed, all discussions resolved (waiting on Yoni-Starkware).

@Yoni-Starkware Yoni-Starkware added this pull request to the merge queue May 20, 2026
Merged via the queue into main with commit a7af171 May 20, 2026
59 of 74 checks passed
@github-actions github-actions Bot locked and limited conversation to collaborators May 24, 2026
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants