Skip to content

Commit

Permalink
Relax tonic version requirements
Browse files Browse the repository at this point in the history
Currently tonic_support.rs implements a single trait Connect from tonic
(impl Connected for VsockStream). This trait is relatively stable on
the tonic side. It was modified last by
e5e311853bff347355722bc829d40f54e8954aee 3.5 years ago and was included
into tonic v0.5.0:
(see `git tag --contains e5e311853bff347355722bc829d40f54e8954aee`).

The trait has not been modified since then up to the current tonic tag
of v0.12.3. So, let's relax the dependency version requirements to
make the most recent version of tokio-vsock usable with older versions
of tonic. Motivation for this change is that in complex projects it
is not easy to move between arbitrary versions of tonic
(which is a major dependency) to be able to use the most recent
version of tokio-vsock (or use it with tonic v.0.9.x, that is not
supported by versions of tonic-vsock). Given that tonic-vsock's
dependency on tonic is very limit (impls a single relatively stable
trait), relaxing the version should be safe.

Signed-off-by: Artem Ignatyev <[email protected]>
  • Loading branch information
cryo28 committed Dec 9, 2024
1 parent c62c70c commit c1017fe
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@ futures = "0.3"
libc = "0.2.138"
vsock = "0.5.1"
tokio = { version = "1", features = ["net", "sync"] }
tonic = { version = "0.12.0", optional = true }
tonic = { version = ">= 0.5.0, < 0.13.0", optional = true }

[dev-dependencies]
sha2 = "0.10.6"
Expand Down

0 comments on commit c1017fe

Please sign in to comment.