Package: pytest-pylint
Version: 0.14.1-2

The build is failing with pylint 2.4.4, log example from an Ubuntu build
https://launchpadlibrarian.net/454058807/buildlog_ubuntu-focal-amd64.pytest-pylint_0.14.1-2_BUILDING.txt.gz

I've reported the issue upstream
https://github.com/carsongee/pytest-pylint/issues/105

The debdiff attached should fix the issue

Cheers,

diff -Nru pytest-pylint-0.14.1/debian/changelog 
pytest-pylint-0.14.1/debian/changelog
--- pytest-pylint-0.14.1/debian/changelog       2019-11-19 08:01:18.000000000 
+0100
+++ pytest-pylint-0.14.1/debian/changelog       2019-12-03 11:06:41.000000000 
+0100
@@ -1,3 +1,10 @@
+pytest-pylint (0.14.1-3) unstable; urgency=medium
+
+  * debian/patches/import_warning_fix.patch:
+    - reorder imports to fix pylint import-outside-toplevel warnings
+
+ -- Sebastien Bacher <seb...@ubuntu.com>  Tue, 03 Dec 2019 10:58:36 +0100
+
 pytest-pylint (0.14.1-2) unstable; urgency=medium
 
   [ Ondřej Nový ]
diff -Nru pytest-pylint-0.14.1/debian/patches/import_warning_fix.patch 
pytest-pylint-0.14.1/debian/patches/import_warning_fix.patch
--- pytest-pylint-0.14.1/debian/patches/import_warning_fix.patch        
1970-01-01 01:00:00.000000000 +0100
+++ pytest-pylint-0.14.1/debian/patches/import_warning_fix.patch        
2019-12-03 11:02:18.000000000 +0100
@@ -0,0 +1,39 @@
+# Description: build was failing on pylint import-outside-toplevel tests
+# Upstream: https://github.com/carsongee/pytest-pylint/issues/105
+#
+--- test-pytest/test_pytest_pylint.py  2019-01-15 14:10:38.000000000 +0100
++++ test-pytest/test_pytest_pylint.py.new      2019-12-03 10:57:27.668814673 
+0100
+@@ -3,7 +3,8 @@
+ Unit testing module for pytest-pylint plugin
+ """
+ import mock
+-
++from pytest_pylint import get_rel_path
++from pytest_pylint import include_file
+ 
+ pytest_plugins = ('pytester',)  # pylint: disable=invalid-name
+ 
+@@ -128,7 +129,6 @@
+     """
+     Verify our relative path function.
+     """
+-    from pytest_pylint import get_rel_path
+     correct_rel_path = 'How/Are/You/blah.py'
+     path = '/Hi/How/Are/You/blah.py'
+     parent_path = '/Hi/'
+@@ -168,7 +168,6 @@
+     Files should only be included in the list if none of the directories on
+     it's path, of the filename, match an entry in the ignore list.
+     """
+-    from pytest_pylint import include_file
+     ignore_list = [
+         "first", "second", "third", "part", "base.py"
+     ]
+@@ -191,7 +190,6 @@
+ 
+ def test_pylint_ignore_patterns():
+     """Test if the ignore-patterns is working"""
+-    from pytest_pylint import include_file
+     ignore_patterns = [
+         "first.*",
+         ".*second",
diff -Nru pytest-pylint-0.14.1/debian/patches/series 
pytest-pylint-0.14.1/debian/patches/series
--- pytest-pylint-0.14.1/debian/patches/series  2019-07-25 14:03:35.000000000 
+0200
+++ pytest-pylint-0.14.1/debian/patches/series  2019-12-03 10:59:16.000000000 
+0100
@@ -1,2 +1,3 @@
 0001-Removed-PEP8-py.test-plugin.patch
 0002-Disable-abstract-method-pylint-check.patch
+import_warning_fix.patch

Reply via email to