{"record":{"id":"923cd123d1d26ff5","repo":"slint-ui/slint","slug":"slint-package-outside-of-the-repository","errorCode":null,"errorMessage":"slint package '{}' outside of the repository?","messagePattern":"slint package '(.+?)' outside of the repository\\?","errorType":"exception","errorClass":null,"httpStatus":null,"severity":"error","filePath":"xtask/src/license_headers_check.rs","lineNumber":1171,"sourceCode":"        }\n\n        Ok(())\n    }\n\n    fn check_dependencies(&self, doc: &CargoToml, expected_version: &str) -> Result<()> {\n        let expected_version = format!(\"={expected_version}\");\n\n        for (dep_name, dep) in doc\n            .dependencies(\"dependencies\")\n            .iter()\n            .chain(doc.dependencies(\"build-dependencies\").iter())\n        {\n            if dep_name.starts_with(\"slint\") || dep_name.starts_with(\"i-slint\") {\n                match dep {\n                    CargoDependency::Workspace => (),\n                    CargoDependency::Full { path, version } => {\n                        if path.is_empty() {\n                            return Err(anyhow!(\n                                \"slint package '{}' outside of the repository?\",\n                                dep_name\n                            ));\n                        }\n                        if version != &expected_version {\n                            return Err(anyhow!(\n                                \"Version \\\"{}\\\" must be specified for dependency {}\",\n                                expected_version,\n                                dep_name\n                            ));\n                        }\n                    }\n                }\n            }\n        }\n\n        for (dep_name, dep) in doc.dependencies(\"dev-dependencies\").iter() {\n            if dep_name.starts_with(\"slint\") || dep_name.starts_with(\"i-slint\") {","sourceCodeStart":1153,"sourceCodeEnd":1189,"githubUrl":"https://github.com/slint-ui/slint/blob/3a7e700487dc74d404cad0726378053ab763d4e0/xtask/src/license_headers_check.rs#L1153-L1189","documentation":"In check_dependencies, every dependency named `slint*` or `i-slint*` inside repository crates must be declared with a `path` to an in-repo crate (plus the pinned version). A CargoDependency::Full entry with an empty path means the dependency resolves from crates.io instead of the local workspace, which would mix released and in-development slint versions. The check rejects this with a rhetorical 'outside of the repository?' message.","triggerScenarios":"Adding `slint = \"1.x\"` (version-only, no `path`) to a Cargo.toml of a crate that the license/Cargo.toml xtask check covers; copying a dependency line from the published slint examples into an internal crate.","commonSituations":"Adding a new example or tool crate and pasting the crates.io dependency snippet from docs; forgetting that internal crates must use path + version; an edit that dropped the `path = \"...\"` key during refactoring.","solutions":["Add the `path` key pointing at the local crate, e.g. `slint = { version = \"=1.x.y\", path = \"../../api/rs/slint\" }`.","If the dependency genuinely is external, use `CargoDependency::Workspace` (workspace inheritance) rather than a version-only entry.","Check whether the dependency should be listed under `[dependencies]` at all, or whether it belongs in the workspace root's dependency table."],"exampleFix":"// before\nslint = \"1.8\"\n// after\nslint = { version = \"=1.8.0\", path = \"../../api/rs/slint\" }","handlingStrategy":"validation","validationCode":"const dep = toml.parse(fs.readFileSync('Cargo.toml')).dependencies.slint;\nif (typeof dep === 'string' || !dep.path) throw new Error('slint dep needs a path');","typeGuard":null,"tryCatchPattern":null,"preventionTips":["Never add version-only slint/i-slint dependencies to in-repo crates.","Copy dependency declarations from a sibling crate that already passes the check.","Run `cargo xtask` checks locally before pushing."],"tags":["cargo","dependencies","ci","versioning"],"backgroundTag":"invalid-config-value","analyzedSha":"3a7e700487dc74d404cad0726378053ab763d4e0","analyzedAt":"2026-09-16T01:37:20.251Z","contentChangedAt":"2026-09-16T01:37:20.251Z","schemaVersion":2},"datasetVersion":"2026-09-23T08:17:48.524Z"}