{"record":{"id":"ef8cbc9437b22dd7","repo":"gfx-rs/wgpu","slug":"timestamp-query-inside-passes-feature-must-be-enab-ef8cbc","errorCode":null,"errorMessage":"TIMESTAMP_QUERY_INSIDE_PASSES feature must be enabled to call write_timestamp in a render pass.","messagePattern":"TIMESTAMP_QUERY_INSIDE_PASSES feature must be enabled to call write_timestamp in a render pass\\.","errorType":"panic","errorClass":null,"httpStatus":null,"severity":"error","filePath":"wgpu/src/backend/webgpu.rs","lineNumber":3961,"sourceCode":"        _max_count: u32,\n    ) {\n        panic!(\"MESH_SHADER feature must be enabled to call multi_draw_mesh_tasks_indirect_count\")\n    }\n\n    fn insert_debug_marker(&mut self, label: &str) {\n        self.inner.insert_debug_marker(label);\n    }\n\n    fn push_debug_group(&mut self, group_label: &str) {\n        self.inner.push_debug_group(group_label);\n    }\n\n    fn pop_debug_group(&mut self) {\n        self.inner.pop_debug_group();\n    }\n\n    fn write_timestamp(&mut self, _query_set: &dispatch::DispatchQuerySet, _query_index: u32) {\n        panic!(\"TIMESTAMP_QUERY_INSIDE_PASSES feature must be enabled to call write_timestamp in a render pass.\")\n    }\n\n    fn begin_occlusion_query(&mut self, query_index: u32) {\n        self.inner.begin_occlusion_query(query_index);\n    }\n\n    fn end_occlusion_query(&mut self) {\n        self.inner.end_occlusion_query();\n    }\n\n    fn begin_pipeline_statistics_query(\n        &mut self,\n        _query_set: &dispatch::DispatchQuerySet,\n        _query_index: u32,\n    ) {\n        // Removed from WebGPU in https://github.com/gpuweb/gpuweb/pull/2296\n    }\n","sourceCodeStart":3943,"sourceCodeEnd":3979,"githubUrl":"https://github.com/gfx-rs/wgpu/blob/3e11ff59bf3f9795d285ecc045014089640d7248/wgpu/src/backend/webgpu.rs#L3943-L3979","documentation":"Panic from the WebGPU backend's write_timestamp stub on a render pass. The browser API exposes no equivalent of writing a timestamp inside a pass, so the method is intentionally unimplemented and any call aborts immediately.","triggerScenarios":"Thrown at wgpu/src/backend/webgpu.rs:3961 when the library encounters an invalid state.","commonSituations":"See trigger scenarios.","solutions":["Move timestamp writes to the command encoder level if supported","Skip timestamp queries entirely when running on the WebGPU backend"],"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"}