Created attachment 1562734 [details] Full log from Copr python-svgwrite-1.2.1-1 fails to build with Python 3.8 as there are 71 test failures, most probably related to invalid escape sequences. /builddir/build/BUILD/svgwrite-1.2.1/tests/test_gradients.py:36: SyntaxWarning: invalid escape sequence \( self.assertTrue(re.match("^url\(#id\d+\) none$", lg.get_paint_server())) /builddir/build/BUILD/svgwrite-1.2.1/tests/test_gradients.py:37: SyntaxWarning: invalid escape sequence \( self.assertTrue(re.match("^url\(#id\d+\) red$", lg.get_paint_server(default='red'))) /builddir/build/BUILD/svgwrite-1.2.1/tests/test_gradients.py:68: SyntaxWarning: invalid escape sequence \( self.assertTrue(re.match("^url\(#id\d+\) none$", rg.get_paint_server())) /builddir/build/BUILD/svgwrite-1.2.1/tests/test_gradients.py:69: SyntaxWarning: invalid escape sequence \( self.assertTrue(re.match("^url\(#id\d+\) red$", rg.get_paint_server(default='red'))) /builddir/build/BUILD/svgwrite-1.2.1/tests/test_marker_class.py:29: SyntaxWarning: invalid escape sequence \d re.match('^<marker id="id\d+"><g /></marker>$', /builddir/build/BUILD/svgwrite-1.2.1/tests/test_xlink.py:45: SyntaxWarning: invalid escape sequence \d self.assertTrue(re.match('^<use xlink:href="#id\d+" />$', m.tostring())) This is due to https://bugs.python.org/issue32912 Full log attached
Created an upstream PR to fix SyntaxWarning : https://github.com/mozman/svgwrite/pull/50 Running the tests locally it seems that xml comparison tests use toString() where the insertion order is now preserved in https://bugs.python.org/issue34160. Upstream issue : https://github.com/mozman/svgwrite/issues/51 Thanks
Current status: Executing(%check): /bin/sh -e /var/tmp/rpm-tmp.kJnkDv + umask 022 + cd /builddir/build/BUILD + cd svgwrite-1.3.1 + /usr/bin/python3 -m unittest discover -s tests ............................................................................................................................................................................................................................................................................................................F..............s............................................................................................................................................................ ====================================================================== FAIL: test_pretty_print (test_pretty_xml.TestPrettyXML) ---------------------------------------------------------------------- Traceback (most recent call last): File "/builddir/build/BUILD/svgwrite-1.3.1/tests/test_pretty_xml.py", line 20, in test_pretty_print self.assertEqual(e, r) AssertionError: '<svg baseProfile="full" height="100%" version=[164 chars]nk">' != '<svg xmlns="http://www.w3.org/2000/svg" xmlns:[164 chars]0%">' - <svg baseProfile="full" height="100%" version="1.1" viewBox="0,0,10000,10000" width="100%" xmlns="http://www.w3.org/2000/svg" xmlns:ev="http://www.w3.org/2001/xml-events" xmlns:xlink="http://www.w3.org/1999/xlink"> + <svg xmlns="http://www.w3.org/2000/svg" xmlns:ev="http://www.w3.org/2001/xml-events" xmlns:xlink="http://www.w3.org/1999/xlink" baseProfile="full" height="100%" version="1.1" viewBox="0,0,10000,10000" width="100%"> ---------------------------------------------------------------------- Ran 472 tests in 0.407s FAILED (failures=1, skipped=1)
Created attachment 1590290 [details] Skip the broken test Given the output of the tests, I think we can just skip this test. I join a patch to do that. I don't have permission on the repo any more to push it. If you agree, you can apply it.
I was hoping the upstream maintainer would decide on skipping this and/or fix this (see https://github.com/mozman/svgwrite/pull/59), I've tried to fix the pretty print use case too, but gave up after few hours trying to understand how XML parsing works. I've added the skip as downstream patch for rawhide for now.