[Python-modules-commits] [python-prov] 02/03: Initial debianization.
Ghislain Vaillant
ghisvail-guest at moszumanska.debian.org
Fri Jul 22 22:12:58 UTC 2016
This is an automated email from the git hooks/post-receive script.
ghisvail-guest pushed a commit to branch debian/master
in repository python-prov.
commit 2555e98e0065a00d0804ef7199bce4afa3796de5
Author: Ghislain Antony Vaillant <ghisvail at gmail.com>
Date: Fri Jul 22 11:14:33 2016 +0100
Initial debianization.
---
debian/changelog | 5 +
debian/compat | 1 +
debian/control | 107 +++++++++++++++++++++
debian/copyright | 40 ++++++++
debian/gbp.conf | 9 ++
...ated-usage-of-cgi.escape-since-Python-3.3.patch | 45 +++++++++
debian/patches/series | 2 +
..._xml-decode-buffers-to-work-with-py3-also.patch | 33 +++++++
debian/prov-tools.lintian-overrides | 4 +
debian/python-prov-doc.doc-base | 9 ++
debian/python-prov-doc.docs | 1 +
debian/rules | 24 +++++
debian/source/format | 1 +
debian/tests/control | 7 ++
debian/watch | 3 +
15 files changed, 291 insertions(+)
diff --git a/debian/changelog b/debian/changelog
new file mode 100644
index 0000000..217b2c7
--- /dev/null
+++ b/debian/changelog
@@ -0,0 +1,5 @@
+python-prov (1.4.0-1) UNRELEASED; urgency=low
+
+ * Initial release. (Closes: #823436)
+
+ -- Ghislain Antony Vaillant <ghisvail at gmail.com> Fri, 22 Jul 2016 11:07:21 +0100
diff --git a/debian/compat b/debian/compat
new file mode 100644
index 0000000..ec63514
--- /dev/null
+++ b/debian/compat
@@ -0,0 +1 @@
+9
diff --git a/debian/control b/debian/control
new file mode 100644
index 0000000..55f6717
--- /dev/null
+++ b/debian/control
@@ -0,0 +1,107 @@
+Source: python-prov
+Maintainer: Debian Python Modules Team <python-modules-team at lists.alioth.debian.org>
+Uploaders: Ghislain Antony Vaillant <ghisvail at gmail.com>
+Section: python
+Testsuite: autopkgtest
+Priority: optional
+Build-Depends: debhelper (>= 9),
+ dh-python,
+ python-all,
+ python-dateutil,
+ python-lxml,
+ python-networkx (>= 1.10),
+ python-pydotplus,
+ python-setuptools,
+ python-six (>= 1.9.0),
+ python-sphinx,
+ python3-all,
+ python3-dateutil,
+ python3-lxml,
+ python3-networkx (>= 1.10),
+ python3-pydotplus,
+ python3-setuptools,
+ python3-six (>= 1.9.0)
+Standards-Version: 3.9.8
+Vcs-Browser: https://anonscm.debian.org/cgit/python-modules/packages/python-prov.git
+Vcs-Git: https://anonscm.debian.org/git/python-modules/packages/python-prov.git
+Homepage: https://github.com/trungdong/prov
+X-Python-Version: >= 2.7
+X-Python3-Version: >= 3.3
+
+Package: python-prov
+Architecture: all
+Depends: ${misc:Depends},
+ ${python:Depends}
+Suggests: python-prov-doc,
+ python-pydotplus
+Description: W3C Provenance Data Model (Python 2)
+ A library for W3C Provenance Data Model supporting PROV-JSON and PROV-
+ XML import/export.
+ .
+ Features:
+ - An implementation of the W3C PROV Data Model in Python.
+ - In-memory classes for PROV assertions, which can then be output
+ as PROV-N.
+ - Serialization and deserializtion support: PROV-JSON and PROV-XML.
+ - Exporting PROV documents into various graphical formats (e.g. PDF,
+ PNG, SVG).
+ .
+ This package provides the prov library for Python 2.
+
+Package: python3-prov
+Architecture: all
+Depends: ${misc:Depends},
+ ${python3:Depends}
+Suggests: python-prov-doc,
+ python3-pydotplus
+Description: W3C Provenance Data Model (Python 3)
+ A library for W3C Provenance Data Model supporting PROV-JSON and PROV-
+ XML import/export.
+ .
+ Features:
+ - An implementation of the W3C PROV Data Model in Python.
+ - In-memory classes for PROV assertions, which can then be output
+ as PROV-N.
+ - Serialization and deserializtion support: PROV-JSON and PROV-XML.
+ - Exporting PROV documents into various graphical formats (e.g. PDF,
+ PNG, SVG).
+ .
+ This package provides the prov library for Python 3.
+
+Package: python-prov-doc
+Architecture: all
+Section: doc
+Depends: ${misc:Depends},
+ ${sphinxdoc:Depends}
+Description: documentation for prov
+ A library for W3C Provenance Data Model supporting PROV-JSON and PROV-
+ XML import/export.
+ .
+ Features:
+ - An implementation of the W3C PROV Data Model in Python.
+ - In-memory classes for PROV assertions, which can then be output
+ as PROV-N.
+ - Serialization and deserializtion support: PROV-JSON and PROV-XML.
+ - Exporting PROV documents into various graphical formats (e.g. PDF,
+ PNG, SVG).
+ .
+ This package provides the documentation for the prov library.
+
+Package: prov-tools
+Architecture: all
+Depends: ${misc:Depends},
+ ${python3:Depends},
+ python3-prov (= ${binary:Version})
+Description: tools for prov
+ A library for W3C Provenance Data Model supporting PROV-JSON and PROV-
+ XML import/export.
+ .
+ Features:
+ - An implementation of the W3C PROV Data Model in Python.
+ - In-memory classes for PROV assertions, which can then be output
+ as PROV-N.
+ - Serialization and deserializtion support: PROV-JSON and PROV-XML.
+ - Exporting PROV documents into various graphical formats (e.g. PDF,
+ PNG, SVG).
+ .
+ This package provides the command-line tools for the prov library.
diff --git a/debian/copyright b/debian/copyright
new file mode 100644
index 0000000..06475f2
--- /dev/null
+++ b/debian/copyright
@@ -0,0 +1,40 @@
+Format: https://www.debian.org/doc/packaging-manuals/copyright-format/1.0/
+Upstream-Name: prov
+Upstream-Contact: Trung Dong Huynh <trungdong at donggiang.com>
+Source: https://pypi.python.org/pypi/prov
+
+Files: *
+Copyright: 2014 University of Southampton
+License: Expat
+
+Files: debian/*
+Copyright: 2016 Ghislain Antony Vaillant <ghisvail at gmail.com>
+License: Expat
+
+License: Expat
+ The MIT License
+ .
+ Permission is hereby granted, free of charge, to any person
+ obtaining a copy of this software and associated
+ documentation files (the "Software"), to deal in the Software
+ without restriction, including without limitation the rights to
+ use, copy, modify, merge, publish, distribute, sublicense,
+ and/or sell copies of the Software, and to permit persons to
+ whom the Software is furnished to do so, subject to the
+ following conditions:
+ .
+ The above copyright notice and this permission notice shall
+ be included in all copies or substantial portions of the
+ Software.
+ .
+ THE SOFTWARE IS PROVIDED "AS IS", WITHOUT
+ WARRANTY OF ANY KIND, EXPRESS OR IMPLIED,
+ INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
+ MERCHANTABILITY, FITNESS FOR A PARTICULAR
+ PURPOSE AND NONINFRINGEMENT. IN NO EVENT
+ SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE
+ LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
+ LIABILITY, WHETHER IN AN ACTION OF CONTRACT,
+ TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN
+ CONNECTION WITH THE SOFTWARE OR THE USE OR
+ OTHER DEALINGS IN THE SOFTWARE.
diff --git a/debian/gbp.conf b/debian/gbp.conf
new file mode 100644
index 0000000..ea5c858
--- /dev/null
+++ b/debian/gbp.conf
@@ -0,0 +1,9 @@
+[DEFAULT]
+upstream-branch = upstream/latest
+debian-branch = debian/master
+upstream-tag = upstream/%(version)s
+debian-tag = debian/%(version)s
+pristine-tar = True
+
+[pq]
+patch-numbers = False
diff --git a/debian/patches/Fix-deprecated-usage-of-cgi.escape-since-Python-3.3.patch b/debian/patches/Fix-deprecated-usage-of-cgi.escape-since-Python-3.3.patch
new file mode 100644
index 0000000..455884d
--- /dev/null
+++ b/debian/patches/Fix-deprecated-usage-of-cgi.escape-since-Python-3.3.patch
@@ -0,0 +1,45 @@
+From 1b3353944085e01807ae90e5fcf1e5848604e0dc Mon Sep 17 00:00:00 2001
+From: Ghislain Antony Vaillant <ghisvail at gmail.com>
+Date: Fri, 22 Jul 2016 14:49:03 +0100
+Subject: [PATCH] Fix deprecated usage of cgi.escape since Python 3.3
+
+---
+ prov/dot.py | 13 ++++++++-----
+ 1 file changed, 8 insertions(+), 5 deletions(-)
+
+diff --git a/prov/dot.py b/prov/dot.py
+index 57adfc3..8e531de 100644
+--- a/prov/dot.py
++++ b/prov/dot.py
+@@ -17,7 +17,10 @@ from __future__ import (absolute_import, division, print_function,
+ __author__ = 'Trung Dong Huynh'
+ __email__ = 'trungdong at donggiang.com'
+
+-import cgi
++try:
++ from html import escape
++except ImportError:
++ from cgi import escape
+ from datetime import datetime
+ import pydotplus as pydot
+ import six
+@@ -175,12 +178,12 @@ def prov_to_dot(bundle, show_nary=True, use_labels=False,
+ ann_rows = [ANNOTATION_START_ROW]
+ ann_rows.extend(
+ ANNOTATION_ROW_TEMPLATE % (
+- attr.uri, cgi.escape(six.text_type(attr)),
++ attr.uri, escape(six.text_type(attr)),
+ ' href=\"%s\"' % value.uri if isinstance(value, Identifier)
+ else '',
+- cgi.escape(six.text_type(value)
+- if not isinstance(value, datetime) else
+- six.text_type(value.isoformat())))
++ escape(six.text_type(value)
++ if not isinstance(value, datetime) else
++ six.text_type(value.isoformat())))
+ for attr, value in attributes
+ )
+ ann_rows.append(ANNOTATION_END_ROW)
+--
+2.8.1
+
diff --git a/debian/patches/series b/debian/patches/series
new file mode 100644
index 0000000..429ace5
--- /dev/null
+++ b/debian/patches/series
@@ -0,0 +1,2 @@
+test_xml-decode-buffers-to-work-with-py3-also.patch
+Fix-deprecated-usage-of-cgi.escape-since-Python-3.3.patch
diff --git a/debian/patches/test_xml-decode-buffers-to-work-with-py3-also.patch b/debian/patches/test_xml-decode-buffers-to-work-with-py3-also.patch
new file mode 100644
index 0000000..e0ec4b4
--- /dev/null
+++ b/debian/patches/test_xml-decode-buffers-to-work-with-py3-also.patch
@@ -0,0 +1,33 @@
+From bdbc6fb97b52a76239498064764e2140c2236251 Mon Sep 17 00:00:00 2001
+From: Igor Gnatenko <i.gnatenko.brain at gmail.com>
+Date: Sun, 6 Dec 2015 23:06:31 +0100
+Subject: [PATCH] test_xml: decode() buffers to work with py3 also
+
+Signed-off-by: Igor Gnatenko <i.gnatenko.brain at gmail.com>
+---
+ prov/tests/test_xml.py | 4 ++--
+ 1 file changed, 2 insertions(+), 2 deletions(-)
+
+diff --git a/prov/tests/test_xml.py b/prov/tests/test_xml.py
+index 79fb7eb..533b967 100644
+--- a/prov/tests/test_xml.py
++++ b/prov/tests/test_xml.py
+@@ -64,13 +64,13 @@ def compare_xml(doc1, doc2):
+ buf = io.BytesIO()
+ obj1.write_c14n(buf)
+ buf.seek(0, 0)
+- str1 = buf.read()
++ str1 = buf.read().decode()
+ str1 = [_i.strip() for _i in str1.splitlines() if _i.strip()]
+
+ buf = io.BytesIO()
+ obj2.write_c14n(buf)
+ buf.seek(0, 0)
+- str2 = buf.read()
++ str2 = buf.read().decode()
+ str2 = [_i.strip() for _i in str2.splitlines() if _i.strip()]
+
+ unified_diff = difflib.unified_diff(str1, str2)
+--
+2.8.1
+
diff --git a/debian/prov-tools.lintian-overrides b/debian/prov-tools.lintian-overrides
new file mode 100644
index 0000000..1590162
--- /dev/null
+++ b/debian/prov-tools.lintian-overrides
@@ -0,0 +1,4 @@
+# Upstream does not (yet) provide a mean to generate the respective manpages
+# for its scripts. This issue is currently discussed here:
+# https://github.com/trungdong/prov/issues/83
+binary-without-manpage
diff --git a/debian/python-prov-doc.doc-base b/debian/python-prov-doc.doc-base
new file mode 100644
index 0000000..fb5ca0b
--- /dev/null
+++ b/debian/python-prov-doc.doc-base
@@ -0,0 +1,9 @@
+Document: python-prov-doc
+Title: prov Documentation
+Author: Trung Dong Huynh
+Abstract: This is the reference documentation of the prov Python library.
+Section: Programming
+
+Format: HTML
+Index: /usr/share/doc/python-prov-doc/html/index.html
+Files: /usr/share/doc/python-prov-doc/html/*.html
diff --git a/debian/python-prov-doc.docs b/debian/python-prov-doc.docs
new file mode 100644
index 0000000..6d28621
--- /dev/null
+++ b/debian/python-prov-doc.docs
@@ -0,0 +1 @@
+build/html
diff --git a/debian/rules b/debian/rules
new file mode 100755
index 0000000..c87c0a4
--- /dev/null
+++ b/debian/rules
@@ -0,0 +1,24 @@
+#! /usr/bin/make -f
+
+# Uncomment this to turn on verbose mode.
+#export DH_VERBOSE = 1
+
+export PYBUILD_NAME = prov
+export PYBUILD_DESTDIR_python3 = debian/python3-$(PYBUILD_NAME)
+export PYBUILD_AFTER_INSTALL_python2 = rm -rf {destdir}/usr/bin
+
+%:
+ dh $@ --with python2,python3,sphinxdoc --buildsystem=pybuild
+
+override_dh_auto_build:
+ dh_auto_build
+ PYTHONPATH=. http_proxy='127.0.0.1:9' \
+ sphinx-build -N -b html docs build/html
+
+override_dh_auto_install:
+ dh_auto_install
+ dh_movefiles --package=$(PYBUILD_NAME)-tools \
+ --sourcedir=$(PYBUILD_DESTDIR_python3) usr/bin
+
+override_dh_installchangelogs:
+ dh_installchangelogs HISTORY.rst
diff --git a/debian/source/format b/debian/source/format
new file mode 100644
index 0000000..163aaf8
--- /dev/null
+++ b/debian/source/format
@@ -0,0 +1 @@
+3.0 (quilt)
diff --git a/debian/tests/control b/debian/tests/control
new file mode 100644
index 0000000..37e41df
--- /dev/null
+++ b/debian/tests/control
@@ -0,0 +1,7 @@
+Test-Command: cp -R prov/tests $AUTOPKGTEST_TMP ; cd $AUTOPKGTEST_TMP
+ ; python -m unittest discover 2>&1
+Depends: python, python-prov, python-pydotplus
+
+Test-Command: cp -R prov/tests $AUTOPKGTEST_TMP ; cd $AUTOPKGTEST_TMP
+ ; python3 -m unittest discover 2>&1
+Depends: python3, python3-prov, python3-pydotplus
diff --git a/debian/watch b/debian/watch
new file mode 100644
index 0000000..9f88fd8
--- /dev/null
+++ b/debian/watch
@@ -0,0 +1,3 @@
+version=3
+opts=uversionmangle=s/(rc|a|b|c)/~$1/ \
+http://pypi.debian.net/prov/prov-(.+)\.(?:zip|tgz|tbz|txz|(?:tar\.(?:gz|bz2|xz)))
--
Alioth's /usr/local/bin/git-commit-notice on /srv/git.debian.org/git/python-modules/packages/python-prov.git
More information about the Python-modules-commits
mailing list