← Back to issue list

appstream parsing fails when comments exist

View original Launchpad issue

Metadata

Project
snapcraft (launchpad)
Number
#1852329
Type
issue
State
open
Author
~ken-vandine
Labels
—
Created
Updated
Closed
—

Current evaluation

AppStream description parsing broke on XML translator comments; fixed by commit e4dc754f2 (snapcraft#2832), which strips comments in the XSLT and adds a TRANSLATORS-comment regression test. Launchpad bug still open.

Suggested action: close resolved

Reason: The reported failure mode is fixed in the current codebase: `snapcraft/meta/appstream.py` now contains `<xsl:template match="comment()"/>` in the `_XSLT` stylesheet, and commit e4dc754f2 ("appstream extractor: take xml comments into account", merged as canonical/snapcraft#2832) added that template together with `test_appstream_with_comments` in `tests/unit/meta/test_appstream.py`, which uses exactly the reported `<!-- TRANSLATORS: ... -->` markup and asserts the description is extracted correctly. The behaviour is also exercised by spread fixtures (e.g. `tests/spread/general/snaps/appstream-remote-gfx/io.snapcraft.appstream.metainfo.xml` with `<!-- Some Comment -->`), so the bug no longer reproduces and the untriaged Launchpad report can be closed.

Evaluated by: mr-cal-bot

Impact: 38 Quick Win: 29 Complexity: 10 Confidence: 93 Actionability: 85

Issue body

Snapcraft is failing to parse description from the appstream data when there is a translators comment present. For example: https://gitlab.gnome.org/kenvandine/gnome-firmware-updater/blob/snap/data/appdata/org.gnome.Firmware.metainfo.xml.in

Evaluation history

Date Model Scores Action Summary
stealth/space-bunny-alpha
Impact: 38
Quick Win: 29
Complexity: 10
Confidence: 93
Actionability: 85
close resolved AppStream description parsing broke on XML translator comments; fixed by commit e4dc754f2 (snapcraft#2832), which strips comments in the XSLT and adds a TRANSLATORS-comment regression test. Launchpad bug still open.
stealth/space-bunny-alpha
Impact: 35
Quick Win: 20
Complexity: 25
Confidence: 86
Actionability: 78
close resolved AppStream description extraction with XML translator comments was addressed by commit e4dc754f2, although the untriaged report remains open.
qwen/qwen3.8-27b
Impact: 40
Quick Win: 28
Staleness: 95
Complexity: 30
Confidence: 50
Support Request: 10
needs triage Snapcraft fails to parse the appstream description when translator comments are present in the metainfo XML. Unlabelled, zero comments, no maintainer interaction, inactive for ~6.8 years.
qwen/qwen3.6-35b-a3b
Staleness: 95
Complexity: 20
Confidence: 90
Support Request: 10
close stale Snapcraft fails to parse AppStream descriptions when translator comments are present in the XML. The report is unlabelled, has zero comments, and has been inactive for over six years.
qwen/qwen3.6-35b-a3b
Staleness: 98
Complexity: 25
Confidence: 90
Support Request: 10
close stale Snapcraft fails to parse appstream descriptions when translator comments are present in the XML. The issue has been open for over six years with no maintainer response or activity.
qwen3.6-35b-a3b-mtp-q6
Staleness: 98
Complexity: 20
Confidence: 90
Support Request: 5
close stale Snapcraft fails to parse AppStream descriptions when translator comments are present in the XML. The issue has been completely inactive for over six years with no maintainer response or labels.

Update history

Date Change
created

Related work

  • Likely Fixed By: canonical/snapcraft#2832 (confidence 96%)

    Merged PR 'appstream extractor: take xml comments into account' resolving commit e4dc754f2; adds the XSLT comment-stripping template plus the TRANSLATORS-comment unit test.

Related issues

Issue Project State Summary Similarity
#2832 appstream extractor: take xml comments into account snapcraft merged Merged as commit e4dc754f2, fixing AppStream extraction with XML comments and adding regression coverage for Launchpad bug #1852329.
86%