Skip to content

Commit

Permalink
chore(deps): force 0.7 version for zerocopy
Browse files Browse the repository at this point in the history
The aquatic_udp_protocol crate uses version 0.7:

https://github.com/greatest-ape/aquatic/blob/master/crates/udp_protocol/Cargo.toml#L19

We were having problems with trait `read_from`. Example:

```rust
let data = PeerId::read_from(&bytes).expect("it should have the correct amount of bytes");
```

There have been changes in version 0.8:

google/zerocopy#1680
  • Loading branch information
josecelano committed Nov 1, 2024
1 parent d5af5d3 commit e58bdeb
Show file tree
Hide file tree
Showing 4 changed files with 12 additions and 32 deletions.
38 changes: 9 additions & 29 deletions Cargo.lock

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

2 changes: 1 addition & 1 deletion Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -82,7 +82,7 @@ tracing = "0"
tracing-subscriber = { version = "0", features = ["json"] }
url = { version = "2", features = ["serde"] }
uuid = { version = "1", features = ["v4"] }
zerocopy = "0"
zerocopy = "0.7"

[package.metadata.cargo-machete]
ignored = ["crossbeam-skiplist", "dashmap", "figment", "parking_lot", "serde_bytes"]
Expand Down
2 changes: 1 addition & 1 deletion packages/primitives/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -23,4 +23,4 @@ serde = { version = "1", features = ["derive"] }
tdyne-peer-id = "1"
tdyne-peer-id-registry = "0"
thiserror = "1"
zerocopy = "0"
zerocopy = "0.7"
2 changes: 1 addition & 1 deletion packages/torrent-repository/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,7 @@ tokio = { version = "1", features = ["macros", "net", "rt-multi-thread", "signal
torrust-tracker-clock = { version = "3.0.0-develop", path = "../clock" }
torrust-tracker-configuration = { version = "3.0.0-develop", path = "../configuration" }
torrust-tracker-primitives = { version = "3.0.0-develop", path = "../primitives" }
zerocopy = "0"
zerocopy = "0.7"

[dev-dependencies]
async-std = { version = "1", features = ["attributes", "tokio1"] }
Expand Down

0 comments on commit e58bdeb

Please sign in to comment.