mozman / svgwrite

Python Package to write SVG files (UNMAINTAINED)
Other
547 stars 97 forks source link

Change validation type in Polyline #114

Closed normanrz closed 2 years ago

normanrz commented 2 years ago

This validation also needs to check for number, otherwise it will be in conflict with https://github.com/normanrz/svgwrite/blob/cc938e018b828bdfa84a3911439bb55dd20651b5/svgwrite/shapes.py#L122-L123

normanrz commented 2 years ago

The tests are failing, because there are coordinates used as points (ie. with units). From how I read the spec, points need to be composed of numbers only. I'll go ahead and adapt the tests.

mozman commented 2 years ago

svgwrite does not support SVG2!

normanrz commented 2 years ago

Fair point. I didn't know that. What would you advise? Shall I change the validations to coordinate everywhere and revert the tests, then?

mozman commented 2 years ago

First line of README.rst:

This package is inactive! No new features will be added, there will be no change of behavior, just bugfixes will be merged.

Is this a bug? I don't use this package and I don't want to read the specs again!

normanrz commented 2 years ago

Is this a bug?

Yes, it is a bug. I read through the specs, points are list-of-points, which can take pairs of coordinates. I adapted the validations and tests accordingly.

mozman commented 2 years ago

Thank you!