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
{{ message }}
Repository navigation
Annot.set_rotation(0) followed by Annot.update() throws AttributeError #5033
I have an Annot instance that I would like to remove rotation from. Trying to set the rotation of the Annot to zero then calling Annot.update() throws an AttributeError, stating that "'Annot' object has no attribute 'setRect'. Did you mean: 'set_rect'?" The offending line appears as 1838 of src/init.py of the latest revision of the main branch.
How to reproduce the bug
Issue can be reproduced by running the following code. Real use differs, but this replicates the error simply.
The first annot.update() call will return or print "cannot set rect: code=4: Line annotations have no Rect property". This behavior is expected.
The second annot.update() call should return or print similarly but instead terminates with the "setRect" error as described. This behavior is not expected.
Activity
JorjMcKie commentedon Jun 24, 2026
Thanks for submitting this.
This is a piece of code that hasn't been touched since the changing our naming standards from "CamelCase" to "snake_case".
changes.txt: removed bogus #4423 entry, added #5033.
julian-smith-artifex-com commentedon Jun 29, 2026
Fixed in pymupdf-1.28.0.