gfx-rs / wgpu

A cross-platform, safe, pure-Rust graphics API.
https://wgpu.rs
Apache License 2.0
12.18k stars 896 forks source link

Shader translation error for stage ShaderStages(VERTEX | FRAGMENT): new_render_pipeline_state: "Compiler encountered an internal error" #4817

Closed ekalosak closed 4 months ago

ekalosak commented 9 months ago

Summary

I encountered this error running a Bevy example cargo run --example mesh2d:

2023-12-02T22:26:01.361664Z  INFO bevy_render::renderer: AdapterInfo { name: "Intel Iris Pro Graphics", vendor: 0, device: 0, device_type: IntegratedGpu, driver: "", driver_info: "", backend: Metal }
2023-12-02T22:26:02.066572Z  INFO bevy_winit::system: Creating new window "App" (0v0)
2023-12-02T22:26:02.200397Z  INFO bevy_diagnostic::system_information_diagnostics_plugin::internal: SystemInfo { os: "MacOS 12.7 ", kernel: "21.6.0", cpu: "Intel(R) Core(TM) i7-4770HQ CPU @ 2.20GHz", core_count: "4", memory: "16.0 GiB" }
2023-12-02T22:26:03.078599Z ERROR log: Shader translation error for stage ShaderStages(VERTEX | FRAGMENT): new_render_pipeline_state: "Compiler encountered an internal error"    
2023-12-02T22:26:03.078644Z ERROR log: Please report it to https://github.com/gfx-rs/naga    
2023-12-02T22:26:03.078697Z ERROR log: Handling wgpu errors as fatal by default    
thread 'Compute Task Pool (2)' panicked at /Users/eric/.cargo/registry/src/index.crates.io-6f17d22bba15001f/wgpu-0.17.2/src/backend/direct.rs:3056:5:
wgpu error: Validation Error

Caused by:
    In Device::create_render_pipeline
      note: label = `transparent_mesh2d_pipeline`
    Internal error in ShaderStages(VERTEX | FRAGMENT) shader: new_render_pipeline_state: "Compiler encountered an internal error"

note: run with `RUST_BACKTRACE=1` environment variable to display a backtrace
Encountered a panic in system `bevy_render::render_resource::pipeline_cache::PipelineCache::process_pipeline_queue_system`!
thread 'Compute Task Pool (0)' panicked at crates/bevy_render/src/pipelined_rendering.rs:145:45:
called `Result::unwrap()` on an `Err` value: RecvError

Appreciating this may well be a Bevy error, I posted over there https://github.com/bevyengine/bevy/issues/10849. However, because the error message asks me to file here, I'm cross-posting.

teoxoy commented 9 months ago

Could you try tunning it with RUST_LOG=trace? It should log out the MSL generated by naga.

We might be missing some validation causing trouble for the Metal compiler.

jonreindeer commented 9 months ago

I think I got the same error and ran it with RUST_LOG=trace

2023-12-13T15:47:49.841266Z  INFO bevy_render::renderer: AdapterInfo { name: "Intel Iris Pro Graphics", vendor: 0, device: 0, device_type: IntegratedGpu, driver: "", driver_info: "", backend: Metal }
2023-12-13T15:47:49.977705Z  INFO bevy_winit::system: Creating new window "ncube" (0v0)
2023-12-13T15:47:50.087499Z  INFO bevy_diagnostic::system_information_diagnostics_plugin::internal: SystemInfo { os: "MacOS 12.7.1 ", kernel: "21.6.0", cpu: "Intel(R) Core(TM) i7-4980HQ CPU @ 2.80GHz", core_count: "4", memory: "16.0 GiB" }
2023-12-13T15:47:50.948881Z ERROR log: Shader translation error for stage ShaderStages(VERTEX | FRAGMENT): new_render_pipeline_state: "Compiler encountered an internal error"
2023-12-13T15:47:50.948902Z ERROR log: Please report it to https://github.com/gfx-rs/naga
2023-12-13T15:47:50.948924Z ERROR log: Handling wgpu errors as fatal by default
thread 'main' panicked at /Users/me/.cargo/registry/src/index.crates.io-6f17d22bba15001f/wgpu-0.17.2/src/backend/direct.rs:3056:5:
wgpu error: Validation Error

Caused by:
    In Device::create_render_pipeline
      note: label = `pbr_premultiplied_alpha_mesh_pipeline`
    Internal error in ShaderStages(VERTEX | FRAGMENT) shader: new_render_pipeline_state: "Compiler encountered an internal error"

note: run with `RUST_BACKTRACE=1` environment variable to display a backtrace
Encountered a panic in system `bevy_render::render_resource::pipeline_cache::PipelineCache::process_pipeline_queue_system`!
thread 'main' panicked at /Users/me/.cargo/registry/src/index.crates.io-6f17d22bba15001f/bevy_render-0.12.1/src/pipelined_rendering.rs:145:45:
called `Result::unwrap()` on an `Err` value: RecvError
teoxoy commented 9 months ago

The defaults of the logging plugin exclude wgpu and naga's logs for severities lower than error/warn.

https://github.com/bevyengine/bevy/blob/12a11e2fd0f7f6c1b907daa2782898c6f3097d1e/crates/bevy_log/src/lib.rs#L105

You should disable it or change the defaults.

olenive commented 8 months ago

So I commented out the filters in LogPlugin and also ran it with RUST_LOG=trace giving a very long trace log that starts with the following

RUST_LOG=trace cargo run --example mesh2d
    Finished dev [unoptimized + debuginfo] target(s) in 0.82s
     Running `target/debug/examples/mesh2d`
