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

Convert to Cargo workspace #141

Closed
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
20 changes: 10 additions & 10 deletions Cargo.lock

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

52 changes: 50 additions & 2 deletions Cargo.toml
Original file line number Diff line number Diff line change
@@ -1,10 +1,13 @@
workspace = { members = ["cairo-type-derive", "bin/hint_tool"] }
[workspace]
members = ["cairo-type-derive", "bin/hint_tool"]
resolver = "2"

[package]
edition = "2021"
name = "snos"
version = "0.1.0"

[dependencies]
[workspace.dependencies]
anyhow = "1.0.75"
assert_matches = "1.5.0"
async-stream = "0.3.5"
Expand Down Expand Up @@ -49,6 +52,51 @@ cairo-lang-semantic = { version = "~2.5.4" }
cairo-lang-sierra = { version = "~2.5.4" }
cairo-lang-syntax = { version = "~2.5.4" }

[dependencies]
anyhow = { workspace = true }
assert_matches = { workspace = true }
async-stream = { workspace = true }
base64 = { workspace = true }
bitvec = { workspace = true }
blockifier = { workspace = true }
cairo-type-derive = { workspace = true }
cairo-vm = { workspace = true }
futures = { workspace = true }
futures-util = { workspace = true }
getset = { workspace = true }
heck = { workspace = true }
hex = { workspace = true }
indexmap = { workspace = true }
indoc = { workspace = true }
lazy_static = { workspace = true }
log = { workspace = true }
num-bigint = { workspace = true }
num-integer = { workspace = true }
num-traits = { workspace = true }
regex = { workspace = true }
reqwest = { workspace = true }
serde = { workspace = true }
serde_json = { workspace = true }
serde_with = { workspace = true }
serde_yaml = { workspace = true }
starknet-crypto = { workspace = true }
starknet_api = { workspace = true }
thiserror = { workspace = true }
tokio = { workspace = true }
tokio-stream = { workspace = true }
uuid = { workspace = true }
zip = { workspace = true }

# These dependencies pin cairo-lang requirement versions because cairo-vm does not do it
cairo-lang-starknet = { workspace = true }
cairo-lang-casm = { workspace = true }
cairo-lang-defs = { workspace = true }
cairo-lang-diagnostics = { workspace = true }
cairo-lang-filesystem = { workspace = true }
cairo-lang-semantic = { workspace = true }
cairo-lang-sierra = { workspace = true }
cairo-lang-syntax = { workspace = true }

Copy link
Contributor

Choose a reason for hiding this comment

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

I hadn't thought about this duplication. This limits the interest of the workspace. I'm not sure if this is the right way to go. What do you think?

Copy link
Collaborator Author

Choose a reason for hiding this comment

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

Agreed, it's a nuisance, and isn't very valuable with only a couple minor sub-crates. I'm rather indifferent.

These dependencies would be duplicated in any case, but it would be cleaner if the crate snos was in a subdir. We could make that change while we don't have many PRs open... 🤷

[dev-dependencies]
pretty_assertions = "1.4.0"
rand = "0.8.5"
Expand Down
11 changes: 6 additions & 5 deletions bin/hint_tool/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -4,12 +4,13 @@ name = "examples"
version = "0.1.0"

[dependencies]
blockifier = { git = "https://github.com/keep-starknet-strange/blockifier", branch = "snos/callinfo-clone", features = ["clone", "testing"] }
cairo-vm = { git = "https://github.com/lambdaclass/cairo-vm", features = ["extensive_hints", "cairo-1-hints"] }
clap = { version = "4.5.4", features = ["derive"] }
serde = { version = "1.0.188", features = ["derive"] }
serde_json = { version = "1.0.105", features = ["arbitrary_precision"] }
blockifier = { workspace = true }
cairo-vm = { workspace = true }
serde = { workspace = true }
serde_json = { workspace = true }

snos = { path = "../../" }
clap = { version = "4.5.4", features = ["derive"] }

[[bin]]
name = "hint_tool"
Expand Down
Loading