{"record":{"id":"605e370d4abfabfb","repo":"slint-ui/slint","slug":"failed-to-create-language-pyi","errorCode":null,"errorMessage":"Failed to create language.pyi","messagePattern":"Failed to create language\\.pyi","errorType":"panic","errorClass":null,"httpStatus":null,"severity":"error","filePath":"api/python/slint/build.rs","lineNumber":214,"sourceCode":"                                }\n                            }\n                            writeln!(writer, \"    \\\"\\\"\\\"\").unwrap();\n                        }\n                    })*\n                }\n            )*\n        }\n    };\n}\n\ni_slint_common::for_each_enums!(generate_public_enums_pyi);\n\nfn main() {\n    let pyi_path = std::path::Path::new(\"slint/language.pyi\");\n    if let Some(parent) = pyi_path.parent() {\n        std::fs::create_dir_all(parent).expect(\"Failed to create slint/ directory\");\n    }\n    let file = File::create(pyi_path).expect(\"Failed to create language.pyi\");\n    let mut writer = BufWriter::new(file);\n    generate_pyi(&mut writer);\n    writeln!(&mut writer, \"\\nimport enum\").unwrap();\n    generate_enums_pyi(&mut writer);\n}\n","sourceCodeStart":196,"sourceCodeEnd":220,"githubUrl":"https://github.com/slint-ui/slint/blob/3fd8f2ec03c2aa8a95d5f4b9daa299c7b8bf4016/api/python/slint/build.rs#L196-L220","documentation":"Error \"Failed to create language.pyi\" thrown in slint-ui/slint.","triggerScenarios":"Thrown at api/python/slint/build.rs:214 when the library encounters an invalid state.","commonSituations":"See trigger scenarios.","solutions":["Ensure the build script can write language.pyi.","Check file permissions and disk space."],"exampleFix":null,"handlingStrategy":null,"validationCode":null,"typeGuard":null,"tryCatchPattern":null,"preventionTips":[],"tags":[],"backgroundTag":null,"analyzedSha":"3fd8f2ec03c2aa8a95d5f4b9daa299c7b8bf4016","analyzedAt":"2026-08-19T23:23:16.610Z","contentChangedAt":null,"schemaVersion":2},"datasetVersion":"2026-09-14T05:17:10.506Z"}