{"record":{"id":"0bd84c534e94c1e0","repo":"slint-ui/slint","slug":"encountered-one-or-multiple-errors-see-above-for-details","errorCode":null,"errorMessage":"Encountered one or multiple errors. See above for details.","messagePattern":"Encountered one or multiple errors\\. See above for details\\.","errorType":"exception","errorClass":null,"httpStatus":null,"severity":"error","filePath":"xtask/src/license_headers_check.rs","lineNumber":964,"sourceCode":"impl LicenseHeaderCheck {\n    pub fn check_license_headers(&self) -> Result<(), Box<dyn std::error::Error>> {\n        let mut seen_errors = false;\n        for path in &collect_files()? {\n            let result = self\n                .check_file(path.as_path())\n                .with_context(|| format!(\"checking {}\", path.to_string_lossy()));\n\n            if result.is_err() {\n                seen_errors = true;\n                if self.show_all {\n                    eprintln!(\"Error: {result:?}\");\n                } else {\n                    return result.map_err(|e| e.into());\n                }\n            }\n        }\n        if seen_errors {\n            Err(anyhow!(\"Encountered one or multiple errors. See above for details.\").into())\n        } else {\n            println!(\"All files are ok.\");\n            Ok(())\n        }\n    }\n\n    fn check_file_tags(&self, path: &Path, style: &LicenseTagStyle, license: &str) -> Result<()> {\n        let source = &std::fs::read_to_string(path).context(\"Error reading file\")?;\n\n        let source = SourceFileWithTags::new(source, style);\n\n        if !source.has_tag() {\n            if self.fix_it {\n                eprintln!(\"Fixing up {path:?} as instructed. It's missing a license header.\");\n                let source = source.replace_tag(&EXPECTED_HEADER, license);\n                std::fs::write(path, source).context(\"Error writing source\")\n            } else {\n                Err(anyhow!(\"Missing tag\"))","sourceCodeStart":946,"sourceCodeEnd":982,"githubUrl":"https://github.com/slint-ui/slint/blob/3a7e700487dc74d404cad0726378053ab763d4e0/xtask/src/license_headers_check.rs#L946-L982","documentation":"check_license_headers aggregates per-file results and prints each individual error as it goes; at the end, if any file failed, it throws this generic summary error so the process exits non-zero. The real diagnostics are printed above this line in the output.","triggerScenarios":"Running `cargo xtask check` where any file failed any check: missing/wrong license header, missing tag, bad Cargo.toml metadata, or bad LICENSES symlinks — each individual error is printed first, then this error.","commonSituations":"CI failure on a PR where developers must scroll up to find the actual failing file(s); running the check locally after adding new files.","solutions":["Scroll up in the output for the specific per-file errors printed above this message","Fix each reported issue (or run `cargo xtask check --fix` for auto-fixable ones)","Re-run `cargo xtask check` until it prints \"All files are ok.\""],"exampleFix":"null","handlingStrategy":"try-catch","validationCode":"null","typeGuard":null,"tryCatchPattern":"// run the check and surface the detailed output, not just the summary\nmatch check_license_headers(...) {\n    Ok(()) => println!(\"ok\"),\n    Err(e) => {\n        eprintln!(\"license check failed: {e}; see detailed errors above\");\n        std::process::exit(1);\n    }\n}","preventionTips":["Read the full CI log, not just the last error line","Run `cargo xtask check --fix` locally before pushing","Fix all per-file errors reported above the summary in one pass","Add the check to local pre-commit hooks to catch issues early"],"tags":["ci","license","aggregate-error"],"backgroundTag":"schema-validation-failed","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"}