Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

feat(blockifier): support reverts in native #2271

Merged
merged 1 commit into from
Nov 25, 2024

Conversation

Yoni-Starkware
Copy link
Collaborator

No description provided.

@reviewable-StarkWare
Copy link

This change is Reviewable

Copy link

github-actions bot commented Nov 25, 2024

Artifacts upload workflows:

@ilyalesokhin-starkware
Copy link
Contributor

crates/blockifier/src/execution/syscalls/syscall_tests/call_contract.rs line 68 at r1 (raw file):

    for call in res.iter() {
        assert_eq!(call.tracked_resource, TrackedResource::SierraGas);
    }

Using SierraGas without cairo-native is not supported?

Code quote:

    // Check that the tracked resource is SierraGas to make sure that Native is running.
    for call in res.iter() {
        assert_eq!(call.tracked_resource, TrackedResource::SierraGas);
    }

Copy link
Contributor

@ilyalesokhin-starkware ilyalesokhin-starkware left a comment

Choose a reason for hiding this comment

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

Reviewed 8 of 8 files at r1, all commit messages.
Reviewable status: all files reviewed, 1 unresolved discussion (waiting on @amosStarkware, @dorimedini-starkware, and @Yoni-Starkware)

Copy link
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.

Reviewable status: 0 of 8 files reviewed, 1 unresolved discussion (waiting on @amosStarkware, @dorimedini-starkware, and @ilyalesokhin-starkware)


crates/blockifier/src/execution/syscalls/syscall_tests/call_contract.rs line 68 at r1 (raw file):

Previously, ilyalesokhin-starkware wrote…

Using SierraGas without cairo-native is not supported?

It is supported. But is the resource was CairoSteps, the Native class would be replace with casm.
This check is to verify that the native case is not replaced under the hood.

Copy link

codecov bot commented Nov 25, 2024

Codecov Report

Attention: Patch coverage is 90.90909% with 3 lines in your changes missing coverage. Please review.

Project coverage is 68.70%. Comparing base (e3165c4) to head (9692b16).
Report is 576 commits behind head on main.

Files with missing lines Patch % Lines
.../blockifier/src/execution/syscalls/syscall_base.rs 89.47% 0 Missing and 2 partials ⚠️
crates/blockifier/src/execution/syscalls/mod.rs 50.00% 0 Missing and 1 partial ⚠️
Additional details and impacted files
@@             Coverage Diff             @@
##             main    #2271       +/-   ##
===========================================
+ Coverage   40.10%   68.70%   +28.60%     
===========================================
  Files          26      108       +82     
  Lines        1895    13891    +11996     
  Branches     1895    13891    +11996     
===========================================
+ Hits          760     9544     +8784     
- Misses       1100     3937     +2837     
- Partials       35      410      +375     

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.


🚨 Try these New Features:

@Yoni-Starkware Yoni-Starkware force-pushed the yoni/syscall-handler/support-reverts-native branch from fc8224a to 9692b16 Compare November 25, 2024 13:45
@Yoni-Starkware Yoni-Starkware changed the base branch from yoni/syscall-handler/exec-inner-call-base to main November 25, 2024 13:45
Copy link
Contributor

@ilyalesokhin-starkware ilyalesokhin-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:

Reviewable status: all files reviewed, 1 unresolved discussion (waiting on @amosStarkware, @dorimedini-starkware, and @Yoni-Starkware)


crates/blockifier/src/execution/syscalls/syscall_tests/call_contract.rs line 68 at r1 (raw file):

Previously, Yoni-Starkware (Yoni) wrote…

It is supported. But is the resource was CairoSteps, the Native class would be replace with casm.
This check is to verify that the native case is not replaced under the hood.

it feels like a bad check for usage of native.

Copy link
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.

Reviewable status: all files reviewed, 1 unresolved discussion (waiting on @amosStarkware, @dorimedini-starkware, and @ilyalesokhin-starkware)


crates/blockifier/src/execution/syscalls/syscall_tests/call_contract.rs line 68 at r1 (raw file):

Previously, ilyalesokhin-starkware wrote…

it feels like a bad check for usage of native.

Native yes/no should be transparent :(
I'll think about a better indication

@Yoni-Starkware Yoni-Starkware merged commit 6b63197 into main Nov 25, 2024
13 checks passed
@github-actions github-actions bot locked and limited conversation to collaborators Nov 27, 2024
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