[med-svn] [Git][med-team/python-ruffus][master] 6 commits: strip unneeded overrides

Andreas Tille gitlab at salsa.debian.org
Wed Jul 11 14:54:37 BST 2018


Andreas Tille pushed to branch master at Debian Med / python-ruffus


Commits:
61ec07a2 by Andreas Tille at 2018-07-11T13:25:45+02:00
strip unneeded overrides

- - - - -
790be1b6 by Andreas Tille at 2018-07-11T13:25:58+02:00
Fix strange import error

- - - - -
f18105d6 by Andreas Tille at 2018-07-11T13:57:39+02:00
Make sure docs will be build

- - - - -
5fb829ab by Andreas Tille at 2018-07-11T13:59:27+02:00
Respect DEB_BUILD_OPTIONS in override_dh_auto_test

- - - - -
e2c92f0a by Andreas Tille at 2018-07-11T15:52:52+02:00
Fix interpreter in test files

- - - - -
b8ae6d33 by Andreas Tille at 2018-07-11T15:53:20+02:00
Avoid privacy breach

- - - - -


5 changed files:

- debian/changelog
- + debian/patches/fix_test.patch
- + debian/patches/privacy.patch
- debian/patches/series
- debian/rules


Changes:

=====================================
debian/changelog
=====================================
--- a/debian/changelog
+++ b/debian/changelog
@@ -4,6 +4,10 @@ python-ruffus (2.7-1) UNRELEASED; urgency=medium
     Closes: #903531
   * Standards-Version: 4.1.5
   * Build-Depends: python3-sphinx-rtd-theme
+  * d/rules: strip unneeded overrides
+  * Respect DEB_BUILD_OPTIONS in override_dh_auto_test
+  * Fix interpreter line in test suite
+  * Avoid privacy breach
 
  -- Andreas Tille <tille at debian.org>  Wed, 11 Jul 2018 11:21:00 +0200
 


=====================================
debian/patches/fix_test.patch
=====================================
--- /dev/null
+++ b/debian/patches/fix_test.patch
@@ -0,0 +1,25 @@
+Author: Andreas Tille <tille at debian.org>
+Last-Update: Wed, 11 Jul 2018 11:21:00 +0200
+Description: For some strange reason without this patch the test ends up in
+ .
+ ImportError: No module named ruffus
+
+--- a/ruffus/test/test_pool_manager.py
++++ b/ruffus/test/test_pool_manager.py
+@@ -1,8 +1,15 @@
++#!/usr/bin/env python
++import os
++import sys
++
++## add grandparent to search path for testing
++grandparent_dir = os.path.abspath(os.path.join(os.path.dirname(__file__), "..", ".."))
++sys.path.insert(0, grandparent_dir)
++
+ import contextlib
+ import random
+ import unittest
+ import ruffus
+-import os
+ import shutil
+ import glob
+ import tempfile


=====================================
debian/patches/privacy.patch
=====================================
--- /dev/null
+++ b/debian/patches/privacy.patch
@@ -0,0 +1,16 @@
+Author: Andreas Tille <tille at debian.org>
+Last-Update: Wed, 11 Jul 2018 11:21:00 +0200
+Description: Avoid privacy issue
+
+--- a/doc/_templates/index.html
++++ b/doc/_templates/index.html
+@@ -153,8 +153,7 @@ The very latest (in development) code ca
+   </li>
+   
+   <li>
+-    <img src="https://groups.google.com/forum/my-groups-color.png"
+-             height=30 alt="Google Groups"> <b>Subscribe to the <a href="https://groups.google.com/forum/#!forum/ruffus_discuss"><i>ruffus_discuss</i> mailing list </a></b>
++    <b>Subscribe to the <a href="https://groups.google.com/forum/#!forum/ruffus_discuss"><i>ruffus_discuss</i> mailing list </a></b>
+     <br>    
+     <form action="http://groups.google.com/group/ruffus_discuss/boxsubscribe">
+     Email: <input type=text name=email>


=====================================
debian/patches/series
=====================================
--- a/debian/patches/series
+++ b/debian/patches/series
@@ -1,3 +1,5 @@
 use_libjs-mathjax.patch
 sphinx.ext.pngmath_deprecated.patch
 use_png_instead_of_jpg.patch
+fix_test.patch
+privacy.patch


=====================================
debian/rules
=====================================
--- a/debian/rules
+++ b/debian/rules
@@ -8,25 +8,24 @@ docpkg:=$(DEB_SOURCE)-doc
 
 export PYBUILD_NAME=ruffus
 
-pyrun = DEB_BUILD_OPTIONS= pybuild -s custom -p $(shell pyversions -dv) --test --test-args
-
 %:
 	dh $@ --with python2,python3,sphinxdoc --buildsystem=pybuild
 
 override_dh_auto_build:
-	$(pyrun) 'make --directory=doc html'
-	## latexpdf # <--- several LaTeX errors occure - just take the PDF provided by upstream
+	dh_auto_build
+	make --directory=doc html
 
 override_dh_installdocs:
 	dh_installdocs -ppython-ruffus-doc doc/_build/html
 	dh_installdocs -A
 
 override_dh_auto_test:
-	# cd ruffus/test && . $(CURDIR)/debian/tests/run-unit-test
+ifeq (,$(filter nocheck,$(DEB_BUILD_OPTIONS)))
 	cd ruffus/test && \
 	sh ./run_all_unit_tests.cmd && \
 	sh ./run_all_unit_tests3.cmd && \
 	rm -rf .ruffus_history.sqlite __pycache__ *.pyc
+endif
 
 override_dh_auto_clean:
 	dh_auto_clean
@@ -40,3 +39,15 @@ override_dh_auto_clean:
 	       doc/_build/doctrees \
 	       ruffus/test/*.log \
 	       .ruffus_history.sqlite
+
+override_dh_install:
+	dh_install
+	# test files have all #!/usr/bin/python which looks wrong in python3 package
+	find debian/python3-$(PYBUILD_NAME)/usr/lib/python3*/dist-packages/ruffus/test -name "*.py" -exec sed -i 's+^\(#!/usr/bin/.*python\)[[:space:]]*$$+\13+' \{\} \;
+	# leave only the test starter that fits Python version
+	find debian/python3-$(PYBUILD_NAME) -name run_all_unit_tests.cmd -delete
+	find debian/python-$(PYBUILD_NAME) -name run_all_unit_tests3.cmd -delete
+
+override_dh_fixperms:
+	dh_fixperms
+	find debian -name "run_all_unit_tests*.cmd" -exec chmod +x \{\} \;



View it on GitLab: https://salsa.debian.org/med-team/python-ruffus/compare/4ac17466810e818d09a007489f821390b89a4d9c...b8ae6d331b079b78adc1cfbff7825808ff266cb4

-- 
View it on GitLab: https://salsa.debian.org/med-team/python-ruffus/compare/4ac17466810e818d09a007489f821390b89a4d9c...b8ae6d331b079b78adc1cfbff7825808ff266cb4
You're receiving this email because of your account on salsa.debian.org.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://alioth-lists.debian.net/pipermail/debian-med-commit/attachments/20180711/8ef32f8f/attachment-0001.html>


More information about the debian-med-commit mailing list