
❌ This issue is not open for contribution. Visit Contributing guidelines to learn about the contributing process and how to find suitable issues.

Target branch: unstable
Observed behavior
- A native
qti item whose XML contains a comment passes validate_qti_item.
is_perseus_derivable then raises ValueError on it. _node_is_perseus_derivable calls it from publish.py with no try.
_local in utils/assessment/qti/perseus_derive.py passes every node from .iter() to etree.QName, and a comment node has no tag name.
derive_perseus_item raises the same error through _interaction_elements.
Errors and logs
>>> xml = VALID_CHOICE_ITEM.replace("<qti-item-body>", "<qti-item-body><!-- note -->", 1)
>>> validate_qti_item(xml.encode()).is_valid
True
>>> is_perseus_derivable(xml)
ValueError: Invalid input tag of type <class '_cython_3_2_4.cython_function_or_method'>
User-facing consequences
A single item uploaded through ricecooker or written through the sync API, with a comment anywhere in its XML, blocks publishing the whole channel.
Steps to reproduce
- Store
VALID_CHOICE_ITEM (tests/utils/qti/test_validation.py) with <!-- note --> inserted after <qti-item-body> as the raw_data of a qti AssessmentItem on an exercise.
- Publish the channel.
Acceptance Criteria
AI usage
I used Claude Code to review the #6189 branch. It reproduced this on upstream/unstable with is_perseus_derivable and a generator-level publish, and drafted this issue. The step from there to the channel publish failing comes from reading publish.py.
❌ This issue is not open for contribution. Visit Contributing guidelines to learn about the contributing process and how to find suitable issues.
Target branch: unstable
Observed behavior
qtiitem whose XML contains a comment passesvalidate_qti_item.is_perseus_derivablethen raisesValueErroron it._node_is_perseus_derivablecalls it frompublish.pywith notry._localinutils/assessment/qti/perseus_derive.pypasses every node from.iter()toetree.QName, and a comment node has no tag name.derive_perseus_itemraises the same error through_interaction_elements.Errors and logs
User-facing consequences
A single item uploaded through ricecooker or written through the sync API, with a comment anywhere in its XML, blocks publishing the whole channel.
Steps to reproduce
VALID_CHOICE_ITEM(tests/utils/qti/test_validation.py) with<!-- note -->inserted after<qti-item-body>as theraw_dataof aqtiAssessmentItemon an exercise.Acceptance Criteria
AI usage
I used Claude Code to review the #6189 branch. It reproduced this on
upstream/unstablewithis_perseus_derivableand a generator-level publish, and drafted this issue. The step from there to the channel publish failing comes from readingpublish.py.