← Back to issue list

feat: improve error messages when parsing XML

View original Github issue

Metadata

Project
craft-parts
Number
#1138
Type
pull request
State
merged
Author
bepri
Labels
Created
Updated
Closed

Current evaluation

Merged enhancement improving XML parsing error messages in the maven-use plugin. Replaces unhelpful empty errors with full XML element output for debugging. Approved by two reviewers, passed all CI checks, and modified 5 files (+47/-14).

Suggested action:

No scores available.

Issue body

- [x] Have you signed the [CLA](http://www.ubuntu.com/legal/contributors/)? - [x] Have you added an entry to the changelog (`docs/reference/changelog.rst`)? ----- Improves the error message given when parsing bad XML with the maven-use plugin. Previously, very empty error messages were given that gave next to no information for finding the offending XML tag. Now, the entire XML element is printed (as line numbers are not available to us) to aid in debugging. CRAFT-4601

Evaluation history

Date Model Scores Action Summary
qwen/qwen3.6-35b-a3b Merged enhancement improving XML parsing error messages in the maven-use plugin. Replaces unhelpful empty errors with full XML element output for debugging. Approved by two reviewers, passed all CI checks, and modified 5 files (+47/-14).
qwen3.6-35b-a3b-mtp-q6 Merged improvement to XML parsing error messages in the maven-use plugin. The change prints the full offending XML element instead of empty messages to aid debugging, addressing CRAFT-4601.

Update history

No update history recorded yet.

Related issues

Issue Project State Summary Similarity
#1172 refactor(maven-use): use lxml instead of base xml for all parsing craft-parts merged Merged a refactor replacing the standard xml library with lxml for safer parsing in maven-use. Approved by three reviewers and passed all CI checks. Updates four files with secure configs and whitespace stripping to improve testability.
72%
#3179 Maven plugin: improve error message when target libs are not found. snapcraft merged Merged updates to the Maven plugin that enhance error reporting for missing target libraries. The change adds searched directories and a usage scenario to clarify build failures. Approved by one reviewer and passed CI checks.
70%