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

fix: loosen version constraints #62

Closed
wants to merge 3 commits into from
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
14 changes: 14 additions & 0 deletions .github/workflows/ci.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -55,12 +55,26 @@ jobs:
profile: default
override: true

# Install nightly which is required for supporting `-Z minimal-versions`
# https://github.com/rust-lang/cargo/issues/5657
- name: "Install Rust nightly"
uses: actions-rs/toolchain@v1
with:
toolchain: nightly
profile: minimal

- uses: Swatinem/rust-cache@v2

- uses: taiki-e/install-action@v1
with:
tool: nextest

# Install the minimal versions this package says it supports
# https://users.rust-lang.org/t/psa-please-specify-precise-dependency-versions-in-cargo-toml/71277
# https://github.com/rust-lang/cargo/issues/5657
- name: "Install minimal package versions"
run: cargo +nightly -Z minimal-versions update

- name: "Cargo ${{ matrix.cargo.name }}"
uses: actions-rs/cargo@v1
with:
Expand Down
6 changes: 3 additions & 3 deletions Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -25,10 +25,10 @@ relay_rpc = { path = "./relay_rpc", optional = true }
[dev-dependencies]
anyhow = "1"
structopt = { version = "0.3", default-features = false }
tokio = { version = "1.22", features = ["full"] }
url = "2.3"
tokio = { version = "1", features = ["full"] }
url = "2"
warp = { version = "0.3", default-features = false }
serde_json = "1.0"
serde_json = "1"

[[example]]
name = "websocket_client"
Expand Down
10 changes: 5 additions & 5 deletions relay_client/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -10,20 +10,20 @@ rustls = ["tokio-tungstenite/rustls-tls-native-roots"]
[dependencies]
relay_rpc = { path = "../relay_rpc" }
futures-util = { version = "0.3", default-features = false, features = ["sink", "std"] }
thiserror = "1.0"
serde = { version = "1.0", features = ["derive"] }
serde_json = "1.0"
thiserror = "1"
serde = { version = "1", features = ["derive"] }
serde_json = "1"
serde_qs = "0.10"
pin-project = "1.0"
chrono = { version = "0.4", default-features = false, features = ["alloc", "std"] }
url = "2.3"
url = "2"
http = "0.2"

# HTTP client dependencies.
reqwest = { version = "0.11", features = ["json"] }

# WebSocket client dependencies.
tokio = { version = "1.22", features = ["rt", "time", "sync", "macros", "rt-multi-thread"] }
tokio = { version = "1", features = ["rt", "time", "sync", "macros", "rt-multi-thread"] }
tokio-tungstenite = "0.20"
futures-channel = "0.3"
tokio-stream = "0.1"
Expand Down
22 changes: 11 additions & 11 deletions relay_rpc/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -26,32 +26,32 @@ derive_more = { version = "0.99", default-features = false, features = [
"as_ref",
"as_mut",
] }
serde = { version = "1.0", features = ["derive", "rc"] }
serde-aux = { version = "4.1", default-features = false }
serde_json = "1.0"
thiserror = "1.0"
serde = { version = "1", features = ["derive", "rc"] }
serde-aux = { version = "4", default-features = false }
serde_json = "1"
thiserror = "1"
ed25519-dalek = { git = "https://github.com/dalek-cryptography/ed25519-dalek.git", rev = "7529d65" }
rand = "0.7"
chrono = { version = "0.4", default-features = false, features = [
"std",
"clock",
] }
regex = "1.7"
once_cell = "1.16"
regex = "1"
Copy link
Collaborator

Choose a reason for hiding this comment

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

So what happens if relay_rpc is using features added in 1.7 release, while the consumer code forces e.g. 1.0 version?

Copy link
Member Author

Choose a reason for hiding this comment

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

If we needed features/fixes from the 1.7 release, then we would set the minimum to 1.7 not 1 as I did

once_cell = "1"
jsonwebtoken = "8.1"
k256 = { version = "0.13", optional = true }
sha3 = { version = "0.10", optional = true }
sha2 = { version = "0.10.6" }
sha2 = { version = "0.10" }
reqwest = { version = "0.11", features = ["default-tls"] }
url = "2"
alloy-providers = { git = "https://github.com/alloy-rs/alloy.git", rev = "e6f98e1", optional = true }
alloy-transport = { git = "https://github.com/alloy-rs/alloy.git", rev = "e6f98e1", optional = true }
alloy-transport-http = { git = "https://github.com/alloy-rs/alloy.git", rev = "e6f98e1", optional = true }
alloy-rpc-types = { git = "https://github.com/alloy-rs/alloy.git", rev = "e6f98e1", optional = true }
alloy-json-rpc = { git = "https://github.com/alloy-rs/alloy.git", rev = "e6f98e1", optional = true }
alloy-json-abi = { version = "0.6.2", optional = true }
alloy-sol-types = { version = "0.6.2", optional = true }
alloy-primitives = { version = "0.6.2", optional = true }
alloy-json-abi = { version = "0.6", optional = true }
alloy-sol-types = { version = "0.6", optional = true }
alloy-primitives = { version = "0.6", optional = true }

[dev-dependencies]
tokio = { version = "1.35.1", features = ["test-util", "macros"] }
tokio = { version = "1", features = ["test-util", "macros"] }
Loading