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(katana-executor): add blockifier executor implementations #1562

Merged
Show file tree
Hide file tree
Changes from all commits
Commits
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
89 changes: 59 additions & 30 deletions Cargo.lock

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

4 changes: 4 additions & 0 deletions Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -148,6 +148,7 @@ semver = "1.0.5"
serde = { version = "1.0.192", features = [ "derive" ] }
serde_json = { version = "1.0", features = [ "arbitrary_precision" ] }
serde_with = "2.3.1"
similar-asserts = "1.5.0"
smol_str = { version = "0.2.0", features = [ "serde" ] }
sqlx = { version = "0.7.2", features = [ "chrono", "macros", "regexp", "runtime-async-std", "runtime-tokio", "sqlite", "uuid" ] }
starknet = "0.8.0"
Expand All @@ -163,6 +164,9 @@ tracing = "0.1.34"
tracing-subscriber = { version = "0.3.16", features = [ "env-filter", "json" ] }
url = { version = "2.4.0", features = [ "serde" ] }

rstest = "0.18.2"
rstest_reuse = "0.6.0"

# server
hyper = "0.14.27"
warp = "0.3"
Expand Down
1 change: 1 addition & 0 deletions crates/katana/core/src/backend/mod.rs
Original file line number Diff line number Diff line change
Expand Up @@ -146,6 +146,7 @@ impl Backend {
let prev_hash = BlockHashProvider::latest_hash(self.blockchain.provider())?;

let partial_header = PartialHeader {
number: block_env.number,
parent_hash: prev_hash,
version: CURRENT_STARKNET_VERSION,
timestamp: block_env.timestamp,
Expand Down
7 changes: 7 additions & 0 deletions crates/katana/executor/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -21,3 +21,10 @@ tracing.workspace = true
blockifier.workspace = true
starknet_api.workspace = true
tokio.workspace = true

[dev-dependencies]
cairo-vm.workspace = true
katana-provider.workspace = true
rstest.workspace = true
serde_json.workspace = true
similar-asserts.workspace = true
3 changes: 3 additions & 0 deletions crates/katana/executor/src/abstraction.rs
Original file line number Diff line number Diff line change
Expand Up @@ -34,6 +34,9 @@ pub enum ExecutorError {

#[error(transparent)]
Other(Box<dyn std::error::Error + Send>),

#[error(transparent)]
BlockifierError(#[from] crate::implementation::blockifier::Error),
}

pub type ExecutorResult<T> = Result<T, ExecutorError>;
Expand Down
Loading
Loading