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

Remove starknet_in_rust executor support #2200

Merged
merged 2 commits into from
Jul 22, 2024
Merged

Remove starknet_in_rust executor support #2200

merged 2 commits into from
Jul 22, 2024

Conversation

kariy
Copy link
Member

@kariy kariy commented Jul 22, 2024

starknet_in_rust is in process to archive their repository (https://github.com/lambdaclass/starknet_in_rust/tree/archive-repository). considering we're already on cairo 2.7 while starknet_in_rust is still on 2.6.3. make sense to remove support for it from now.

Summary by CodeRabbit

  • Chores

    • Simplified CI configuration by removing outdated comments and unused commands.
    • Streamlined dependency management in project configurations for better modularity.
    • Removed unnecessary and outdated modules related to the sir feature from the codebase.
  • Bug Fixes

    • Improved build stability by eliminating deprecated dependencies and features.
  • Tests

    • Removed test modules associated with the sir feature, streamlining the testing framework.

Copy link

coderabbitai bot commented Jul 22, 2024

Walkthrough

Ohayo, sensei! The recent changes focus on simplifying the project by removing unused features and dependencies related to the "sir" functionality. This streamlining affects both the CI configuration and various Rust module files, enhancing clarity and maintainability. The updates improve dependency management within the Cargo.toml files and eliminate redundant test cases, thus refining the overall structure and functionality of the codebase.

Changes

Files Change Summary
.github/workflows/ci.yml Removed commented-out lines related to the "sir" feature, simplifying the CI configuration.
bin/katana/Cargo.toml Updated katana-executor dependency for feature management; activated katana-rpc-api.
bin/katana/src/main.rs Removed commented-out code for the "sir" feature, simplifying the main function logic.
crates/katana/executor/Cargo.toml Removed commented-out Starknet dependencies and simplified the features section.
crates/katana/executor/src/implementation/mod.rs Eliminated commented-out sir module, enhancing module clarity.
crates/katana/executor/tests/executor.rs Removed the sir testing module and its associated test functions, affecting test coverage.
crates/katana/executor/tests/fixtures/mod.rs Removed sir fixture module, simplifying the blockifier structure.
crates/katana/executor/tests/simulate.rs Eliminated the sir test module, streamlining the testing process.

Recent review details

Configuration used: .coderabbit.yaml
Review profile: CHILL

Commits

Files that changed from the base of the PR and between 8a1a652 and bd46f85.

Files selected for processing (8)
  • .github/workflows/ci.yml (1 hunks)
  • bin/katana/Cargo.toml (2 hunks)
  • bin/katana/src/main.rs (1 hunks)
  • crates/katana/executor/Cargo.toml (2 hunks)
  • crates/katana/executor/src/implementation/mod.rs (1 hunks)
  • crates/katana/executor/tests/executor.rs (1 hunks)
  • crates/katana/executor/tests/fixtures/mod.rs (1 hunks)
  • crates/katana/executor/tests/simulate.rs (1 hunks)
Files skipped from review due to trivial changes (6)
  • .github/workflows/ci.yml
  • bin/katana/src/main.rs
  • crates/katana/executor/Cargo.toml
  • crates/katana/executor/src/implementation/mod.rs
  • crates/katana/executor/tests/executor.rs
  • crates/katana/executor/tests/simulate.rs
Additional comments not posted (3)
bin/katana/Cargo.toml (3)

18-18: Ohayo, sensei! Ensure the blockifier feature is correctly implemented.

The addition of the blockifier feature to the katana-executor dependency looks good. Please verify that this feature is correctly implemented and does not introduce any issues.


35-35: Ohayo, sensei! Ensure the default features are correctly configured.

The modification of the default feature by removing the blockifier entry looks good. Please verify that this change does not introduce any issues.


21-21: Ohayo, sensei! Ensure the inclusion of katana-rpc-api is correct.

The inclusion of katana-rpc-api in the workspace looks good. Please verify that this inclusion does not introduce any issues.

Verification successful

Ohayo, sensei! Let's ensure the inclusion of katana-rpc-api is correct by performing a more thorough check.


Ohayo, sensei! Let's dive deeper to ensure the inclusion of katana-rpc-api is correct by searching for potential usage patterns or imports in the Rust source files.


Ohayo, sensei! The inclusion of katana-rpc-api in the workspace has been verified and is actively used across multiple files in the codebase. Everything looks good!

  • katana-rpc-api is used in various modules and test files, confirming its necessity and correct implementation.
Scripts executed

The following scripts were executed for the analysis:

Script:

#!/bin/bash
# Description: Verify the usage of `katana-rpc-api` in the codebase.

# Test: Search for the usage of `katana-rpc-api`. Expect: Correct implementation without issues.
rg --type rust -A 5 $'katana-rpc-api'

Length of output: 36


Script:

#!/bin/bash
# Description: Verify the inclusion and usage of `katana-rpc-api` in the codebase.

# Step 1: Search for the dependency in all Cargo.toml files to confirm its inclusion.
rg 'katana-rpc-api' --glob '**/Cargo.toml'

# Step 2: Verify the usage of `katana-rpc-api` in the Rust source files.
rg 'katana-rpc-api' --type rust -A 10

Length of output: 708


Script:

#!/bin/bash
# Description: Verify the usage of `katana-rpc-api` in the codebase by searching for potential usage patterns or imports.

# Step 1: Search for potential usage patterns or imports related to `katana-rpc-api` in Rust source files.
rg 'katana_rpc_api' --type rust -A 10
rg 'use.*katana' --type rust -A 10

Length of output: 236181


Tips

Chat

There are 3 ways to chat with CodeRabbit:

  • Review comments: Directly reply to a review comment made by CodeRabbit. Example:
    • I pushed a fix in commit <commit_id>.
    • Generate unit testing code for this file.
    • Open a follow-up GitHub issue for this discussion.
  • Files and specific lines of code (under the "Files changed" tab): Tag @coderabbitai in a new review comment at the desired location with your query. Examples:
    • @coderabbitai generate unit testing code for this file.
    • @coderabbitai modularize this function.
  • PR comments: Tag @coderabbitai in a new PR comment to ask questions about the PR branch. For the best results, please provide a very specific query, as very limited context is provided in this mode. Examples:
    • @coderabbitai generate interesting stats about this repository and render them as a table.
    • @coderabbitai show all the console.log statements in this repository.
    • @coderabbitai read src/utils.ts and generate unit testing code.
    • @coderabbitai read the files in the src/scheduler package and generate a class diagram using mermaid and a README in the markdown format.
    • @coderabbitai help me debug CodeRabbit configuration file.

Note: Be mindful of the bot's finite context window. It's strongly recommended to break down tasks such as reading entire modules into smaller chunks. For a focused discussion, use review comments to chat about specific files and their changes, instead of using the PR comments.

CodeRabbit Commands (invoked as PR comments)

  • @coderabbitai pause to pause the reviews on a PR.
  • @coderabbitai resume to resume the paused reviews.
  • @coderabbitai review to trigger an incremental review. This is useful when automatic reviews are disabled for the repository.
  • @coderabbitai full review to do a full review from scratch and review all the files again.
  • @coderabbitai summary to regenerate the summary of the PR.
  • @coderabbitai resolve resolve all the CodeRabbit review comments.
  • @coderabbitai configuration to show the current CodeRabbit configuration for the repository.
  • @coderabbitai help to get help.

Additionally, you can add @coderabbitai ignore anywhere in the PR description to prevent this PR from being reviewed.

CodeRabbit Configuration File (.coderabbit.yaml)

  • You can programmatically configure CodeRabbit by adding a .coderabbit.yaml file to the root of your repository.
  • Please see the configuration documentation for more information.
  • If your editor has YAML language server enabled, you can add the path at the top of this file to enable auto-completion and validation: # yaml-language-server: $schema=https://coderabbit.ai/integrations/schema.v2.json

Documentation and Community

  • Visit our Documentation for detailed information on how to use CodeRabbit.
  • Join our Discord Community to get help, request features, and share feedback.
  • Follow us on X/Twitter for updates and announcements.

Copy link

codecov bot commented Jul 22, 2024

Codecov Report

All modified and coverable lines are covered by tests ✅

Project coverage is 68.19%. Comparing base (8a1a652) to head (bd46f85).

Additional details and impacted files
@@            Coverage Diff             @@
##             main    #2200      +/-   ##
==========================================
+ Coverage   68.17%   68.19%   +0.02%     
==========================================
  Files         336      336              
  Lines       44053    44038      -15     
==========================================
- Hits        30032    30031       -1     
+ Misses      14021    14007      -14     

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

@kariy kariy changed the title Remove starknet_in_rust executor support' Remove starknet_in_rust executor support Jul 22, 2024
@kariy kariy merged commit 25da1a8 into main Jul 22, 2024
15 checks passed
@kariy kariy deleted the drop-sir-support branch July 22, 2024 20:41
kariy added a commit that referenced this pull request Oct 25, 2024
also removes some unused flags. the flags were introduced back in #1561 when we were trying to integrate both blockifier and starknet_in_rust. but some of the flags (ie `skip_execute` and `skip_max_fee`) is starknet_in_rust specific. but now that we no longer need to accomodate for starknet-in-rust due to its deprecation #2200, better to just remove it to keep things simple and clean. 

I decided to rename the fields and omit the `skip_*` prefix as it gets kinda confusing sometimes, esp when we need to determine the execution flag based on the rpc flags as well ie in https://github.com/dojoengine/dojo/blob/17f25640cb2495e0223e5844e3c98f52a7aa901c/crates/katana/rpc/rpc/src/starknet/read.rs#L479-L495
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant