fix(assets): pin plate SVG root size to pt so poppler builds agree #197
No reviewers
Labels
No labels
build-dist
priority
P1
priority
P2
priority
P3
priority
P4
bug
duplicate
enhancement
help wanted
invalid
question
wontfix
No milestone
No project
No assignees
1 participant
Notifications
Due date
No due date set.
Dependencies
No dependencies set
Reference
Toilville/toilville-design!197
Loading…
Reference in a new issue
No description provided.
Delete branch "fix/plate-svg-units"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Scope
Plate derivatives come out different depending on which poppler build converts them. Debian's
poppler (used by the CI build bot) writes the root
<svg width="667.94">without a unit, whileHomebrew's writes
width="667.94pt". Both mean points. The result: the bot's first live run (#195)rewrote all three plate derivatives, though only one EPS had changed. A later local
just plateswould flip them back.assets.py checkcompares only the EPS's sha256, so it can'tsee the change.
_pt_units()inudg/generators/assets.pysets the root tag'swidth/heighttopt. Innerelements keep their user units.
Testing
generator/tests/unit/test_plate_units.py(3 tests): Debian output gainspt, Homebrew outputis unchanged, and inner
<rect>sizes stay bare.python:3.12-slimwith Debianghostscriptandpoppler-utils:origin/mainassets.py): 3 derived plates change;just plates(macOS): 0 change.just check: exit 0.pytest generator/tests: 292 passed.Impact Statement
pt.Docs
None needed; the docstring explains the normalisation.