pkgsrc-Changes archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

CVS commit: pkgsrc/print/py-pisa



Module Name:    pkgsrc
Committed By:   joerg
Date:           Mon Jan  8 22:11:06 UTC 2018

Modified Files:
        pkgsrc/print/py-pisa: Makefile distinfo
Added Files:
        pkgsrc/print/py-pisa/patches: patch-sx_pisa3_pisa__context.py
            patch-sx_pisa3_pisa__parser.py

Log Message:
Deal with py-html5lib API changes. Bump revision.


To generate a diff of this commit:
cvs rdiff -u -r1.19 -r1.20 pkgsrc/print/py-pisa/Makefile
cvs rdiff -u -r1.9 -r1.10 pkgsrc/print/py-pisa/distinfo
cvs rdiff -u -r0 -r1.1 \
    pkgsrc/print/py-pisa/patches/patch-sx_pisa3_pisa__context.py \
    pkgsrc/print/py-pisa/patches/patch-sx_pisa3_pisa__parser.py

Please note that diffs are not public domain; they are subject to the
copyright notices on the relevant files.

Modified files:

Index: pkgsrc/print/py-pisa/Makefile
diff -u pkgsrc/print/py-pisa/Makefile:1.19 pkgsrc/print/py-pisa/Makefile:1.20
--- pkgsrc/print/py-pisa/Makefile:1.19  Sat Sep 30 07:52:18 2017
+++ pkgsrc/print/py-pisa/Makefile       Mon Jan  8 22:11:06 2018
@@ -1,8 +1,8 @@
-# $NetBSD: Makefile,v 1.19 2017/09/30 07:52:18 wiz Exp $
+# $NetBSD: Makefile,v 1.20 2018/01/08 22:11:06 joerg Exp $
 
 DISTNAME=      pisa-3.0.33
 PKGNAME=       ${PYPKGPREFIX}-${DISTNAME}
-PKGREVISION=   2
+PKGREVISION=   3
 CATEGORIES=    textproc print www python
 MASTER_SITES=  ${MASTER_SITE_PYPI:=p/pisa/}
 
@@ -19,10 +19,9 @@ PYTHON_VERSIONS_INCOMPATIBLE=        34 35 36 #
 
 # remove CRs: fixes patching on Darwin and stops pkglint from complaining
 pre-patch:
-.for f in css.py cssDOMElementInterface.py
-       ${TR} -d '\r' < ${WRKSRC}/sx/w3c/${f} > ${WRKSRC}/sx/w3c/${f}.new
-       ${MV} ${WRKSRC}/sx/w3c/${f}.new ${WRKSRC}/sx/w3c/${f}
-.endfor
+       cd ${WRKSRC} && for f in sx/*/*.py; do \
+               ${TR} -d '\r' < $$f > $${f}.new && ${MV} $${f}.new $$f; \
+       done
 
 .include "../../lang/python/egg.mk"
 .include "../../mk/bsd.pkg.mk"

Index: pkgsrc/print/py-pisa/distinfo
diff -u pkgsrc/print/py-pisa/distinfo:1.9 pkgsrc/print/py-pisa/distinfo:1.10
--- pkgsrc/print/py-pisa/distinfo:1.9   Thu Jun 29 20:02:02 2017
+++ pkgsrc/print/py-pisa/distinfo       Mon Jan  8 22:11:06 2018
@@ -1,9 +1,11 @@
-$NetBSD: distinfo,v 1.9 2017/06/29 20:02:02 joerg Exp $
+$NetBSD: distinfo,v 1.10 2018/01/08 22:11:06 joerg Exp $
 
 SHA1 (pisa-3.0.33.tar.gz) = 3d7e644b96b7c8f98bfd5823a163c3badd662209
 RMD160 (pisa-3.0.33.tar.gz) = 1479865d1f0b14f4a37c74fc8aae7e72e9d0efac
 SHA512 (pisa-3.0.33.tar.gz) = 5d11d717734ca30876697ce25c77f381a560f4b266b2dbd9f2445ac9b39e2750cc3ff31603d9a1cba6ed51a047fca38ac95a2a4dddf88b238aa5c0d6f810a975
 Size (pisa-3.0.33.tar.gz) = 4500555 bytes
 SHA1 (patch-aa) = 39354cac1592787d43622c04ef776f13b39450ca
+SHA1 (patch-sx_pisa3_pisa__context.py) = 3822f8b4e155bf6d2cbe57304d641dee459151fe
+SHA1 (patch-sx_pisa3_pisa__parser.py) = 54a582b177ec5866ad2b3ba0db8d7a3bc9b8ad51
 SHA1 (patch-sx_pisa3_pisa__reportlab.py) = 0eb4a042b151d94ee8d3d12fc00b28fee4b31e48
 SHA1 (patch-sx_pisa3_pisa__util.py) = 130f9ac339239b71fc6a4920c0cadcccdbc1a913

Added files:

Index: pkgsrc/print/py-pisa/patches/patch-sx_pisa3_pisa__context.py
diff -u /dev/null pkgsrc/print/py-pisa/patches/patch-sx_pisa3_pisa__context.py:1.1
--- /dev/null   Mon Jan  8 22:11:06 2018
+++ pkgsrc/print/py-pisa/patches/patch-sx_pisa3_pisa__context.py        Mon Jan  8 22:11:06 2018
@@ -0,0 +1,16 @@
+$NetBSD: patch-sx_pisa3_pisa__context.py,v 1.1 2018/01/08 22:11:06 joerg Exp $
+
+--- sx/pisa3/pisa_context.py.orig      2018-01-08 14:18:52.579405122 +0000
++++ sx/pisa3/pisa_context.py
+@@ -40,7 +40,10 @@ from reportlab.lib.fonts import addMappi
+ 
+ from sx.w3c import css, cssDOMElementInterface
+ 
+-from html5lib.sanitizer import *
++try:
++    from html5lib.filters.sanitizer import *
++except ImportError:
++    from html5lib.sanitizer import *
+ 
+ import logging
+ log = logging.getLogger("ho.pisa")
Index: pkgsrc/print/py-pisa/patches/patch-sx_pisa3_pisa__parser.py
diff -u /dev/null pkgsrc/print/py-pisa/patches/patch-sx_pisa3_pisa__parser.py:1.1
--- /dev/null   Mon Jan  8 22:11:06 2018
+++ pkgsrc/print/py-pisa/patches/patch-sx_pisa3_pisa__parser.py Mon Jan  8 22:11:06 2018
@@ -0,0 +1,29 @@
+$NetBSD: patch-sx_pisa3_pisa__parser.py,v 1.1 2018/01/08 22:11:06 joerg Exp $
+
+--- sx/pisa3/pisa_parser.py.orig       2018-01-08 15:08:43.919276904 +0000
++++ sx/pisa3/pisa_parser.py
+@@ -26,7 +26,11 @@ import os
+ import os.path
+ 
+ import html5lib
+-from html5lib import treebuilders, serializer, treewalkers, inputstream
++from html5lib import treebuilders, serializer, treewalkers
++try:
++    from html5lib import inputstream
++except ImportError:
++    from html5lib import _inputstream as inputstream
+ from xml.dom import Node
+ import xml.dom.minidom
+ 
+@@ -612,9 +616,8 @@ def pisaParser(src, c, default_css="", x
+                  log.error("%r is not a valid encoding", encoding)
+     
+     document = parser.parse(
+-        src,
+-        encoding=encoding)
+-        
++        src)
++
+     if xml_output:        
+         xml_output.write(document.toprettyxml(encoding="utf8"))    
+ 



Home | Main Index | Thread Index | Old Index