projectharmonia / bevy_replicon

Server-authoritative networking crate for the Bevy game engine.
https://crates.io/crates/bevy_replicon
Apache License 2.0
350 stars 31 forks source link

Faster releases #300

Closed Shatur closed 4 months ago

Shatur commented 4 months ago

The problem

renet is great, but the author is not very active and its examples depend on other third-party crates. Because of it, the crate could be behind a Bevy version. It's not a problem on its own, but since we have a small ecosystem, a release delayed due to renet delays other crates that depend on us.

Possible solutions

  1. Draft bevy_replicon release without bevy_replicon_renet when needed. This is what we do now, but users won't be able to run examples from the repo and I have to temporarely remove the crate from CI.
  2. Depend on renet directly. I tried this approach in #299. It works, but since we can't enable bevy feature on renet, we created wrappers with the same name and Deref(Mut). I think it's a bit hacky. Users will have to change their imports from something like renet::RenetServer to wrappers::RenetServer. I also have to copy-paste all available constructors since they aren't affected by Deref(Mut).
  3. Move bevy_replicon_renet into a separate repository. I will continue to maintain it as before, but this way I will be free to update bevy_replicon independently. But this also means that we won't have examples in this repo. Here is what we can do about it: 3.1 Do nothing. Just mention in readme that for examples see messaging backends. 3.2 Replace bevy_replicon_renet with bevy_replicon_renet2. But I will need to ask @UkoeHB to temporarily remove webtransport (to be able to draft a new release, blocked by h3) and remove all other examples from the repo that have dependencies on third-party crates. 3.3 Create our own simple backend that uses inter-process communication to run examples.

I think that 3(.1) will be the best solution.

UkoeHB commented 4 months ago

I think that 3(.1) will be the best solution.

This works for me. Workspaces are kind of a PITA.

Shatur commented 4 months ago

Closed by #299.