{"record":{"id":"e0950287cb20279b","repo":"gfx-rs/wgpu","slug":"found-shadersource-dummy-e09502","errorCode":null,"errorMessage":"found `ShaderSource::Dummy`","messagePattern":"found `ShaderSource::Dummy`","errorType":"panic","errorClass":null,"httpStatus":null,"severity":"error","filePath":"wgpu/src/backend/wgpu_core.rs","lineNumber":828,"sourceCode":"            ShaderSource::Glsl {\n                ref shader,\n                stage,\n                defines,\n            } => {\n                let options = naga::front::glsl::Options {\n                    stage,\n                    defines: defines\n                        .iter()\n                        .map(|&(key, value)| (String::from(key), String::from(value)))\n                        .collect(),\n                };\n                wgc::pipeline::ShaderModuleSource::Glsl(Borrowed(shader), options)\n            }\n            #[cfg(feature = \"wgsl\")]\n            ShaderSource::Wgsl(ref code) => wgc::pipeline::ShaderModuleSource::Wgsl(Borrowed(code)),\n            #[cfg(feature = \"naga-ir\")]\n            ShaderSource::Naga(module) => wgc::pipeline::ShaderModuleSource::Naga(module),\n            ShaderSource::Dummy(_) => panic!(\"found `ShaderSource::Dummy`\"),\n        };\n        let (wgpu_shader_module, error) =\n            self.wgpu_device.create_shader_module(&descriptor, source);\n        let compilation_info = match error {\n            Some(cause) => {\n                self.wgpu_device.handle_error(\n                    cause.clone(),\n                    desc.label,\n                    \"Device::create_shader_module\",\n                );\n                CompilationInfo::from(cause)\n            }\n            None => CompilationInfo { messages: vec![] },\n        };\n\n        CoreShaderModule {\n            wgpu_shader_module,\n            compilation_info,","sourceCodeStart":810,"sourceCodeEnd":846,"githubUrl":"https://github.com/gfx-rs/wgpu/blob/3e11ff59bf3f9795d285ecc045014089640d7248/wgpu/src/backend/wgpu_core.rs#L810-L846","documentation":"Panic while converting a ShaderSource to a wgpu-core module: the enum held the Dummy variant, which exists only as a placeholder for doc/tests builds and carries no actual shader code, so the match's catch-all arm aborts.","triggerScenarios":"Thrown at wgpu/src/backend/wgpu_core.rs:828 when the library encounters an invalid state.","commonSituations":"See trigger scenarios.","solutions":["Pass a real ShaderSource (Wgsl, SpirV, Glsl, Naga, or VulkanNaga) instead of ShaderSource::Dummy","Avoid code paths that construct the Dummy variant outside cfg(test) builds"],"exampleFix":null,"handlingStrategy":"validation","validationCode":null,"typeGuard":null,"tryCatchPattern":null,"preventionTips":[],"tags":[],"backgroundTag":null,"analyzedSha":"3e11ff59bf3f9795d285ecc045014089640d7248","analyzedAt":"2026-09-03T01:43:21.459Z","contentChangedAt":null,"schemaVersion":2},"datasetVersion":"2026-09-10T07:17:11.731Z"}