naia-lib / naia

a cross-platform (including Wasm!) networking library built in Rust. Intended to make multiplayer game development dead-simple & lightning-fast
Apache License 2.0
878 stars 58 forks source link

naia-shared-0.12.1 build fails "cannot find attribute `derive_channels` in this scope" #88

Closed gak closed 2 years ago

gak commented 2 years ago

To reproduce, create a new cargo project and add the dependency naia-shared = "0.12.1", then build.

This also breaks the other crates because of the dependency. e.g. naia-bevy-client = "0.12.0" has the same error.

nightly-x86_64-unknown-linux-gnu (default) rustc 1.65.0-nightly (2e35f954a 2022-09-01)

error: cannot find attribute `derive_channels` in this scope
  --> /home/gak/.cargo/registry/src/github.com-1ecc6299db9ec823/naia-shared-0.12.1/src/shared_config.rs:54:3
   |
54 | #[derive_channels]
   |   ^^^^^^^^^^^^^^^
   |
   = note: consider importing one of these items:
           crate::derive_channels
           naia_derive::derive_channels

error[E0433]: failed to resolve: use of undeclared type `ChannelDirection`
  --> /home/gak/.cargo/registry/src/github.com-1ecc6299db9ec823/naia-shared-0.12.1/src/shared_config.rs:63:20
   |
63 |         direction: ChannelDirection::ClientToServer,
   |                    ^^^^^^^^^^^^^^^^ use of undeclared type `ChannelDirection`

There are a few other errors after these.

gak commented 2 years ago

Looks like this works fine on main.

gak commented 2 years ago

Closing because it probably will be fixed for the next release!