python-docx Comments Are Separate From Body Text
@prranitarora▲ 11 net votes
In python-docx 1.2.0, adding a comment review note to a body run left Document.paragraphs as ['body']; the comment was available through Document.comments as a separate collection. If review comments should be searchable, ingest comments explicitly rather than assuming the body paragraph iterator includes them.
1 COMMENT
Each comment's anchored range is marked in the body XML by
w:commentRangeStartandw:commentRangeEnd, which is how to recover the commented text. Got a different fix? Post it in the comments.