You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
fix(comments): use PowerPoint's real modern-comment contract — parent threads now render (issue #25)
Threaded comments were invisible in PowerPoint's Comments pane despite a
green trinity and clean script UAT. Root-caused by diffing our OOXML
against a threaded comment PowerPoint for Mac itself authored+saved
(ground truth, captured this session) — three string axes and one
element were inferred wrong in Waves 1-2:
- comment-part content type: was application/vnd.ms-powerpoint.threadedComments+xml
-> application/vnd.ms-powerpoint.comments+xml
- slide -> comment-part reltype: was .../2018/10/relationships/threadedComment
-> .../2018/10/relationships/comments
- presentation -> authors reltype: was .../2018/10/relationships/threadedCommentAuthors
-> .../2018/10/relationships/authors
- every <p188:cm> now emits its required first child
<pc:sldMkLst><pc:docMk/><pc:sldMk cId="0" sldId="{p:sldId}"/></pc:sldMkLst>
(ns .../2013/main/command) — the slide binding PowerPoint needs;
omitting it (or the fork-private extLst anchor) leaves the comment
unbound.
PowerPoint resolves the comment part by the slide relationship type; an
unrecognized reltype meant the part was never loaded -> empty pane.
Files: opc/constants.py (3 values; symbols unchanged so the PartFactory
registry + producer move in lockstep — Cato-audited), oxml/ns.py (+pc),
oxml/comments.py (sldMkLst ZeroOrOne + set_slide_marker), comments.py
(Comments.add binds the slide). 6 regression assertions in
DescribeThreadedCommentPowerPointContract lock all four axes
(red->green proven by stashing src) plus set_slide_marker idempotency.
Verification: pytest 3759 passed; ruff check + format clean; behave
1062 scenarios / 3215 steps 0 failed. Regenerated UAT deck opened in
real PowerPoint via Interceptor — Comments pane renders 3 threads,
correct author/text, resolved status persisted (uat/FIXED_comments_rendering.png
vs uat/REPRO_no_comments_pane.png). Cato cross-vendor audit: pass.
KNOWN-INCOMPLETE: PowerPoint still drops every <p188:reply> (replies do
not render; only parent comments do). This is a logically independent
reply-level contract defect, deliberately NOT inference-fixed — it needs
its own PowerPoint-authored <p188:reply> ground-truth diff. Tracked as a
scoped follow-up in the session ISA.
UAT script runs clean — pending maintainer visual signoff in
PowerPoint/Keynote. No push/PR per repo §6a. Refs #25.
0 commit comments