Skip to content

Test asset issues in cross-complilation may imply test assets are winding up embdedded in every build. #29

@RaeveNoir

Description

@RaeveNoir

Similar to #14 I'm trying to cross-compile a game using Cross-rs. I am passing BEVY_ASSET_PATH to my containers to avoid that issue, but have run into a stranger one instead:

error: couldn't read `/target/x86_64-pc-windows-gnu/release/build/bevy_embedded_assets-f8a1a20165da7476/out/./assets/açèt.test`: No such file or directory (os error 2)
 --> /target/x86_64-pc-windows-gnu/release/build/bevy_embedded_assets-f8a1a20165da7476/out/include_all_assets.rs:4:49
  |
4 |     registry.insert_included_asset("açèt.test", include_bytes!("./assets/açèt.test"));
  |                                                 ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^

error: couldn't read `/target/x86_64-pc-windows-gnu/release/build/bevy_embedded_assets-f8a1a20165da7476/out/./assets/example_asset.test`: No such file or directory (os error 2)
 --> /target/x86_64-pc-windows-gnu/release/build/bevy_embedded_assets-f8a1a20165da7476/out/include_all_assets.rs:5:58
  |
5 |     registry.insert_included_asset("example_asset.test", include_bytes!("./assets/example_asset.test"));
  |                                                          ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^

error: couldn't read `/target/x86_64-pc-windows-gnu/release/build/bevy_embedded_assets-f8a1a20165da7476/out/./assets/subdir/other_asset.test`: No such file or directory (os error 2)
 --> /target/x86_64-pc-windows-gnu/release/build/bevy_embedded_assets-f8a1a20165da7476/out/include_all_assets.rs:6:63
  |
6 |     registry.insert_included_asset("subdir/other_asset.test", include_bytes!("./assets/subdir/other_asset.test"));
  |                                                               ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^

warning: bevy_embedded_assets@0.13.0: Asset folder found: ./assets
error: could not compile `bevy_embedded_assets` (lib) due to 3 previous errors
warning: build failed, waiting for other jobs to finish...

This appears to imply that the build script is trying to find the test assets, and when it fails it's killing the whole build. The flow here also implies that these are being embedded on every build which is trivial but incorrect.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions