| name | triage-designer-errors |
|---|---|
| description | Turn a Quadient Inspire Designer import error log into permanent assets - an import-lint check, a rulebook entry, a fixture, and a G5 import record - then open a PR. Use when someone pastes Designer import errors, asks to "triage import errors for <form>", or supplies an import log. |
Input: the raw error output from a Designer import of a generated artifact, plus who imported it, which Designer version, and on what date. If the raw text is paraphrased ("it complained about tables"), ask for the verbatim messages before proceeding; the catalogue stores messages, not summaries.
- Record the import as evidence first. Compute
sha256sum <layout.xml>for the artifact that was imported and writesrc/fixtures/import_logs/<sha256>.json(format insrc/fixtures/import_logs/README.md) withverdict: failand every message inerrors. This is the only thing that makes G5 say anything other thanexternal. - Classify each message against
src/gates/import_lint/catalogue.yaml:- Known code (
IMP-00x): set that entry'sstatus: observed, paste the message intodesigner_message, and extendevidence. If the offline check did not flag the artifact before import, the check is wrong or too narrow: fix it insrc/gates/import_lint/__init__.pywith a test intests/test_gates.pythat fails on the offending XML before the fix. - New class: add a catalogue entry with the next code,
status: observed, the verbatimdesigner_message, and acheckfunction you implement insrc/gates/import_lint/__init__.py. The check receives the target inventory (gates.target_inventory.inventory) and returns offending node ids. Add it toCHECKS. Add a failing-then-passing test using a mutated copy oftests/data/99-0001.xml. - Not structural (licensing, font not installed, version mismatch): do not add a check. Record it in
the PR and, if it recurs, in
knowledge/quadient-designer.md.
- Known code (
- For each new or changed check, find or add the rulebook rule that prevents the error at build-plan time:
src/rulebook/rules/<family>.yaml,classAUTOifsrc/converters/cim_to_inspire/build_plan.pycan enforce it (then implement and list it inimplemented_in), otherwiseASSIST/MANUAL.originis{type: designer_error, refs: ["<import_log sha256 prefix>"]}. Status staysdraft. - Re-run
python -m tools.pipeline -o out/. The catalogue must now flag the imported artifact offline (G5failwith the new code) and must still be clean on the two reference exports (they were produced by Designer, so any new finding against them is a false positive). ruff check . && pytest -q. Open a PR titledimport-lint: <IMP-code> <short title>listing: the error text, the check, the rule, and what a reviewer must confirm in Designer to mark the ruleverified.
- Fix the generated XML by hand to make the import pass.
- Mark a catalogue entry
observedwithout the verbatim Designer message. - Add a check that also fires on
17-0574.xmlor18-1026_Quad_2.xml. - Set a rule to
verified.