2024-01-04T22:33:29.201648Z DEBUG bevy_app::plugin_group: added plugin: bevy_core::TaskPoolPlugin
2024-01-04T22:33:29.201732Z DEBUG bevy_app::app: added plugin: bevy_core::TaskPoolPlugin
2024-01-04T22:33:29.201785Z TRACE bevy_core::task_pool_options: Assigning 8 cores to default task pools
2024-01-04T22:33:29.201804Z TRACE bevy_core::task_pool_options: IO Threads: 2
2024-01-04T22:33:29.201935Z TRACE bevy_core::task_pool_options: Async Compute Threads: 2
2024-01-04T22:33:29.202024Z TRACE bevy_core::task_pool_options: Compute Threads: 4
2024-01-04T22:33:29.202336Z DEBUG bevy_app::plugin_group: added plugin: bevy_core::TypeRegistrationPlugin
2024-01-04T22:33:29.202356Z DEBUG bevy_app::app: added plugin: bevy_core::TypeRegistrationPlugin
2024-01-04T22:33:29.203339Z DEBUG bevy_app::plugin_group: added plugin: bevy_core::FrameCountPlugin
2024-01-04T22:33:29.203353Z DEBUG bevy_app::app: added plugin: bevy_core::FrameCountPlugin
2024-01-04T22:33:29.203417Z DEBUG bevy_app::plugin_group: added plugin: bevy_time::TimePlugin
2024-01-04T22:33:29.203440Z DEBUG bevy_app::app: added plugin: bevy_time::TimePlugin
2024-01-04T22:33:29.203924Z DEBUG bevy_app::plugin_group: added plugin: bevy_transform::TransformPlugin
2024-01-04T22:33:29.203937Z DEBUG bevy_app::app: added plugin: bevy_transform::TransformPlugin
2024-01-04T22:33:29.204074Z DEBUG bevy_app::app: added plugin: bevy_hierarchy::valid_parent_check_plugin::ValidParentCheckPlugin<bevy_transform::components::global_transform::GlobalTransform>
2024-01-04T22:33:29.204371Z DEBUG bevy_app::plugin_group: added plugin: bevy_hierarchy::HierarchyPlugin
2024-01-04T22:33:29.204383Z DEBUG bevy_app::app: added plugin: bevy_hierarchy::HierarchyPlugin
2024-01-04T22:33:29.204578Z DEBUG bevy_app::plugin_group: added plugin: bevy_diagnostic::DiagnosticsPlugin
2024-01-04T22:33:29.204590Z DEBUG bevy_app::app: added plugin: bevy_diagnostic::DiagnosticsPlugin
2024-01-04T22:33:29.204677Z DEBUG bevy_app::plugin_group: added plugin: bevy_input::InputPlugin
2024-01-04T22:33:29.204698Z DEBUG bevy_app::app: added plugin: bevy_input::InputPlugin
2024-01-04T22:33:29.206169Z DEBUG bevy_app::plugin_group: added plugin: bevy_window::WindowPlugin
2024-01-04T22:33:29.206183Z DEBUG bevy_app::app: added plugin: bevy_window::WindowPlugin
2024-01-04T22:33:29.207726Z DEBUG bevy_app::plugin_group: added plugin: bevy_a11y::AccessibilityPlugin
2024-01-04T22:33:29.207741Z DEBUG bevy_app::app: added plugin: bevy_a11y::AccessibilityPlugin
2024-01-04T22:33:29.207796Z DEBUG bevy_app::plugin_group: added plugin: bevy_asset::AssetPlugin
2024-01-04T22:33:29.207805Z DEBUG bevy_app::app: added plugin: bevy_asset::AssetPlugin
2024-01-04T22:33:29.208781Z DEBUG bevy_app::plugin_group: added plugin: bevy_scene::ScenePlugin
2024-01-04T22:33:29.208795Z DEBUG bevy_app::app: added plugin: bevy_scene::ScenePlugin
2024-01-04T22:33:29.209486Z DEBUG bevy_app::plugin_group: added plugin: bevy_winit::WinitPlugin
2024-01-04T22:33:29.209500Z DEBUG bevy_app::app: added plugin: bevy_winit::WinitPlugin
2024-01-04T22:33:29.209704Z DEBUG bevy_app::app: added plugin: bevy_winit::accessibility::AccessKitPlugin
2024-01-04T22:33:29.295863Z DEBUG bevy_app::plugin_group: added plugin: bevy_render::RenderPlugin
2024-01-04T22:33:29.295895Z DEBUG bevy_app::app: added plugin: bevy_render::RenderPlugin
2024-01-04T22:33:29.296716Z DEBUG log: Instance::new: created Metal backend    
2024-01-04T22:33:29.296994Z DEBUG log: Instance::new: failed to create Gl backend: InstanceError { message: "unable to open libEGL", source: Some(Library(DlOpen { desc: "dlopen(libEGL.dylib, 0x0005): tried: \'libEGL.dylib\' (no such file), \'/Users/[redacted]/bevy/target/debug/build/blake3-fb19bf56729a5c3b/out/libEGL.dylib\' (no such file), \'/Users/[redacted]/bevy/target/debug/build/objc_exception-7e113c5746105727/out/libEGL.dylib\' (no such file), \'/Users/[redacted]/bevy/target/debug/deps/libEGL.dylib\' (no such file), \'/Users/[redacted]/bevy/target/debug/libEGL.dylib\' (no such file), \'/Users/[redacted]/.rustup/toolchains/stable-x86_64-apple-darwin/lib/rustlib/x86_64-apple-darwin/lib/libEGL.dylib\' (no such file), \'/Users/[redacted]/.rustup/toolchains/stable-x86_64-apple-darwin/lib/libEGL.dylib\' (no such file), \'/Users/[redacted]/lib/libEGL.dylib\' (no such file), \'/usr/local/lib/libEGL.dylib\' (no such file), \'/usr/lib/libEGL.dylib\' (no such file), \'/Users/[redacted]/bevy/libEGL.dylib\' (no such file)" })) }    
2024-01-04T22:33:29.297154Z TRACE log: Instance::pick_adapter    
2024-01-04T22:33:29.303123Z DEBUG log: PrivateCapabilities {

Looks like libEGL.dylib is missing but I am not sure if that is the right library for Bevy to be using here or where to get the binary. I tried copying the one that came with Chrome as a hack but that resulted in the same shader translation error as before without the complaint about about Gl backend.

cwfitzgerald commented 8 months ago

Yeah on mac you're not supposed to find the GL backend - that log is only at debug for that reason.

The shader compilation error is on metal - we need the dump of the shader that failed to compile.

olenive commented 8 months ago

So the whole log is 6000+ lines long and I can't tell which parts are relevant but it ends in the following.

2024-01-05T00:47:59.238876Z TRACE log: expression [20] = GlobalVariable([1])    
2024-01-05T00:47:59.238980Z TRACE log: statement[1] Call { function: [4], arguments: [[19], [22]], result: Some([23]) }    
2024-01-05T00:47:59.239008Z TRACE log: statement[1] Store { pointer: [4], value: [23] }    
2024-01-05T00:47:59.239021Z TRACE log: expression [4] = LocalVariable([1])    
2024-01-05T00:47:59.239034Z TRACE log: statement[1] Emit([24..24])    
2024-01-05T00:47:59.239047Z TRACE log: expression [24] = Load { pointer: [4] }    
2024-01-05T00:47:59.239058Z TRACE log: expression [4] = LocalVariable([1])    
2024-01-05T00:47:59.239069Z TRACE log: statement[1] Return { value: Some([24]) }    
2024-01-05T00:47:59.239125Z DEBUG log: Naga generated shader for entry point 'fragment' and stage Fragment
// language: metal2.4
#include <metal_stdlib>
#include <simd/simd.h>

using metal::uint;
struct DefaultConstructible {
    template<typename T>
    operator T() && {
        return T {};
    }
};

struct VertexOutputX_naga_oil_mod_XMJSXM6K7ONYHE2LUMU5DU3LFONUDEZC7OZSXE5DFPBPW65LUOB2XIX {
    metal::float4 position;
    metal::float4 world_position;
    metal::float3 world_normal;
    metal::float2 uv;
};
struct ColorGradingX_naga_oil_mod_XMJSXM6K7OJSW4ZDFOI5DU5TJMV3QX {
    float exposure;
    float gamma;
    float pre_saturation;
    float post_saturation;
};
struct type_5 {
    metal::float4 inner[6];
};
struct ViewX_naga_oil_mod_XMJSXM6K7OJSW4ZDFOI5DU5TJMV3QX {
    metal::float4x4 view_proj;
    metal::float4x4 unjittered_view_proj;
    metal::float4x4 inverse_view_proj;
    metal::float4x4 view;
    metal::float4x4 inverse_view;
    metal::float4x4 projection;
    metal::float4x4 inverse_projection;
    metal::float3 world_position;
    metal::float4 viewport;
    type_5 frustum;
    ColorGradingX_naga_oil_mod_XMJSXM6K7OJSW4ZDFOI5DU5TJMV3QX color_grading;
    float mip_bias;
    uint render_layers;
};
struct GlobalsX_naga_oil_mod_XMJSXM6K7OJSW4ZDFOI5DUZ3MN5RGC3DTX {
    float time;
    float delta_time;
    uint frame_count;
};
struct ColorMaterial {
    metal::float4 color;
    uint flags;
};
constant uint COLOR_MATERIAL_FLAGS_TEXTURE_BIT = 1u;

float tonemapping_luminanceX_naga_oil_mod_XMJSXM6K7MNXXEZK7OBUXAZLMNFXGKOR2ORXW4ZLNMFYHA2LOM4X(
    metal::float3 v
) {
    return metal::dot(v, metal::float3(0.2126, 0.7152, 0.0722));
}

metal::float3 saturationX_naga_oil_mod_XMJSXM6K7MNXXEZK7OBUXAZLMNFXGKOR2ORXW4ZLNMFYHA2LOM4X(
    metal::float3 color,
    float saturationAmount
) {
    float _e1 = tonemapping_luminanceX_naga_oil_mod_XMJSXM6K7MNXXEZK7OBUXAZLMNFXGKOR2ORXW4ZLNMFYHA2LOM4X(color);
    return metal::mix(metal::float3(_e1), color, metal::float3(saturationAmount));
}

metal::float3 powsafeX_naga_oil_mod_XMJSXM6K7MNXXEZK7OBUXAZLMNFXGKOR2ORXW4ZLNMFYHA2LOM4X(
    metal::float3 color_1,
    float power
) {
    return metal::pow(metal::abs(color_1), metal::float3(power)) * metal::sign(color_1);
}

metal::float4 tone_mappingX_naga_oil_mod_XMJSXM6K7MNXXEZK7OBUXAZLMNFXGKOR2ORXW4ZLNMFYHA2LOM4X(
    metal::float4 in,
    ColorGradingX_naga_oil_mod_XMJSXM6K7OJSW4ZDFOI5DU5TJMV3QX color_grading
) {
    metal::float3 color_2 = {};
    color_2 = metal::max(in.xyz, metal::float3(0.0));
    metal::float3 _e7 = color_2;
    metal::float3 _e9 = saturationX_naga_oil_mod_XMJSXM6K7MNXXEZK7OBUXAZLMNFXGKOR2ORXW4ZLNMFYHA2LOM4X(_e7, color_grading.pre_saturation);
    color_2 = _e9;
    metal::float3 _e10 = color_2;
    metal::float3 _e12 = powsafeX_naga_oil_mod_XMJSXM6K7MNXXEZK7OBUXAZLMNFXGKOR2ORXW4ZLNMFYHA2LOM4X(_e10, color_grading.gamma);
    color_2 = _e12;
    metal::float3 _e13 = color_2;
    metal::float3 _e17 = powsafeX_naga_oil_mod_XMJSXM6K7MNXXEZK7OBUXAZLMNFXGKOR2ORXW4ZLNMFYHA2LOM4X(metal::float3(2.0), color_grading.exposure);
    color_2 = _e13 * _e17;
    metal::float3 _e19 = color_2;
    color_2 = metal::max(_e19, metal::float3(0.0));
    metal::float3 _e23 = color_2;
    color_2 = _e23;
    metal::float3 _e24 = color_2;
    metal::float3 _e26 = saturationX_naga_oil_mod_XMJSXM6K7MNXXEZK7OBUXAZLMNFXGKOR2ORXW4ZLNMFYHA2LOM4X(_e24, color_grading.post_saturation);
    color_2 = _e26;
    metal::float3 _e27 = color_2;
    return metal::float4(_e27, in.w);
}

struct fragment_Input {
    metal::float4 world_position [[user(loc0), center_perspective]];
    metal::float3 world_normal [[user(loc1), center_perspective]];
    metal::float2 uv [[user(loc2), center_perspective]];
};
struct fragment_Output {
    metal::float4 member [[color(0)]];
};
fragment fragment_Output fragment_(
  fragment_Input varyings [[stage_in]]
, metal::float4 position [[position]]
, constant ViewX_naga_oil_mod_XMJSXM6K7OJSW4ZDFOI5DU5TJMV3QX& viewX_naga_oil_mod_XMJSXM6K7ONYHE2LUMU5DU3LFONUDEZC7OZUWK527MJUW4ZDJNZTXGX [[buffer(0)]]
, constant ColorMaterial& material [[buffer(3)]]
, metal::texture2d<float, metal::access::sample> texture [[texture(0)]]
, metal::sampler texture_sampler [[sampler(0)]]
) {
    const VertexOutputX_naga_oil_mod_XMJSXM6K7ONYHE2LUMU5DU3LFONUDEZC7OZSXE5DFPBPW65LUOB2XIX mesh = { position, varyings.world_position, varyings.world_normal, varyings.uv };
    metal::float4 output_color = {};
    metal::float4 _e2 = material.color;
    output_color = _e2;
    uint _e6 = material.flags;
    if ((_e6 & COLOR_MATERIAL_FLAGS_TEXTURE_BIT) != 0u) {
        metal::float4 _e11 = output_color;
        metal::float4 _e16 = texture.sample(texture_sampler, mesh.uv);
        output_color = _e11 * _e16;
    }
    metal::float4 _e18 = output_color;
    ColorGradingX_naga_oil_mod_XMJSXM6K7OJSW4ZDFOI5DU5TJMV3QX _e21 = viewX_naga_oil_mod_XMJSXM6K7ONYHE2LUMU5DU3LFONUDEZC7OZUWK527MJUW4ZDJNZTXGX.color_grading;
    metal::float4 _e22 = tone_mappingX_naga_oil_mod_XMJSXM6K7MNXXEZK7OBUXAZLMNFXGKOR2ORXW4ZLNMFYHA2LOM4X(_e18, _e21);
    output_color = _e22;
    metal::float4 _e23 = output_color;
    return fragment_Output { _e23 };
}

2024-01-05T00:47:59.313811Z ERROR log: Shader translation error for stage ShaderStages(VERTEX | FRAGMENT): new_render_pipeline_state: "Compiler encountered an internal error"    
2024-01-05T00:47:59.313885Z ERROR log: Please report it to https://github.com/gfx-rs/naga    
2024-01-05T00:47:59.313964Z ERROR log: Handling wgpu errors as fatal by default    
thread 'Compute Task Pool (0)' panicked at /Users/[redacted]/.cargo/registry/src/index.crates.io-6f17d22bba15001f/wgpu-0.18.0/src/backend/direct.rs:3111:5:
wgpu error: Validation Error

Caused by:
    In Device::create_render_pipeline
      note: label = `transparent_mesh2d_pipeline`
    Internal error in ShaderStages(VERTEX | FRAGMENT) shader: new_render_pipeline_state: "Compiler encountered an internal error"

note: run with `RUST_BACKTRACE=1` environment variable to display a backtrace
Encountered a panic in system `bevy_render::render_resource::pipeline_cache::PipelineCache::process_pipeline_queue_system`!
thread 'Compute Task Pool (0)' panicked at crates/bevy_render/src/pipelined_rendering.rs:145:45:
called `Result::unwrap()` on an `Err` value: RecvError
2024-01-05T00:47:59.320082Z TRACE log: Locked shared state in `fullscreen`    
2024-01-05T00:47:59.320108Z TRACE log: Unlocked shared state in `fullscreen`    
2024-01-05T00:47:59.320149Z TRACE log: Triggered `windowWillClose:`    
2024-01-05T00:47:59.320226Z TRACE log: Completed `windowWillClose:`    
2024-01-05T00:47:59.321770Z TRACE log: Triggered `viewDidMoveToWindow`    
2024-01-05T00:47:59.321848Z TRACE log: Completed `viewDidMoveToWindow`    
thread 'main' panicked at /Users/[redacted]/.cargo/registry/src/index.crates.io-6f17d22bba15001f/winit-0.29.8/src/platform_impl/macos/app_state.rs:387:33:
called `Result::unwrap()` on an `Err` value: PoisonError { .. }
teoxoy commented 8 months ago

I don't see anything wrong with the generated Metal shader. It compiles to Metal IR (tried via https://shader-playground.timjones.io/) just fine, this is probably a driver bug that happens later when compiling the Metal IR to GPU instructions.

Debugging with Xcode (see https://github.com/gfx-rs/wgpu/wiki/Debugging-with-Xcode) might tell us more.

Does upgrading OS and/or Xcode version help? Before you do, could you let us know the versions you are on right now? It would help if others run into this to know the broken versions.

jdm commented 7 months ago

Fwiw, I see this with macOS 12.7.3 and xcode 14.2. I am unable to upgrade past this because I'm using a 2015 MacBook pro that is not supported by newer macOS versions.

jdm commented 7 months ago

I updated the xcode commandline tools to xcode 14.3 and the same error appears.

alexandrasp commented 5 months ago

I'm dealing with the same kind of problem :/

2024-04-13T02:45:41.720201Z  INFO bevy_render::renderer: AdapterInfo { name: "Intel Iris Pro Graphics", vendor: 0, device: 0, device_type: IntegratedGpu, driver: "", driver_info: "", backend: Metal }
2024-04-13T02:45:42.325953Z  INFO space_bevy_xpbd_plugin: Add bevy_xpbd_3d plugin to editor
BevyXpbdPlugin::build
2024-04-13T02:45:42.513102Z  INFO bevy_winit::system: Creating new window "Space Editor" (0v1)
2024-04-13T02:45:42.579941Z  INFO space_editor_ui: Set start state
2024-04-13T02:45:42.580123Z  INFO bevy_diagnostic::system_information_diagnostics_plugin::internal: SystemInfo { os: "MacOS 12.7.4 ", kernel: "21.6.0", cpu: "Intel(R) Core(TM) i7-4980HQ CPU @ 2.80GHz", core_count: "4", memory: "16.0 GiB" }
2024-04-13T02:45:42.721990Z  WARN space_persistence: Persistence file not found at path editor.ron
2024-04-13T02:45:44.229189Z ERROR log: Device::create_render_pipeline error: Internal error in ShaderStages(VERTEX | FRAGMENT) shader: new_render_pipeline_state: "Compiler encountered an internal error"
2024-04-13T02:45:44.229232Z ERROR log: Shader translation error for stage ShaderStages(VERTEX | FRAGMENT): new_render_pipeline_state: "Compiler encountered an internal error"
2024-04-13T02:45:44.229245Z ERROR log: Please report it to https://github.com/gfx-rs/wgpu
2024-04-13T02:45:44.229287Z ERROR log: Handling wgpu errors as fatal by default
thread 'main' panicked at /Users/me/.cargo/registry/src/index.crates.io-6f17d22bba15001f/wgpu-0.19.3/src/backend/wgpu_core.rs:3006:5:
wgpu error: Validation Error

Caused by:
    In Device::create_render_pipeline
      note: label = `alpha_blend_mesh_pipeline`
    Internal error in ShaderStages(VERTEX | FRAGMENT) shader: new_render_pipeline_state: "Compiler encountered an internal error"

note: run with `RUST_BACKTRACE=1` environment variable to display a backtrace
Encountered a panic in system `bevy_core_pipeline::upscaling::prepare_view_upscaling_pipelines`!
thread 'Compute Task Pool (3)' panicked at /Users/me/.cargo/registry/src/index.crates.io-6f17d22bba15001f/bevy_render-0.13.1/src/pipelined_rendering.rs:49:67:
called `Result::unwrap()` on an `Err` value: RecvError
thread 'main' panicked at /Users/me/.cargo/registry/src/index.crates.io-6f17d22bba15001f/winit-0.29.15/src/platform_impl/macos/app_state.rs:387:33:
called `Result::unwrap()` on an `Err` value: PoisonError { .. }
ekalosak commented 4 months ago

Here is the traceback from RUST_BACKTRACE=full:

2024-04-27T14:03:42.236584Z ERROR log: Device::create_render_pipeline error: Internal error in ShaderStages(VERTEX | FRAGMENT) shader: new_render_pipeline_state: "Compiler encountered an internal error"    
2024-04-27T14:03:42.236614Z ERROR log: Shader translation error for stage ShaderStages(VERTEX | FRAGMENT): new_render_pipeline_state: "Compiler encountered an internal error"    
2024-04-27T14:03:42.236626Z ERROR log: Please report it to https://github.com/gfx-rs/wgpu    
2024-04-27T14:03:42.236694Z ERROR log: Handling wgpu errors as fatal by default    
thread 'Compute Task Pool (3)' panicked at /Users/eric/.cargo/registry/src/index.crates.io-6f17d22bba15001f/wgpu-0.19.4/src/backend/wgpu_core.rs:3006:5:
wgpu error: Validation Error

Caused by:
    In Device::create_render_pipeline
      note: label = `pbr_opaque_mesh_pipeline`
    Internal error in ShaderStages(VERTEX | FRAGMENT) shader: new_render_pipeline_state: "Compiler encountered an internal error"

stack backtrace:
   0:        0x10e940b93 - std::backtrace_rs::backtrace::libunwind::trace::heb0ed943047ae607
                               at /rustc/4d570eea025a19564429eb52b34ec34e14659f55/library/std/src/../../backtrace/src/backtrace/libunwind.rs:105:5
   1:        0x10e940b93 - std::backtrace_rs::backtrace::trace_unsynchronized::hd40c99601c69fcdc
                               at /rustc/4d570eea025a19564429eb52b34ec34e14659f55/library/std/src/../../backtrace/src/backtrace/mod.rs:66:5
   2:        0x10e940b93 - std::sys_common::backtrace::_print_fmt::h30feec6dd4416b29
                               at /rustc/4d570eea025a19564429eb52b34ec34e14659f55/library/std/src/sys_common/backtrace.rs:68:5
   3:        0x10e940b93 - <std::sys_common::backtrace::_print::DisplayBacktrace as core::fmt::Display>::fmt::hb76885d4160cbc07
                               at /rustc/4d570eea025a19564429eb52b34ec34e14659f55/library/std/src/sys_common/backtrace.rs:44:22
   4:        0x10e96252b - core::fmt::rt::Argument::fmt::h7a496fbf57cda822
                               at /rustc/4d570eea025a19564429eb52b34ec34e14659f55/library/core/src/fmt/rt.rs:165:63
   5:        0x10e96252b - core::fmt::write::hb6c7322b133ccb41
                               at /rustc/4d570eea025a19564429eb52b34ec34e14659f55/library/core/src/fmt/mod.rs:1157:21
   6:        0x10e93e55e - std::io::Write::write_fmt::h967f79c1494da52a
                               at /rustc/4d570eea025a19564429eb52b34ec34e14659f55/library/std/src/io/mod.rs:1832:15
   7:        0x10e940981 - std::sys_common::backtrace::_print::hc4ab9120a1e7fceb
                               at /rustc/4d570eea025a19564429eb52b34ec34e14659f55/library/std/src/sys_common/backtrace.rs:47:5
   8:        0x10e940981 - std::sys_common::backtrace::print::hd8bbf589af3442f4
                               at /rustc/4d570eea025a19564429eb52b34ec34e14659f55/library/std/src/sys_common/backtrace.rs:34:9
   9:        0x10e941f29 - std::panicking::default_hook::{{closure}}::h5b697a050565f751
  10:        0x10e941c70 - std::panicking::default_hook::hc1b90463f4026204
                               at /rustc/4d570eea025a19564429eb52b34ec34e14659f55/library/std/src/panicking.rs:298:9
  11:        0x10e942936 - std::panicking::rust_panic_with_hook::hb800850208fe4a44
                               at /rustc/4d570eea025a19564429eb52b34ec34e14659f55/library/std/src/panicking.rs:795:13
  12:        0x10e9422b2 - std::panicking::begin_panic_handler::{{closure}}::h5bc0ab93ecc16cc6
                               at /rustc/4d570eea025a19564429eb52b34ec34e14659f55/library/std/src/panicking.rs:664:13
  13:        0x10e941069 - std::sys_common::backtrace::__rust_end_short_backtrace::hec78ae0903d2a2d3
                               at /rustc/4d570eea025a19564429eb52b34ec34e14659f55/library/std/src/sys_common/backtrace.rs:171:18
  14:        0x10e941fe6 - rust_begin_unwind
                               at /rustc/4d570eea025a19564429eb52b34ec34e14659f55/library/std/src/panicking.rs:652:5
  15:        0x10eb30942 - core::panicking::panic_fmt::he60397b262bce7df
                               at /rustc/4d570eea025a19564429eb52b34ec34e14659f55/library/core/src/panicking.rs:72:14
  16:        0x10e0b6be5 - wgpu::backend::wgpu_core::default_error_handler::h7b6977cb7c5dfc48
                               at /Users/eric/.cargo/registry/src/index.crates.io-6f17d22bba15001f/wgpu-0.19.4/src/backend/wgpu_core.rs:3006:5
  17:        0x10e0b6be5 - core::ops::function::Fn::call::hb90e796650f14f7a
                               at /rustc/4d570eea025a19564429eb52b34ec34e14659f55/library/core/src/ops/function.rs:79:5
  18:        0x10e0c8ad0 - <alloc::boxed::Box<F,A> as core::ops::function::Fn<Args>>::call::h835c46024007fcc5
                               at /rustc/4d570eea025a19564429eb52b34ec34e14659f55/library/alloc/src/boxed.rs:2036:9
  19:        0x10e0c8ad0 - wgpu::backend::wgpu_core::ErrorSinkRaw::handle_error::h32c2cf0612ba6b73
                               at /Users/eric/.cargo/registry/src/index.crates.io-6f17d22bba15001f/wgpu-0.19.4/src/backend/wgpu_core.rs:2992:17
  20:        0x10e0c8ad0 - wgpu::backend::wgpu_core::ContextWgpuCore::handle_error::h1ce5fa65eb4204d3
                               at /Users/eric/.cargo/registry/src/index.crates.io-6f17d22bba15001f/wgpu-0.19.4/src/backend/wgpu_core.rs:262:9
  21:        0x10e0c8ad0 - <wgpu::backend::wgpu_core::ContextWgpuCore as wgpu::context::Context>::device_create_render_pipeline::he481772df5cd41e8
                               at /Users/eric/.cargo/registry/src/index.crates.io-6f17d22bba15001f/wgpu-0.19.4/src/backend/wgpu_core.rs:1152:13
  22:        0x10e0d3cbe - <T as wgpu::context::DynContext>::device_create_render_pipeline::had6ce4807274fd87
                               at /Users/eric/.cargo/registry/src/index.crates.io-6f17d22bba15001f/wgpu-0.19.4/src/context.rs:2262:13
  23:        0x10e181544 - wgpu::Device::create_render_pipeline::h230448688a1f8661
                               at /Users/eric/.cargo/registry/src/index.crates.io-6f17d22bba15001f/wgpu-0.19.4/src/lib.rs:2479:26
  24:        0x10df07b3e - bevy_render::renderer::render_device::RenderDevice::create_render_pipeline::h0d58de2ad58d86a8
                               at /Users/eric/.cargo/registry/src/index.crates.io-6f17d22bba15001f/bevy_render-0.13.2/src/renderer/render_device.rs:130:36
  25:        0x10df07b3e - bevy_render::render_resource::pipeline_cache::PipelineCache::start_create_render_pipeline::{{closure}}::h700081f920ad47a3
                               at /Users/eric/.cargo/registry/src/index.crates.io-6f17d22bba15001f/bevy_render-0.13.2/src/render_resource/pipeline_cache.rs:784:21
  26:        0x10df07b3e - futures_lite::future::block_on::{{closure}}::h9b66c905c0c37048
                               at /Users/eric/.cargo/registry/src/index.crates.io-6f17d22bba15001f/futures-lite-2.3.0/src/future.rs:99:19
  27:        0x10df07b3e - std::thread::local::LocalKey<T>::try_with::h7f525320c2a1be06
                               at /rustc/4d570eea025a19564429eb52b34ec34e14659f55/library/std/src/thread/local.rs:286:12
  28:        0x10df07b3e - std::thread::local::LocalKey<T>::with::h61c17041e383c361
                               at /rustc/4d570eea025a19564429eb52b34ec34e14659f55/library/std/src/thread/local.rs:262:9
  29:        0x10df07b3e - futures_lite::future::block_on::hb6528e0f2c7e1fd7
                               at /Users/eric/.cargo/registry/src/index.crates.io-6f17d22bba15001f/futures-lite-2.3.0/src/future.rs:78:11
  30:        0x10de919f4 - bevy_render::render_resource::pipeline_cache::create_pipeline_task::h667fd1791aad6aa3
                               at /Users/eric/.cargo/registry/src/index.crates.io-6f17d22bba15001f/bevy_render-0.13.2/src/render_resource/pipeline_cache.rs:978:11
  31:        0x10de919f4 - bevy_render::render_resource::pipeline_cache::PipelineCache::start_create_render_pipeline::h4645197101e9504e
                               at /Users/eric/.cargo/registry/src/index.crates.io-6f17d22bba15001f/bevy_render-0.13.2/src/render_resource/pipeline_cache.rs:700:9
  32:        0x10de919f4 - bevy_render::render_resource::pipeline_cache::PipelineCache::process_pipeline::h87d9cdc6ff0a94e9
                               at /Users/eric/.cargo/registry/src/index.crates.io-6f17d22bba15001f/bevy_render-0.13.2/src/render_resource/pipeline_cache.rs:876:25
  33:        0x10de919f4 - bevy_render::render_resource::pipeline_cache::PipelineCache::process_queue::h8eb207771fbbb466
                               at /Users/eric/.cargo/registry/src/index.crates.io-6f17d22bba15001f/bevy_render-0.13.2/src/render_resource/pipeline_cache.rs:865:13
  34:        0x10d8d525b - bevy_render::render_resource::pipeline_cache::PipelineCache::block_on_render_pipeline::h52381c2c582dbf04
                               at /Users/eric/.cargo/registry/src/index.crates.io-6f17d22bba15001f/bevy_render-0.13.2/src/render_resource/pipeline_cache.rs:586:13
  35:        0x10d8d525b - bevy_core_pipeline::upscaling::prepare_view_upscaling_pipelines::h2d46e99216a03a6c
                               at /Users/eric/.cargo/registry/src/index.crates.io-6f17d22bba15001f/bevy_core_pipeline-0.13.2/src/upscaling/mod.rs:53:9
  36:        0x10d8d525b - core::ops::function::FnMut::call_mut::h73381c982c3f2040
                               at /rustc/4d570eea025a19564429eb52b34ec34e14659f55/library/core/src/ops/function.rs:166:5
  37:        0x10d8d525b - core::ops::function::impls::<impl core::ops::function::FnMut<A> for &mut F>::call_mut::hf607fbdcae961e90
                               at /rustc/4d570eea025a19564429eb52b34ec34e14659f55/library/core/src/ops/function.rs:294:13
  38:        0x10d8d3c2b - <Func as bevy_ecs::system::function_system::SystemParamFunction<fn(F0,F1,F2,F3,F4) .> Out>>::run::call_inner::hd5c676021eacc800
                               at /Users/eric/.cargo/registry/src/index.crates.io-6f17d22bba15001f/bevy_ecs-0.13.2/src/system/function_system.rs:656:21
  39:        0x10d8d3c2b - <Func as bevy_ecs::system::function_system::SystemParamFunction<fn(F0,F1,F2,F3,F4) .> Out>>::run::h1d5b1f3c07ea2693
                               at /Users/eric/.cargo/registry/src/index.crates.io-6f17d22bba15001f/bevy_ecs-0.13.2/src/system/function_system.rs:659:17
  40:        0x10d8d3c2b - <bevy_ecs::system::function_system::FunctionSystem<Marker,F> as bevy_ecs::system::system::System>::run_unsafe::h5fd5d661bcaee5ad
                               at /Users/eric/.cargo/registry/src/index.crates.io-6f17d22bba15001f/bevy_ecs-0.13.2/src/system/function_system.rs:499:19
  41:        0x10e85ffe7 - bevy_ecs::schedule::executor::multi_threaded::MultiThreadedExecutor::spawn_system_task::{{closure}}::{{closure}}::he0c7ad6b5362319e
                               at /Users/eric/.cargo/registry/src/index.crates.io-6f17d22bba15001f/bevy_ecs-0.13.2/src/schedule/executor/multi_threaded.rs:534:26
  42:        0x10e85ffe7 - core::ops::function::FnOnce::call_once::h8644be2e5b80b505
                               at /rustc/4d570eea025a19564429eb52b34ec34e14659f55/library/core/src/ops/function.rs:250:5
  43:        0x10e85ffe7 - <core::panic::unwind_safe::AssertUnwindSafe<F> as core::ops::function::FnOnce<()>>::call_once::h654d016a305a8b23
                               at /rustc/4d570eea025a19564429eb52b34ec34e14659f55/library/core/src/panic/unwind_safe.rs:272:9
  44:        0x10e85ffe7 - std::panicking::try::do_call::h00e90b0b499ce3f4
                               at /rustc/4d570eea025a19564429eb52b34ec34e14659f55/library/std/src/panicking.rs:559:40
  45:        0x10e85ffe7 - std::panicking::try::h67fd7e2f1d0f6815
                               at /rustc/4d570eea025a19564429eb52b34ec34e14659f55/library/std/src/panicking.rs:523:19
  46:        0x10e85ffe7 - std::panic::catch_unwind::h47b8b49e9f74f0ff
                               at /rustc/4d570eea025a19564429eb52b34ec34e14659f55/library/std/src/panic.rs:149:14
  47:        0x10e85ffe7 - bevy_ecs::schedule::executor::multi_threaded::MultiThreadedExecutor::spawn_system_task::{{closure}}::h95ea00969604874c
                               at /Users/eric/.cargo/registry/src/index.crates.io-6f17d22bba15001f/bevy_ecs-0.13.2/src/schedule/executor/multi_threaded.rs:529:23
  48:        0x10e85ffe7 - <core::panic::unwind_safe::AssertUnwindSafe<F> as core::future::future::Future>::poll::h551a2e64dd122c91
                               at /rustc/4d570eea025a19564429eb52b34ec34e14659f55/library/core/src/panic/unwind_safe.rs:297:9
  49:        0x10e85ffe7 - <futures_lite::future::CatchUnwind<F> as core::future::future::Future>::poll::{{closure}}::hb17fdf9192b22c80
                               at /Users/eric/.cargo/registry/src/index.crates.io-6f17d22bba15001f/futures-lite-2.3.0/src/future.rs:588:42
  50:        0x10e85ffe7 - <core::panic::unwind_safe::AssertUnwindSafe<F> as core::ops::function::FnOnce<()>>::call_once::h9209b18e30377d6e
                               at /rustc/4d570eea025a19564429eb52b34ec34e14659f55/library/core/src/panic/unwind_safe.rs:272:9
  51:        0x10e85ffe7 - std::panicking::try::do_call::h6658060a1d95614d
                               at /rustc/4d570eea025a19564429eb52b34ec34e14659f55/library/std/src/panicking.rs:559:40
  52:        0x10e85ffe7 - std::panicking::try::h756798997ee3a9c4
                               at /rustc/4d570eea025a19564429eb52b34ec34e14659f55/library/std/src/panicking.rs:523:19
  53:        0x10e85ffe7 - std::panic::catch_unwind::hc2ccc0cb411c2e2e
                               at /rustc/4d570eea025a19564429eb52b34ec34e14659f55/library/std/src/panic.rs:149:14
  54:        0x10e85ffe7 - <futures_lite::future::CatchUnwind<F> as core::future::future::Future>::poll::hb9ffbf3afe1ba0c2
                               at /Users/eric/.cargo/registry/src/index.crates.io-6f17d22bba15001f/futures-lite-2.3.0/src/future.rs:588:9
  55:        0x10e85c2a9 - async_executor::Executor::spawn_inner::{{closure}}::h94b8fd48be094b09
                               at /Users/eric/.cargo/registry/src/index.crates.io-6f17d22bba15001f/async-executor-1.11.0/src/lib.rs:243:20
  56:        0x10e84d92d - async_task::raw::RawTask<F,T,S,M>::run::{{closure}}::h9f0d75f5f196d2f3
                               at /Users/eric/.cargo/registry/src/index.crates.io-6f17d22bba15001f/async-task-4.7.0/src/raw.rs:550:21
  57:        0x10e84d92d - core::ops::function::FnOnce::call_once::h316183233070dcdf
                               at /rustc/4d570eea025a19564429eb52b34ec34e14659f55/library/core/src/ops/function.rs:250:5
  58:        0x10e84d92d - <core::panic::unwind_safe::AssertUnwindSafe<F> as core::ops::function::FnOnce<()>>::call_once::h0b6a2b557d179d5c
                               at /rustc/4d570eea025a19564429eb52b34ec34e14659f55/library/core/src/panic/unwind_safe.rs:272:9
  59:        0x10e84d92d - std::panicking::try::do_call::h193ef2f795a43dba
                               at /rustc/4d570eea025a19564429eb52b34ec34e14659f55/library/std/src/panicking.rs:559:40
  60:        0x10e84d92d - std::panicking::try::hf5101e2c517e73b1
                               at /rustc/4d570eea025a19564429eb52b34ec34e14659f55/library/std/src/panicking.rs:523:19
  61:        0x10e84d92d - std::panic::catch_unwind::h098f2c9f64cccb70
                               at /rustc/4d570eea025a19564429eb52b34ec34e14659f55/library/std/src/panic.rs:149:14
  62:        0x10e84d92d - async_task::raw::RawTask<F,T,S,M>::run::h0744f09f5e7a155b
                               at /Users/eric/.cargo/registry/src/index.crates.io-6f17d22bba15001f/async-task-4.7.0/src/raw.rs:549:23
  63:        0x10e890d8b - async_task::runnable::Runnable<M>::run::hf6e79e058389d681
                               at /Users/eric/.cargo/registry/src/index.crates.io-6f17d22bba15001f/async-task-4.7.0/src/runnable.rs:781:18
  64:        0x10e890d8b - async_executor::Executor::run::{{closure}}::{{closure}}::h0e890f5a02067b94
                               at /Users/eric/.cargo/registry/src/index.crates.io-6f17d22bba15001f/async-executor-1.11.0/src/lib.rs:358:21
  65:        0x10e890d8b - <futures_lite::future::Or<F1,F2> as core::future::future::Future>::poll::h48a407f869c94c52
                               at /Users/eric/.cargo/registry/src/index.crates.io-6f17d22bba15001f/futures-lite-2.3.0/src/future.rs:449:33
  66:        0x10e890d8b - async_executor::Executor::run::{{closure}}::h278b03b82373fb0c
                               at /Users/eric/.cargo/registry/src/index.crates.io-6f17d22bba15001f/async-executor-1.11.0/src/lib.rs:365:32
  67:        0x10e890d8b - futures_lite::future::block_on::{{closure}}::h9bda75f3a443a7b5
                               at /Users/eric/.cargo/registry/src/index.crates.io-6f17d22bba15001f/futures-lite-2.3.0/src/future.rs:99:19
  68:        0x10e890d8b - std::thread::local::LocalKey<T>::try_with::hc3a34083aec3084b
                               at /rustc/4d570eea025a19564429eb52b34ec34e14659f55/library/std/src/thread/local.rs:286:12
  69:        0x10e890d8b - std::thread::local::LocalKey<T>::with::hd166454caacc3da1
                               at /rustc/4d570eea025a19564429eb52b34ec34e14659f55/library/std/src/thread/local.rs:262:9
  70:        0x10e890d8b - futures_lite::future::block_on::h00f005ca6e55568f
                               at /Users/eric/.cargo/registry/src/index.crates.io-6f17d22bba15001f/futures-lite-2.3.0/src/future.rs:78:11
  71:        0x10e89806e - bevy_tasks::task_pool::TaskPool::new_internal::{{closure}}::{{closure}}::{{closure}}::{{closure}}::h13fab7c1e409f25f
                               at /Users/eric/.cargo/registry/src/index.crates.io-6f17d22bba15001f/bevy_tasks-0.13.2/src/task_pool.rs:180:37
  72:        0x10e89806e - std::panicking::try::do_call::h624bf051ef18e44e
                               at /rustc/4d570eea025a19564429eb52b34ec34e14659f55/library/std/src/panicking.rs:559:40
  73:        0x10e89806e - std::panicking::try::h78617da09fc6a0cc
                               at /rustc/4d570eea025a19564429eb52b34ec34e14659f55/library/std/src/panicking.rs:523:19
  74:        0x10e89806e - std::panic::catch_unwind::hdccf41e82a0a6839
                               at /rustc/4d570eea025a19564429eb52b34ec34e14659f55/library/std/src/panic.rs:149:14
  75:        0x10e89806e - bevy_tasks::task_pool::TaskPool::new_internal::{{closure}}::{{closure}}::{{closure}}::h26f43b126aaa68fa
                               at /Users/eric/.cargo/registry/src/index.crates.io-6f17d22bba15001f/bevy_tasks-0.13.2/src/task_pool.rs:174:43
  76:        0x10e89806e - std::thread::local::LocalKey<T>::try_with::h26966de2da93c6f9
                               at /rustc/4d570eea025a19564429eb52b34ec34e14659f55/library/std/src/thread/local.rs:286:12
  77:        0x10e89806e - std::thread::local::LocalKey<T>::with::h05fe0adf0691c0cc
                               at /rustc/4d570eea025a19564429eb52b34ec34e14659f55/library/std/src/thread/local.rs:262:9
  78:        0x10e89806e - bevy_tasks::task_pool::TaskPool::new_internal::{{closure}}::{{closure}}::hcbaa22a03f497901
                               at /Users/eric/.cargo/registry/src/index.crates.io-6f17d22bba15001f/bevy_tasks-0.13.2/src/task_pool.rs:167:50
  79:        0x10e89806e - std::sys_common::backtrace::__rust_begin_short_backtrace::hbce227d79f6cdbd6
                               at /rustc/4d570eea025a19564429eb52b34ec34e14659f55/library/std/src/sys_common/backtrace.rs:155:18
  80:        0x10e892fcb - std::thread::Builder::spawn_unchecked_::{{closure}}::{{closure}}::h5a04c5ccd7ed44c1
                               at /rustc/4d570eea025a19564429eb52b34ec34e14659f55/library/std/src/thread/mod.rs:542:17
  81:        0x10e892fcb - <core::panic::unwind_safe::AssertUnwindSafe<F> as core::ops::function::FnOnce<()>>::call_once::h2387d2ec89d6f972
                               at /rustc/4d570eea025a19564429eb52b34ec34e14659f55/library/core/src/panic/unwind_safe.rs:272:9
  82:        0x10e892fcb - std::panicking::try::do_call::h8649518cbbd77b79
                               at /rustc/4d570eea025a19564429eb52b34ec34e14659f55/library/std/src/panicking.rs:559:40
  83:        0x10e892fcb - std::panicking::try::h5240a40576f02706
                               at /rustc/4d570eea025a19564429eb52b34ec34e14659f55/library/std/src/panicking.rs:523:19
  84:        0x10e892fcb - std::panic::catch_unwind::h2bb0863eb578a973
                               at /rustc/4d570eea025a19564429eb52b34ec34e14659f55/library/std/src/panic.rs:149:14
  85:        0x10e892fcb - std::thread::Builder::spawn_unchecked_::{{closure}}::h9b43743759124944
                               at /rustc/4d570eea025a19564429eb52b34ec34e14659f55/library/std/src/thread/mod.rs:541:30
  86:        0x10e892fcb - core::ops::function::FnOnce::call_once{{vtable.shim}}::h398e5e2f1db03f30
                               at /rustc/4d570eea025a19564429eb52b34ec34e14659f55/library/core/src/ops/function.rs:250:5
  87:        0x10e945ebb - <alloc::boxed::Box<F,A> as core::ops::function::FnOnce<Args>>::call_once::h039700ca03e33279
                               at /rustc/4d570eea025a19564429eb52b34ec34e14659f55/library/alloc/src/boxed.rs:2022:9
  88:        0x10e945ebb - <alloc::boxed::Box<F,A> as core::ops::function::FnOnce<Args>>::call_once::h244a72d885c08945
                               at /rustc/4d570eea025a19564429eb52b34ec34e14659f55/library/alloc/src/boxed.rs:2022:9
  89:        0x10e945ebb - std::sys::pal::unix::thread::Thread::new::thread_start::h8bcb0c13e5c274b3
                               at /rustc/4d570eea025a19564429eb52b34ec34e14659f55/library/std/src/sys/pal/unix/thread.rs:108:17
  90:     0x7ff81bdc34e1 - __pthread_start
Encountered a panic in system `bevy_core_pipeline::upscaling::prepare_view_upscaling_pipelines`!
thread 'Compute Task Pool (3)' panicked at /Users/eric/.cargo/registry/src/index.crates.io-6f17d22bba15001f/bevy_render-0.13.2/src/pipelined_rendering.rs:49:67:
called `Result::unwrap()` on an `Err` value: RecvError
stack backtrace:
   0:        0x10e940b93 - std::backtrace_rs::backtrace::libunwind::trace::heb0ed943047ae607
                               at /rustc/4d570eea025a19564429eb52b34ec34e14659f55/library/std/src/../../backtrace/src/backtrace/libunwind.rs:105:5
   1:        0x10e940b93 - std::backtrace_rs::backtrace::trace_unsynchronized::hd40c99601c69fcdc
                               at /rustc/4d570eea025a19564429eb52b34ec34e14659f55/library/std/src/../../backtrace/src/backtrace/mod.rs:66:5
   2:        0x10e940b93 - std::sys_common::backtrace::_print_fmt::h30feec6dd4416b29
                               at /rustc/4d570eea025a19564429eb52b34ec34e14659f55/library/std/src/sys_common/backtrace.rs:68:5
   3:        0x10e940b93 - <std::sys_common::backtrace::_print::DisplayBacktrace as core::fmt::Display>::fmt::hb76885d4160cbc07
                               at /rustc/4d570eea025a19564429eb52b34ec34e14659f55/library/std/src/sys_common/backtrace.rs:44:22
   4:        0x10e96252b - core::fmt::rt::Argument::fmt::h7a496fbf57cda822
                               at /rustc/4d570eea025a19564429eb52b34ec34e14659f55/library/core/src/fmt/rt.rs:165:63
   5:        0x10e96252b - core::fmt::write::hb6c7322b133ccb41
                               at /rustc/4d570eea025a19564429eb52b34ec34e14659f55/library/core/src/fmt/mod.rs:1157:21
   6:        0x10e93e55e - std::io::Write::write_fmt::h967f79c1494da52a
                               at /rustc/4d570eea025a19564429eb52b34ec34e14659f55/library/std/src/io/mod.rs:1832:15
   7:        0x10e940981 - std::sys_common::backtrace::_print::hc4ab9120a1e7fceb
                               at /rustc/4d570eea025a19564429eb52b34ec34e14659f55/library/std/src/sys_common/backtrace.rs:47:5
   8:        0x10e940981 - std::sys_common::backtrace::print::hd8bbf589af3442f4
                               at /rustc/4d570eea025a19564429eb52b34ec34e14659f55/library/std/src/sys_common/backtrace.rs:34:9
   9:        0x10e941f29 - std::panicking::default_hook::{{closure}}::h5b697a050565f751
  10:        0x10e941c70 - std::panicking::default_hook::hc1b90463f4026204
                               at /rustc/4d570eea025a19564429eb52b34ec34e14659f55/library/std/src/panicking.rs:298:9
  11:        0x10e942936 - std::panicking::rust_panic_with_hook::hb800850208fe4a44
                               at /rustc/4d570eea025a19564429eb52b34ec34e14659f55/library/std/src/panicking.rs:795:13
  12:        0x10e9422b2 - std::panicking::begin_panic_handler::{{closure}}::h5bc0ab93ecc16cc6
                               at /rustc/4d570eea025a19564429eb52b34ec34e14659f55/library/std/src/panicking.rs:664:13
  13:        0x10e941069 - std::sys_common::backtrace::__rust_end_short_backtrace::hec78ae0903d2a2d3
                               at /rustc/4d570eea025a19564429eb52b34ec34e14659f55/library/std/src/sys_common/backtrace.rs:171:18
  14:        0x10e941fe6 - rust_begin_unwind
                               at /rustc/4d570eea025a19564429eb52b34ec34e14659f55/library/std/src/panicking.rs:652:5
  15:        0x10eb30942 - core::panicking::panic_fmt::he60397b262bce7df
                               at /rustc/4d570eea025a19564429eb52b34ec34e14659f55/library/core/src/panicking.rs:72:14
  16:        0x10eb30f15 - core::result::unwrap_failed::hfe2dbae73644635b
                               at /rustc/4d570eea025a19564429eb52b34ec34e14659f55/library/core/src/result.rs:1654:5
  17:        0x10dcb48dd - core::result::Result<T,E>::unwrap::h057b695fd28299b0
                               at /rustc/4d570eea025a19564429eb52b34ec34e14659f55/library/core/src/result.rs:1077:23
  18:        0x10dcb48dd - bevy_render::pipelined_rendering::RenderAppChannels::recv::{{closure}}::hf7ddebaaa1bffe5e
                               at /Users/eric/.cargo/registry/src/index.crates.io-6f17d22bba15001f/bevy_render-0.13.2/src/pipelined_rendering.rs:49:26
  19:        0x10dcb48dd - bevy_render::pipelined_rendering::update_rendering::{{closure}}::{{closure}}::{{closure}}::{{closure}}::h5931e57b51845ecd
                               at /Users/eric/.cargo/registry/src/index.crates.io-6f17d22bba15001f/bevy_render-0.13.2/src/pipelined_rendering.rs:185:60
  20:        0x10dcb48dd - <core::panic::unwind_safe::AssertUnwindSafe<F> as core::future::future::Future>::poll::hda7c641b488c0e25
                               at /rustc/4d570eea025a19564429eb52b34ec34e14659f55/library/core/src/panic/unwind_safe.rs:297:9
  21:        0x10ddde93c - <futures_lite::future::CatchUnwind<F> as core::future::future::Future>::poll::{{closure}}::h3ea1365e4c310319
                               at /Users/eric/.cargo/registry/src/index.crates.io-6f17d22bba15001f/futures-lite-2.3.0/src/future.rs:588:42
  22:        0x10ddde93c - <core::panic::unwind_safe::AssertUnwindSafe<F> as core::ops::function::FnOnce<()>>::call_once::hf5625c9a57616ffc
                               at /rustc/4d570eea025a19564429eb52b34ec34e14659f55/library/core/src/panic/unwind_safe.rs:272:9
  23:        0x10ddde93c - std::panicking::try::do_call::hfbdbb3c1ec67950d
                               at /rustc/4d570eea025a19564429eb52b34ec34e14659f55/library/std/src/panicking.rs:559:40
  24:        0x10ddde93c - std::panicking::try::h134c92e5667a7700
                               at /rustc/4d570eea025a19564429eb52b34ec34e14659f55/library/std/src/panicking.rs:523:19
  25:        0x10ddde93c - std::panic::catch_unwind::heb791c8016b6cd3b
                               at /rustc/4d570eea025a19564429eb52b34ec34e14659f55/library/std/src/panic.rs:149:14
  26:        0x10ddde93c - <futures_lite::future::CatchUnwind<F> as core::future::future::Future>::poll::ha87ef3be3603f97c
                               at /Users/eric/.cargo/registry/src/index.crates.io-6f17d22bba15001f/futures-lite-2.3.0/src/future.rs:588:9
  27:        0x10ddde93c - async_executor::Executor::spawn_inner::{{closure}}::h93a400b986fb44d5
                               at /Users/eric/.cargo/registry/src/index.crates.io-6f17d22bba15001f/async-executor-1.11.0/src/lib.rs:243:20
  28:        0x10ddde93c - async_task::raw::RawTask<F,T,S,M>::run::{{closure}}::hab1c288b5cb19211
                               at /Users/eric/.cargo/registry/src/index.crates.io-6f17d22bba15001f/async-task-4.7.0/src/raw.rs:550:21
  29:        0x10ddde93c - core::ops::function::FnOnce::call_once::h920035da6363d9a9
                               at /rustc/4d570eea025a19564429eb52b34ec34e14659f55/library/core/src/ops/function.rs:250:5
  30:        0x10ddde93c - <core::panic::unwind_safe::AssertUnwindSafe<F> as core::ops::function::FnOnce<()>>::call_once::h77e8f190038417f4
                               at /rustc/4d570eea025a19564429eb52b34ec34e14659f55/library/core/src/panic/unwind_safe.rs:272:9
  31:        0x10ddde93c - std::panicking::try::do_call::h031545aadb26f1a0
                               at /rustc/4d570eea025a19564429eb52b34ec34e14659f55/library/std/src/panicking.rs:559:40
  32:        0x10ddde93c - std::panicking::try::hb5df24ed23003694
                               at /rustc/4d570eea025a19564429eb52b34ec34e14659f55/library/std/src/panicking.rs:523:19
  33:        0x10dc7134e - std::panic::catch_unwind::h5309713d8567ed59
                               at /rustc/4d570eea025a19564429eb52b34ec34e14659f55/library/std/src/panic.rs:149:14
  34:        0x10dc7134e - async_task::raw::RawTask<F,T,S,M>::run::hf17d6fc4970ec8e8
                               at /Users/eric/.cargo/registry/src/index.crates.io-6f17d22bba15001f/async-task-4.7.0/src/raw.rs:549:23
  35:        0x10e890d8b - async_task::runnable::Runnable<M>::run::hf6e79e058389d681
                               at /Users/eric/.cargo/registry/src/index.crates.io-6f17d22bba15001f/async-task-4.7.0/src/runnable.rs:781:18
  36:        0x10e890d8b - async_executor::Executor::run::{{closure}}::{{closure}}::h0e890f5a02067b94
                               at /Users/eric/.cargo/registry/src/index.crates.io-6f17d22bba15001f/async-executor-1.11.0/src/lib.rs:358:21
  37:        0x10e890d8b - <futures_lite::future::Or<F1,F2> as core::future::future::Future>::poll::h48a407f869c94c52
                               at /Users/eric/.cargo/registry/src/index.crates.io-6f17d22bba15001f/futures-lite-2.3.0/src/future.rs:449:33
  38:        0x10e890d8b - async_executor::Executor::run::{{closure}}::h278b03b82373fb0c
                               at /Users/eric/.cargo/registry/src/index.crates.io-6f17d22bba15001f/async-executor-1.11.0/src/lib.rs:365:32
  39:        0x10e890d8b - futures_lite::future::block_on::{{closure}}::h9bda75f3a443a7b5
                               at /Users/eric/.cargo/registry/src/index.crates.io-6f17d22bba15001f/futures-lite-2.3.0/src/future.rs:99:19
  40:        0x10e890d8b - std::thread::local::LocalKey<T>::try_with::hc3a34083aec3084b
                               at /rustc/4d570eea025a19564429eb52b34ec34e14659f55/library/std/src/thread/local.rs:286:12
  41:        0x10e890d8b - std::thread::local::LocalKey<T>::with::hd166454caacc3da1
                               at /rustc/4d570eea025a19564429eb52b34ec34e14659f55/library/std/src/thread/local.rs:262:9
  42:        0x10e890d8b - futures_lite::future::block_on::h00f005ca6e55568f
                               at /Users/eric/.cargo/registry/src/index.crates.io-6f17d22bba15001f/futures-lite-2.3.0/src/future.rs:78:11
  43:        0x10e89806e - bevy_tasks::task_pool::TaskPool::new_internal::{{closure}}::{{closure}}::{{closure}}::{{closure}}::h13fab7c1e409f25f
                               at /Users/eric/.cargo/registry/src/index.crates.io-6f17d22bba15001f/bevy_tasks-0.13.2/src/task_pool.rs:180:37
  44:        0x10e89806e - std::panicking::try::do_call::h624bf051ef18e44e
                               at /rustc/4d570eea025a19564429eb52b34ec34e14659f55/library/std/src/panicking.rs:559:40
  45:        0x10e89806e - std::panicking::try::h78617da09fc6a0cc
                               at /rustc/4d570eea025a19564429eb52b34ec34e14659f55/library/std/src/panicking.rs:523:19
  46:        0x10e89806e - std::panic::catch_unwind::hdccf41e82a0a6839
                               at /rustc/4d570eea025a19564429eb52b34ec34e14659f55/library/std/src/panic.rs:149:14
  47:        0x10e89806e - bevy_tasks::task_pool::TaskPool::new_internal::{{closure}}::{{closure}}::{{closure}}::h26f43b126aaa68fa
                               at /Users/eric/.cargo/registry/src/index.crates.io-6f17d22bba15001f/bevy_tasks-0.13.2/src/task_pool.rs:174:43
  48:        0x10e89806e - std::thread::local::LocalKey<T>::try_with::h26966de2da93c6f9
                               at /rustc/4d570eea025a19564429eb52b34ec34e14659f55/library/std/src/thread/local.rs:286:12
  49:        0x10e89806e - std::thread::local::LocalKey<T>::with::h05fe0adf0691c0cc
                               at /rustc/4d570eea025a19564429eb52b34ec34e14659f55/library/std/src/thread/local.rs:262:9
  50:        0x10e89806e - bevy_tasks::task_pool::TaskPool::new_internal::{{closure}}::{{closure}}::hcbaa22a03f497901
                               at /Users/eric/.cargo/registry/src/index.crates.io-6f17d22bba15001f/bevy_tasks-0.13.2/src/task_pool.rs:167:50
  51:        0x10e89806e - std::sys_common::backtrace::__rust_begin_short_backtrace::hbce227d79f6cdbd6
                               at /rustc/4d570eea025a19564429eb52b34ec34e14659f55/library/std/src/sys_common/backtrace.rs:155:18
  52:        0x10e892fcb - std::thread::Builder::spawn_unchecked_::{{closure}}::{{closure}}::h5a04c5ccd7ed44c1
                               at /rustc/4d570eea025a19564429eb52b34ec34e14659f55/library/std/src/thread/mod.rs:542:17
  53:        0x10e892fcb - <core::panic::unwind_safe::AssertUnwindSafe<F> as core::ops::function::FnOnce<()>>::call_once::h2387d2ec89d6f972
                               at /rustc/4d570eea025a19564429eb52b34ec34e14659f55/library/core/src/panic/unwind_safe.rs:272:9
  54:        0x10e892fcb - std::panicking::try::do_call::h8649518cbbd77b79
                               at /rustc/4d570eea025a19564429eb52b34ec34e14659f55/library/std/src/panicking.rs:559:40
  55:        0x10e892fcb - std::panicking::try::h5240a40576f02706
                               at /rustc/4d570eea025a19564429eb52b34ec34e14659f55/library/std/src/panicking.rs:523:19
  56:        0x10e892fcb - std::panic::catch_unwind::h2bb0863eb578a973
                               at /rustc/4d570eea025a19564429eb52b34ec34e14659f55/library/std/src/panic.rs:149:14
  57:        0x10e892fcb - std::thread::Builder::spawn_unchecked_::{{closure}}::h9b43743759124944
                               at /rustc/4d570eea025a19564429eb52b34ec34e14659f55/library/std/src/thread/mod.rs:541:30
  58:        0x10e892fcb - core::ops::function::FnOnce::call_once{{vtable.shim}}::h398e5e2f1db03f30
                               at /rustc/4d570eea025a19564429eb52b34ec34e14659f55/library/core/src/ops/function.rs:250:5
  59:        0x10e945ebb - <alloc::boxed::Box<F,A> as core::ops::function::FnOnce<Args>>::call_once::h039700ca03e33279
                               at /rustc/4d570eea025a19564429eb52b34ec34e14659f55/library/alloc/src/boxed.rs:2022:9
  60:        0x10e945ebb - <alloc::boxed::Box<F,A> as core::ops::function::FnOnce<Args>>::call_once::h244a72d885c08945
                               at /rustc/4d570eea025a19564429eb52b34ec34e14659f55/library/alloc/src/boxed.rs:2022:9
  61:        0x10e945ebb - std::sys::pal::unix::thread::Thread::new::thread_start::h8bcb0c13e5c274b3
                               at /rustc/4d570eea025a19564429eb52b34ec34e14659f55/library/std/src/sys/pal/unix/thread.rs:108:17
  62:     0x7ff81bdc34e1 - __pthread_start
thread 'main' panicked at /Users/eric/.cargo/registry/src/index.crates.io-6f17d22bba15001f/winit-0.29.15/src/platform_impl/macos/app_state.rs:387:33:
called `Result::unwrap()` on an `Err` value: PoisonError { .. }
stack backtrace:
   0:        0x10e940b93 - std::backtrace_rs::backtrace::libunwind::trace::heb0ed943047ae607
                               at /rustc/4d570eea025a19564429eb52b34ec34e14659f55/library/std/src/../../backtrace/src/backtrace/libunwind.rs:105:5
   1:        0x10e940b93 - std::backtrace_rs::backtrace::trace_unsynchronized::hd40c99601c69fcdc
                               at /rustc/4d570eea025a19564429eb52b34ec34e14659f55/library/std/src/../../backtrace/src/backtrace/mod.rs:66:5
   2:        0x10e940b93 - std::sys_common::backtrace::_print_fmt::h30feec6dd4416b29
                               at /rustc/4d570eea025a19564429eb52b34ec34e14659f55/library/std/src/sys_common/backtrace.rs:68:5
   3:        0x10e940b93 - <std::sys_common::backtrace::_print::DisplayBacktrace as core::fmt::Display>::fmt::hb76885d4160cbc07
                               at /rustc/4d570eea025a19564429eb52b34ec34e14659f55/library/std/src/sys_common/backtrace.rs:44:22
   4:        0x10e96252b - core::fmt::rt::Argument::fmt::h7a496fbf57cda822
                               at /rustc/4d570eea025a19564429eb52b34ec34e14659f55/library/core/src/fmt/rt.rs:165:63
   5:        0x10e96252b - core::fmt::write::hb6c7322b133ccb41
                               at /rustc/4d570eea025a19564429eb52b34ec34e14659f55/library/core/src/fmt/mod.rs:1157:21
   6:        0x10e93e55e - std::io::Write::write_fmt::h967f79c1494da52a
                               at /rustc/4d570eea025a19564429eb52b34ec34e14659f55/library/std/src/io/mod.rs:1832:15
   7:        0x10e940981 - std::sys_common::backtrace::_print::hc4ab9120a1e7fceb
                               at /rustc/4d570eea025a19564429eb52b34ec34e14659f55/library/std/src/sys_common/backtrace.rs:47:5
   8:        0x10e940981 - std::sys_common::backtrace::print::hd8bbf589af3442f4
                               at /rustc/4d570eea025a19564429eb52b34ec34e14659f55/library/std/src/sys_common/backtrace.rs:34:9
   9:        0x10e941f29 - std::panicking::default_hook::{{closure}}::h5b697a050565f751
  10:        0x10e941c70 - std::panicking::default_hook::hc1b90463f4026204
                               at /rustc/4d570eea025a19564429eb52b34ec34e14659f55/library/std/src/panicking.rs:298:9
  11:        0x10e942936 - std::panicking::rust_panic_with_hook::hb800850208fe4a44
                               at /rustc/4d570eea025a19564429eb52b34ec34e14659f55/library/std/src/panicking.rs:795:13
  12:        0x10e9422b2 - std::panicking::begin_panic_handler::{{closure}}::h5bc0ab93ecc16cc6
                               at /rustc/4d570eea025a19564429eb52b34ec34e14659f55/library/std/src/panicking.rs:664:13
  13:        0x10e941069 - std::sys_common::backtrace::__rust_end_short_backtrace::hec78ae0903d2a2d3
                               at /rustc/4d570eea025a19564429eb52b34ec34e14659f55/library/std/src/sys_common/backtrace.rs:171:18
  14:        0x10e941fe6 - rust_begin_unwind
                               at /rustc/4d570eea025a19564429eb52b34ec34e14659f55/library/std/src/panicking.rs:652:5
  15:        0x10eb30942 - core::panicking::panic_fmt::he60397b262bce7df
                               at /rustc/4d570eea025a19564429eb52b34ec34e14659f55/library/core/src/panicking.rs:72:14
  16:        0x10eb30f15 - core::result::unwrap_failed::hfe2dbae73644635b
                               at /rustc/4d570eea025a19564429eb52b34ec34e14659f55/library/core/src/result.rs:1654:5
  17:        0x10d02e081 - core::result::Result<T,E>::unwrap::h34d987957305e284
                               at /rustc/4d570eea025a19564429eb52b34ec34e14659f55/library/core/src/result.rs:1077:23
  18:        0x10d02e081 - winit::platform_impl::platform::app_state::AppState::clear_callback::h4d51527bcc0e0141
                               at /Users/eric/.cargo/registry/src/index.crates.io-6f17d22bba15001f/winit-0.29.15/src/platform_impl/macos/app_state.rs:387:9
  19:        0x10cfa9c1e - winit::platform_impl::platform::event_loop::EventLoop<T>::run_on_demand::{{closure}}::hf2e79b9bd9fdc5f9
                               at /Users/eric/.cargo/registry/src/index.crates.io-6f17d22bba15001f/winit-0.29.15/src/platform_impl/macos/event_loop.rs:329:13
  20:        0x10cfa9c1e - objc2::rc::autorelease::autoreleasepool::h45b3f3cf590cf94b
                               at /Users/eric/.cargo/registry/src/index.crates.io-6f17d22bba15001f/objc2-0.4.1/src/rc/autorelease.rs:438:15
  21:        0x10cfa9c1e - winit::platform_impl::platform::event_loop::EventLoop<T>::run_on_demand::h10b70c5a9e1b334e
                               at /Users/eric/.cargo/registry/src/index.crates.io-6f17d22bba15001f/winit-0.29.15/src/platform_impl/macos/event_loop.rs:281:9
  22:        0x10cfa9c1e - winit::platform_impl::platform::event_loop::EventLoop<T>::run::h03e7c035f3231d75
                               at /Users/eric/.cargo/registry/src/index.crates.io-6f17d22bba15001f/winit-0.29.15/src/platform_impl/macos/event_loop.rs:248:9
  23:        0x10cf8a0c1 - winit::event_loop::EventLoop<T>::run::h3e98c31f9140437d
                               at /Users/eric/.cargo/registry/src/index.crates.io-6f17d22bba15001f/winit-0.29.15/src/event_loop.rs:249:9
  24:        0x10cf8a0c1 - bevy_winit::winit_runner::h80688b16c970e616
                               at /Users/eric/.cargo/registry/src/index.crates.io-6f17d22bba15001f/bevy_winit-0.13.2/src/lib.rs:305:34
  25:        0x10cfc0bd8 - core::ops::function::FnOnce::call_once::hc9b2ad24e3bd0ad7
                               at /rustc/4d570eea025a19564429eb52b34ec34e14659f55/library/core/src/ops/function.rs:250:5
  26:        0x10cfc0bd8 - core::ops::function::FnOnce::call_once{{vtable.shim}}::h85020e70e41c12a1
                               at /rustc/4d570eea025a19564429eb52b34ec34e14659f55/library/core/src/ops/function.rs:250:5
  27:        0x10e810463 - <alloc::boxed::Box<F,A> as core::ops::function::FnOnce<Args>>::call_once::h306cd4747006af92
                               at /rustc/4d570eea025a19564429eb52b34ec34e14659f55/library/alloc/src/boxed.rs:2022:9
  28:        0x10e810463 - bevy_app::app::App::run::h831db4ab43337e54
                               at /Users/eric/.cargo/registry/src/index.crates.io-6f17d22bba15001f/bevy_app-0.13.2/src/app.rs:308:9
  29:        0x10ce9b51e - animated_cubes::main::hb92285d326aaa23b
                               at /Users/eric/projects/feather/mesh-cape/examples/animated_cubes.rs:6:5
  30:        0x10ceb3956 - core::ops::function::FnOnce::call_once::h53d0dd879b7fd533
                               at /rustc/4d570eea025a19564429eb52b34ec34e14659f55/library/core/src/ops/function.rs:250:5
  31:        0x10ceb3956 - std::sys_common::backtrace::__rust_begin_short_backtrace::h6572982b493f633a
                               at /rustc/4d570eea025a19564429eb52b34ec34e14659f55/library/std/src/sys_common/backtrace.rs:155:18
  32:        0x10ceac1ac - std::rt::lang_start::{{closure}}::ha0a68e8cf1a3ba12
                               at /rustc/4d570eea025a19564429eb52b34ec34e14659f55/library/std/src/rt.rs:159:18
  33:        0x10e93ab57 - core::ops::function::impls::<impl core::ops::function::FnOnce<A> for &F>::call_once::hd4a9f772d8fced30
                               at /rustc/4d570eea025a19564429eb52b34ec34e14659f55/library/core/src/ops/function.rs:284:13
  34:        0x10e93ab57 - std::panicking::try::do_call::h0eaa77172a1fa156
                               at /rustc/4d570eea025a19564429eb52b34ec34e14659f55/library/std/src/panicking.rs:559:40
  35:        0x10e93ab57 - std::panicking::try::h523e36acdf81bab4
                               at /rustc/4d570eea025a19564429eb52b34ec34e14659f55/library/std/src/panicking.rs:523:19
  36:        0x10e93ab57 - std::panic::catch_unwind::hc9c4fe11463df5cc
                               at /rustc/4d570eea025a19564429eb52b34ec34e14659f55/library/std/src/panic.rs:149:14
  37:        0x10e93ab57 - std::rt::lang_start_internal::{{closure}}::h16497403f8764203
                               at /rustc/4d570eea025a19564429eb52b34ec34e14659f55/library/std/src/rt.rs:141:48
  38:        0x10e93ab57 - std::panicking::try::do_call::h9217487671c4834c
                               at /rustc/4d570eea025a19564429eb52b34ec34e14659f55/library/std/src/panicking.rs:559:40
  39:        0x10e93ab57 - std::panicking::try::h9908c33c73eafb2c
                               at /rustc/4d570eea025a19564429eb52b34ec34e14659f55/library/std/src/panicking.rs:523:19
  40:        0x10e93ab57 - std::panic::catch_unwind::hf074bb1c90e74288
                               at /rustc/4d570eea025a19564429eb52b34ec34e14659f55/library/std/src/panic.rs:149:14
  41:        0x10e93ab57 - std::rt::lang_start_internal::hd745ca6755ceb7d1
                               at /rustc/4d570eea025a19564429eb52b34ec34e14659f55/library/std/src/rt.rs:141:20
  42:        0x10ce9c6ac - _main

For what it's worth, looks like the issue arises from winit-0.29.15/src/platform_impl/macos/app_state.rs:387:33 with a PoisonError - 😱⚗️ scary sounding.

Upstream appears to be bevy_core_pipeline::upscaling::prepare_view_upscaling_pipelines originating from /bevy_render-0.13.2/src/pipelined_rendering.rs:49:67.

That said, the first instance of panic is from wgpu-0.19.4/src/backend/wgpu_core.rs:3006:5 with a Validation Error.

ekalosak commented 4 months ago

The full error (excuse the color escapes, this is captured with a simple 2>full_error) is attached.

Another interesting (!) bit is:

DEBUG Instance::new: created Metal backend    
DEBUG Instance::new: failed to create Gl backend: InstanceError { message: "unable to open libEGL", source: Some(Library(DlOpen { desc: "dlopen(libEGL.dylib, 0x0005): tried: \'libEGL.dylib\' (no such file) [...]

full_error.txt

ekalosak commented 4 months ago

Cleaned up the log file with cat full_error.txt | sed -E 's/\x1B\[[0-9;]*[mGK]//g' > full_error_cleaned.txt; attached.

full_error_cleaned.txt

ekalosak commented 4 months ago

Notes, ordered for subsequent reference and not chronology nor importance nor etc.

  1. libEGL is https://docs.mesa3d.org/egl.html from what I can tell.
  2. Mesa3d's documentation on their "amber branch" (looks like deprecated support) says "Users with Intel GPUs that were using i965 should migrate to either Iris or Crocus, depending on their GPU. " - I'm encountering this bug with INFO bevy_render::renderer: AdapterInfo { name: "Intel Iris Pro Graphics", vendor: 0, device: 0, device_type: IntegratedGpu, driver: "", driver_info: "", backend: Metal } so no need to worry about migrating to Iris - it's there.
  3. Someone else here points out that users may copy a missing libEGL.dll to the location expected by the program.

Gotta go for now - I will report with more progress as any is made.

ekalosak commented 4 months ago

Following this StackOverflow answer, one can find a pre-compiled EGL implementation (i.e. libEGL.dll) for the antique macOS via find /Applications/ -name libEGL.dylib; for me this yields eight or so macOS apps having the library e.g. Slack, Discord, VS Code, etc. common things.

So I decided to "pilfer" from one of these apps existing implementations.

Noticing that Bevy (or gfx-rs, I didn't check which) looks in /usr/local/lib for the libEGL.dylib I decided to use that location:

ln -s /Applications/Visual\ Studio\ Code.app/Contents/Frameworks/Electron\ Framework.framework/Versions/A/Libraries/libEGL.dylib /us
r/local/lib/libEGL.dylib

^ and again for libGLESv2.dylib.

I get the same error:

2024-04-28T14:36:44.396826Z  INFO bevy_render::renderer: AdapterInfo { name: "Intel Iris Pro Graphics", vendor: 0, device: 0, device_type: IntegratedGpu, driver: "", driver_info: "", backend: Metal }
2024-04-28T14:36:44.680994Z  INFO bevy_winit::system: Creating new window "App" (0v1)
2024-04-28T14:36:44.750784Z  INFO bevy_diagnostic::system_information_diagnostics_plugin::internal: SystemInfo { os: "MacOS 12.7.4 ", kernel: "21.6.0", cpu: "Intel(R) Core(TM) i7-4770HQ CPU @ 2.20GHz", core_count: "4", memory: "16.0 GiB" }
2024-04-28T14:36:45.096794Z ERROR log: Device::create_render_pipeline error: Internal error in ShaderStages(VERTEX | FRAGMENT) shader: new_render_pipeline_state: "Compiler encountered an internal error"    
2024-04-28T14:36:45.096828Z ERROR log: Shader translation error for stage ShaderStages(VERTEX | FRAGMENT): new_render_pipeline_state: "Compiler encountered an internal error"    
2024-04-28T14:36:45.096839Z ERROR log: Please report it to https://github.com/gfx-rs/wgpu    
2024-04-28T14:36:45.096873Z ERROR log: Handling wgpu errors as fatal by default    
thread 'Compute Task Pool (3)' panicked at /Users/eric/.cargo/registry/src/index.crates.io-6f17d22bba15001f/wgpu-0.19.4/src/backend/wgpu_core.rs:3006:5:
wgpu error: Validation Error

Caused by:
    In Device::create_render_pipeline
      note: label = `pbr_opaque_mesh_pipeline`
    Internal error in ShaderStages(VERTEX | FRAGMENT) shader: new_render_pipeline_state: "Compiler encountered an internal error"

note: run with `RUST_BACKTRACE=1` environment variable to display a backtrace
Encountered a panic in system `bevy_core_pipeline::upscaling::prepare_view_upscaling_pipelines`!
thread 'Compute Task Pool (1)' panicked at /Users/eric/.cargo/registry/src/index.crates.io-6f17d22bba15001f/bevy_render-0.13.2/src/pipelined_rendering.rs:49:67:
called `Result::unwrap()` on an `Err` value: RecvError
thread 'main' panicked at /Users/eric/.cargo/registry/src/index.crates.io-6f17d22bba15001f/winit-0.29.15/src/platform_impl/macos/app_state.rs:387:33:
called `Result::unwrap()` on an `Err` value: PoisonError { .. }

but the RUST_LOG=trace RUST_BACKTRACE=full does show that the EGL implementation is successfully picked up:

[...]
2024-04-28T14:37:21.824966Z DEBUG log: Client extensions: [
    "EGL_EXT_client_extensions",
    "EGL_EXT_device_query",
    "EGL_EXT_platform_base",
    "EGL_ANGLE_platform_angle",
    "EGL_ANGLE_platform_angle_device_type_swiftshader",
    "EGL_ANGLE_platform_angle_opengl",
    "EGL_ANGLE_platform_angle_vulkan",
    "EGL_ANGLE_platform_angle_metal",
    "EGL_ANGLE_platform_device_context_volatile_cgl",
    "EGL_ANGLE_platform_angle_device_id",
    "EGL_KHR_client_get_all_proc_addresses",
    "EGL_KHR_debug",
    "EGL_ANGLE_feature_control",
    "EGL_ANGLE_display_power_preference",
]    
2024-04-28T14:37:21.825012Z DEBUG log: Loading X11 library to get the current display    
2024-04-28T14:37:21.825359Z  WARN log: EGL_MESA_platform_surfaceless not available. Using default platform    
2024-04-28T14:37:21.825420Z DEBUG log: Enabling EGL debug output    
2024-04-28T14:37:21.842071Z DEBUG log: Display vendor "Google Inc. (Intel Inc.)", version (1, 5)    
2024-04-28T14:37:21.842110Z DEBUG log: Display extensions: [
    "EGL_KHR_create_context",
    "EGL_KHR_get_all_proc_addresses",
    "EGL_ANGLE_create_context_webgl_compatibility",
    "EGL_CHROMIUM_create_context_bind_generates_resource",
    "EGL_EXT_pixel_format_float",
    "EGL_KHR_surfaceless_context",
    "EGL_ANGLE_display_texture_share_group",
    "EGL_ANGLE_display_semaphore_share_group",
    "EGL_ANGLE_create_context_client_arrays",
    "EGL_ANGLE_program_cache_control",
    "EGL_ANGLE_robust_resource_initialization",
    "EGL_ANGLE_iosurface_client_buffer",
    "EGL_ANGLE_create_context_extensions_enabled",
    "EGL_ANDROID_blob_cache",
    "EGL_ANDROID_recordable",
    "EGL_ANGLE_wait_until_work_scheduled",
    "EGL_ANGLE_create_context_backwards_compatible",
    "EGL_KHR_create_context_no_error",
    "EGL_KHR_reusable_sync",
[...]

Will post more as more progress is made.

tl;dr the missing libEGL.dll was red herring or insufficient to fix

ekalosak commented 4 months ago

Setting RUST_LOG=debug,wgpu=trace,naga=debug provides:

[...]
2024-04-28T17:18:47.192219Z DEBUG log: var GlobalVariable { name: Some("material"), space: Uniform, binding: Some(ResourceBinding { group: 2, binding: 0 }), ty: [6], init: None }    
2024-04-28T17:18:47.192244Z DEBUG log: var GlobalVariable { name: Some("texture"), space: Handle, binding: Some(ResourceBinding { group: 2, binding: 1 }), ty: [7], init: None }    
2024-04-28T17:18:47.192256Z DEBUG log: var GlobalVariable { name: Some("texture_sampler"), space: Handle, binding: Some(ResourceBinding { group: 2, binding: 2 }), ty: [8], init: None }    
2024-04-28T17:18:47.192297Z DEBUG log: var LocalVariable { name: Some("output_color"), ty: [1], init: None }    
2024-04-28T17:18:47.192433Z DEBUG log: var GlobalVariable { name: Some("material"), space: Uniform, binding: Some(ResourceBinding { group: 2, binding: 0 }), ty: [6], init: None }    
2024-04-28T17:18:47.192451Z DEBUG log: var GlobalVariable { name: Some("texture"), space: Handle, binding: Some(ResourceBinding { group: 2, binding: 1 }), ty: [7], init: None }    
2024-04-28T17:18:47.192462Z DEBUG log: var GlobalVariable { name: Some("texture_sampler"), space: Handle, binding: Some(ResourceBinding { group: 2, binding: 2 }), ty: [8], init: None }    
2024-04-28T17:18:47.192499Z DEBUG log: var LocalVariable { name: Some("output_color"), ty: [1], init: None }    
2024-04-28T17:18:47.192577Z TRACE log: User is inserting ShaderModuleId(9,1,mtl)    
2024-04-28T17:18:47.192595Z TRACE log: Device::create_shader_module -> Id(9,1,mtl)    
2024-04-28T17:18:47.192680Z TRACE log: User is inserting PipelineLayoutId(7,1,mtl)    
2024-04-28T17:18:47.192698Z TRACE log: Device::create_pipeline_layout -> Id(7,1,mtl)    
2024-04-28T17:18:47.194022Z DEBUG log: Naga generated shader for entry point 'vertex' and stage Vertex
// language: metal2.4
#include <metal_stdlib>
#include <simd/simd.h>

using metal::uint;
struct DefaultConstructible {
    template<typename T>
    operator T() && {
        return T {};
    }
};

struct _mslBufferSizes {
    uint size0;
};

struct VertexOutputX_naga_oil_mod_XMJSXM6K7ONYHE2LUMU5DU3LFONUDEZC7OZSXE5DFPBPW65LUOB2XIX {
    metal::float4 position;
    metal::float4 world_position;
    metal::float3 world_normal;
    metal::float2 uv;
};
struct Mesh2dX_naga_oil_mod_XMJSXM6K7ONYHE2LUMU5DU3LFONUDEZC7OR4XAZLTX {
    metal::float3x4 model;
    metal::float2x4 inverse_transpose_model_a;
    float inverse_transpose_model_b;
    uint flags;
};
typedef Mesh2dX_naga_oil_mod_XMJSXM6K7ONYHE2LUMU5DU3LFONUDEZC7OR4XAZLTX type_9[1];
struct type_10 {
    metal::float4 inner[6];
};
struct ColorGradingX_naga_oil_mod_XMJSXM6K7OJSW4ZDFOI5DU5TJMV3QX {
    float exposure;
    float gamma;
    float pre_saturation;
    float post_saturation;
};
struct ViewX_naga_oil_mod_XMJSXM6K7OJSW4ZDFOI5DU5TJMV3QX {
    metal::float4x4 view_proj;
    metal::float4x4 unjittered_view_proj;
    metal::float4x4 inverse_view_proj;
    metal::float4x4 view;
    metal::float4x4 inverse_view;
    metal::float4x4 projection;
    metal::float4x4 inverse_projection;
    metal::packed_float3 world_position;
    float exposure;
    metal::float4 viewport;
    type_10 frustum;
    ColorGradingX_naga_oil_mod_XMJSXM6K7OJSW4ZDFOI5DU5TJMV3QX color_grading;
    float mip_bias;
    uint render_layers;
};
struct GlobalsX_naga_oil_mod_XMJSXM6K7OJSW4ZDFOI5DUZ3MN5RGC3DTX {
    float time;
    float delta_time;
    uint frame_count;
};
struct Vertex {
    uint instance_index;
    char _pad1[12];
    metal::float3 position;
    metal::float3 normal;
    metal::float2 uv;
};

metal::float4x4 affine_to_squareX_naga_oil_mod_XMJSXM6K7OJSW4ZDFOI5DU3LBORUHGX(
    metal::float3x4 affine
) {
    return metal::transpose(metal::float4x4(affine[0], affine[1], affine[2], metal::float4(0.0, 0.0, 0.0, 1.0)));
}

metal::float3x3 mat2x4_f32_to_mat3x3_unpackX_naga_oil_mod_XMJSXM6K7OJSW4ZDFOI5DU3LBORUHGX(
    metal::float2x4 a,
    float b
) {
    return metal::float3x3(a[0].xyz, metal::float3(a[0].w, a[1].xy), metal::float3(a[1].zw, b));
}

metal::float4x4 get_model_matrixX_naga_oil_mod_XMJSXM6K7ONYHE2LUMU5DU3LFONUDEZC7MZ2W4Y3UNFXW44YX(
    uint instance_index,
    device type_9 const& meshX_naga_oil_mod_XMJSXM6K7ONYHE2LUMU5DU3LFONUDEZC7MJUW4ZDJNZTXGX,
    constant _mslBufferSizes& _buffer_sizes
) {
    metal::float3x4 _e4 = uint(instance_index) < 1 + (_buffer_sizes.size0 - 0 - 96) / 96 ? meshX_naga_oil_mod_XMJSXM6K7ONYHE2LUMU5DU3LFONUDEZC7MJUW4ZDJNZTXGX[instance_index].model : DefaultConstructible();
    metal::float4x4 _e5 = affine_to_squareX_naga_oil_mod_XMJSXM6K7OJSW4ZDFOI5DU3LBORUHGX(_e4);
    return _e5;
}

metal::float4 mesh2d_position_local_to_worldX_naga_oil_mod_XMJSXM6K7ONYHE2LUMU5DU3LFONUDEZC7MZ2W4Y3UNFXW44YX(
    metal::float4x4 model_1,
    metal::float4 vertex_position
) {
    return model_1 * vertex_position;
}

metal::float4 mesh2d_position_world_to_clipX_naga_oil_mod_XMJSXM6K7ONYHE2LUMU5DU3LFONUDEZC7MZ2W4Y3UNFXW44YX(
    metal::float4 world_position,
    constant ViewX_naga_oil_mod_XMJSXM6K7OJSW4ZDFOI5DU5TJMV3QX& viewX_naga_oil_mod_XMJSXM6K7ONYHE2LUMU5DU3LFONUDEZC7OZUWK527MJUW4ZDJNZTXGX
) {
    metal::float4x4 _e3 = viewX_naga_oil_mod_XMJSXM6K7ONYHE2LUMU5DU3LFONUDEZC7OZUWK527MJUW4ZDJNZTXGX.view_proj;
    return _e3 * world_position;
}

metal::float3 mesh2d_normal_local_to_worldX_naga_oil_mod_XMJSXM6K7ONYHE2LUMU5DU3LFONUDEZC7MZ2W4Y3UNFXW44YX(
    metal::float3 vertex_normal,
    uint instance_index_1,
    device type_9 const& meshX_naga_oil_mod_XMJSXM6K7ONYHE2LUMU5DU3LFONUDEZC7MJUW4ZDJNZTXGX,
    constant _mslBufferSizes& _buffer_sizes
) {
    metal::float2x4 _e4 = uint(instance_index_1) < 1 + (_buffer_sizes.size0 - 0 - 96) / 96 ? meshX_naga_oil_mod_XMJSXM6K7ONYHE2LUMU5DU3LFONUDEZC7MJUW4ZDJNZTXGX[instance_index_1].inverse_transpose_model_a : DefaultConstructible();
    float _e8 = uint(instance_index_1) < 1 + (_buffer_sizes.size0 - 0 - 96) / 96 ? meshX_naga_oil_mod_XMJSXM6K7ONYHE2LUMU5DU3LFONUDEZC7MJUW4ZDJNZTXGX[instance_index_1].inverse_transpose_model_b : DefaultConstructible();
    metal::float3x3 _e9 = mat2x4_f32_to_mat3x3_unpackX_naga_oil_mod_XMJSXM6K7OJSW4ZDFOI5DU3LBORUHGX(_e4, _e8);
    return _e9 * vertex_normal;
}

struct vertex_Input {
    metal::float3 position [[attribute(0)]];
    metal::float3 normal [[attribute(1)]];
    metal::float2 uv [[attribute(2)]];
};
struct vertex_Output {
    metal::float4 position [[position]];
    metal::float4 world_position [[user(loc0), center_perspective]];
    metal::float3 world_normal [[user(loc1), center_perspective]];
    metal::float2 uv [[user(loc2), center_perspective]];
};
vertex vertex_Output vertex_(
  vertex_Input varyings [[stage_in]]
, uint instance_index_2 [[instance_id]]
, device type_9 const& meshX_naga_oil_mod_XMJSXM6K7ONYHE2LUMU5DU3LFONUDEZC7MJUW4ZDJNZTXGX [[buffer(2)]]
, constant ViewX_naga_oil_mod_XMJSXM6K7OJSW4ZDFOI5DU5TJMV3QX& viewX_naga_oil_mod_XMJSXM6K7ONYHE2LUMU5DU3LFONUDEZC7OZUWK527MJUW4ZDJNZTXGX [[buffer(0)]]
, constant _mslBufferSizes& _buffer_sizes [[buffer(4)]]
) {
    const Vertex vertex_1 = { instance_index_2, {}, varyings.position, varyings.normal, varyings.uv };
    VertexOutputX_naga_oil_mod_XMJSXM6K7ONYHE2LUMU5DU3LFONUDEZC7OZSXE5DFPBPW65LUOB2XIX out = {};
    metal::float4x4 model = {};
    out.uv = vertex_1.uv;
    metal::float4x4 _e5 = get_model_matrixX_naga_oil_mod_XMJSXM6K7ONYHE2LUMU5DU3LFONUDEZC7MZ2W4Y3UNFXW44YX(vertex_1.instance_index, meshX_naga_oil_mod_XMJSXM6K7ONYHE2LUMU5DU3LFONUDEZC7MJUW4ZDJNZTXGX, _buffer_sizes);
    model = _e5;
    metal::float4x4 _e8 = model;
    metal::float4 _e12 = mesh2d_position_local_to_worldX_naga_oil_mod_XMJSXM6K7ONYHE2LUMU5DU3LFONUDEZC7MZ2W4Y3UNFXW44YX(_e8, metal::float4(vertex_1.position, 1.0));
    out.world_position = _e12;
    metal::float4 _e15 = out.world_position;
    metal::float4 _e16 = mesh2d_position_world_to_clipX_naga_oil_mod_XMJSXM6K7ONYHE2LUMU5DU3LFONUDEZC7MZ2W4Y3UNFXW44YX(_e15, viewX_naga_oil_mod_XMJSXM6K7ONYHE2LUMU5DU3LFONUDEZC7OZUWK527MJUW4ZDJNZTXGX);
    out.position = _e16;
    metal::float3 _e20 = mesh2d_normal_local_to_worldX_naga_oil_mod_XMJSXM6K7ONYHE2LUMU5DU3LFONUDEZC7MZ2W4Y3UNFXW44YX(vertex_1.normal, vertex_1.instance_index, meshX_naga_oil_mod_XMJSXM6K7ONYHE2LUMU5DU3LFONUDEZC7MJUW4ZDJNZTXGX, _buffer_sizes);
    out.world_normal = _e20;
    VertexOutputX_naga_oil_mod_XMJSXM6K7ONYHE2LUMU5DU3LFONUDEZC7OZSXE5DFPBPW65LUOB2XIX _e21 = out;
    const auto _tmp = _e21;
    return vertex_Output { _tmp.position, _tmp.world_position, _tmp.world_normal, _tmp.uv };
}

struct fragment_Input {
    metal::float4 world_position [[user(loc0), center_perspective]];
    metal::float3 world_normal [[user(loc1), center_perspective]];
    metal::float2 uv [[user(loc2), center_perspective]];
};
struct fragment_Output {
    metal::float4 member_1 [[color(0)]];
};
fragment fragment_Output fragment_(
  fragment_Input varyings_1 [[stage_in]]
, metal::float4 position [[position]]
) {
    const VertexOutputX_naga_oil_mod_XMJSXM6K7ONYHE2LUMU5DU3LFONUDEZC7OZSXE5DFPBPW65LUOB2XIX in = { position, varyings_1.world_position, varyings_1.world_normal, varyings_1.uv };
    return fragment_Output { metal::float4(1.0, 0.0, 1.0, 1.0) };
}

2024-04-28T17:18:47.195139Z DEBUG log: Naga generated shader for entry point 'fragment' and stage Fragment
// language: metal2.4
#include <metal_stdlib>
#include <simd/simd.h>

using metal::uint;
struct DefaultConstructible {
    template<typename T>
    operator T() && {
        return T {};
    }
};

struct VertexOutputX_naga_oil_mod_XMJSXM6K7ONYHE2LUMU5DU3LFONUDEZC7OZSXE5DFPBPW65LUOB2XIX {
    metal::float4 position;
    metal::float4 world_position;
    metal::float3 world_normal;
    metal::float2 uv;
};
struct ColorMaterial {
    metal::float4 color;
    uint flags;
};
constant uint COLOR_MATERIAL_FLAGS_TEXTURE_BIT = 1u;

struct fragment_Input {
    metal::float4 world_position [[user(loc0), center_perspective]];
    metal::float3 world_normal [[user(loc1), center_perspective]];
    metal::float2 uv [[user(loc2), center_perspective]];
};
struct fragment_Output {
    metal::float4 member [[color(0)]];
};
fragment fragment_Output fragment_(
  fragment_Input varyings [[stage_in]]
, metal::float4 position [[position]]
, constant ColorMaterial& material [[buffer(3)]]
, metal::texture2d<float, metal::access::sample> texture [[texture(0)]]
, metal::sampler texture_sampler [[sampler(0)]]
) {
    const VertexOutputX_naga_oil_mod_XMJSXM6K7ONYHE2LUMU5DU3LFONUDEZC7OZSXE5DFPBPW65LUOB2XIX mesh = { position, varyings.world_position, varyings.world_normal, varyings.uv };
    metal::float4 output_color = {};
    metal::float4 _e2 = material.color;
    output_color = _e2;
    uint _e6 = material.flags;
    if ((_e6 & COLOR_MATERIAL_FLAGS_TEXTURE_BIT) != 0u) {
        metal::float4 _e11 = output_color;
        metal::float4 _e16 = texture.sample(texture_sampler, mesh.uv);
        output_color = _e11 * _e16;
    }
    metal::float4 _e18 = output_color;
    return fragment_Output { _e18 };
}

2024-04-28T17:18:47.303582Z TRACE log: User is insering as error RenderPipelineId(6,1,mtl)    
2024-04-28T17:18:47.303634Z ERROR log: Device::create_render_pipeline error: Internal error in ShaderStages(VERTEX | FRAGMENT) shader: new_render_pipeline_state: "Compiler encountered an internal error"    
2024-04-28T17:18:47.303659Z ERROR log: Shader translation error for stage ShaderStages(VERTEX | FRAGMENT): new_render_pipeline_state: "Compiler encountered an internal error"    
2024-04-28T17:18:47.303669Z ERROR log: Please report it to https://github.com/gfx-rs/wgpu    
2024-04-28T17:18:47.303725Z ERROR log: Handling wgpu errors as fatal by default    
thread 'Compute Task Pool (1)' panicked at /Users/eric/.cargo/registry/src/index.crates.io-6f17d22bba15001f/wgpu-0.19.4/src/backend/wgpu_core.rs:3006:5:
wgpu error: Validation Error

Caused by:
    In Device::create_render_pipeline
      note: label = `transparent_mesh2d_pipeline`
    Internal error in ShaderStages(VERTEX | FRAGMENT) shader: new_render_pipeline_state: "Compiler encountered an internal error"

[...]

So, at this point the error message has become a bit more legible to me: naga makes a Vertex and a Fragment, which wgpu cannot validate, so it "inserts as error" the RenderPipeline (cf wgpu-core-0.19.4/src/storage.rs#L171: log::trace!("User is insering as error {}{:?}", T::TYPE, id);)

@teoxoy please see the logging output requested; @cwfitzgerald pleae see the shader dump requested;

ekalosak commented 4 months ago

Workaround (2)

Please see REMOTE_BEVY.md attached for my notes, essentially just t2.large -> install rust & build essentials -> run through Bevy wbpu, easy as.

REMOTE_BEVY.md

tl;dr easy enough (<30 min) to set up remote dev node and forward http serving wasm (wgpu)

Using chrome: Screen Shot 2024-04-28 at 3 18 42 PM

Recommendation: close as "won't fix".