Commit 5c827c6d authored by Robert Schütz's avatar Robert Schütz
Browse files

python3Packages.flake8-future-import: remove outdated patches

parent 855d20d1
Loading
Loading
Loading
Loading
+3 −13
Original line number Diff line number Diff line
@@ -2,10 +2,6 @@
  lib,
  buildPythonPackage,
  fetchFromGitHub,
  isPy27,
  isPy38,
  isPy39,
  pythonAtLeast,
  setuptools,
  flake8,
  six,
@@ -25,14 +21,8 @@ buildPythonPackage rec {
    hash = "sha256-2EcCOx3+PCk9LYpQjHCFNpQVI2Pdi+lWL8R6bNadFe0=";
  };

  patches =
    lib.optionals (pythonAtLeast "3.10") [ ./fix-annotations-version-11.patch ]
    ++ lib.optionals (isPy38 || isPy39) [ ./fix-annotations-version-10.patch ]
    ++ lib.optionals isPy27 [
      # Upstream disables this test case naturally on python 3, but it also fails
      # inside NixPkgs for python 2. Since it's going to be deleted, we just skip it
      # on py2 as well.
      ./skip-test.patch
  patches = [
    ./fix-annotations-version-11.patch
  ];

  postPatch = ''
+0 −13
Original line number Diff line number Diff line
diff --git a/flake8_future_import.py b/flake8_future_import.py
index 92c3fda..27a1a66 100755
--- a/flake8_future_import.py
+++ b/flake8_future_import.py
@@ -76,7 +76,7 @@ UNICODE_LITERALS = Feature(4, 'unicode_literals', (2, 6, 0), (3, 0, 0))
 GENERATOR_STOP = Feature(5, 'generator_stop', (3, 5, 0), (3, 7, 0))
 NESTED_SCOPES = Feature(6, 'nested_scopes', (2, 1, 0), (2, 2, 0))
 GENERATORS = Feature(7, 'generators', (2, 2, 0), (2, 3, 0))
-ANNOTATIONS = Feature(8, 'annotations', (3, 7, 0), (4, 0, 0))
+ANNOTATIONS = Feature(8, 'annotations', (3, 7, 0), (3, 10, 0))
 
 
 # Order important as it defines the error code
+0 −13
Original line number Diff line number Diff line
diff --git a/test_flake8_future_import.py b/test_flake8_future_import.py
index 84fde59..345f23f 100644
--- a/test_flake8_future_import.py
+++ b/test_flake8_future_import.py
@@ -230,7 +230,7 @@ class TestBadSyntax(TestCaseBase):
     """Test using various bad syntax examples from Python's library."""
 
 
-@unittest.skipIf(sys.version_info[:2] >= (3, 7), 'flake8 supports up to 3.6')
+@unittest.skip("Has issue with installed path for flake8 in python2")
 class Flake8TestCase(TestCaseBase):
 
     """