gnu: python-hacking: Update to 4.0.0.

Fixes <https://issues.guix.gnu.org/39871>.

* gnu/packages/openstack.scm (python-hacking): Update to 4.0.0.
[arguments]: Remove field.
[propagated-inputs]: Remove python-flake8-2.6, python-mccabe-0.2.1, python-pbr,
python-pep8-1.5.7, python-pyflakes-1.2, python-six.  Add python-flake8.
[native-inputs]: Remove python-reno and python-testrepository.  Add
python-coverage, python-ddt, python-dnspython, python-fixtures,
python-monotonic, python-subunit, python-stestr and python-testtools.
(python2-hacking): Remove variable.
* gnu/packages/python-xyz.scm (python-pyflakes-1.2)
(python-mccabe-0.2.1, python2-mccabe-0.2.1)
(python-pep8-1.5.7, python2-pep8-1.5.7)
(python-flake8-2.6): Delete variables.
This commit is contained in:
Maxim Cournoyer 2020-11-18 16:14:15 -05:00
parent e8d1637be3
commit 226b2af51a
No known key found for this signature in database
GPG key ID: 1260E46482E63562
2 changed files with 15 additions and 113 deletions

View file

@ -5,6 +5,7 @@
;;; Copyright © 2018, 2019 Tobias Geerinckx-Rice <me@tobias.gr>
;;; Copyright © 2018 Marius Bakke <mbakke@fastmail.com>
;;; Copyright © 2020 Ricardo Wurmus <rekado@elephly.net>
;;; Copyright © 2020 Maxim Cournoyer <maxim.cournoyer@gmail.com>
;;;
;;; This file is part of GNU Guix.
;;;
@ -26,6 +27,7 @@ (define-module (gnu packages openstack)
#:use-module (gnu packages check)
#:use-module (gnu packages gnupg)
#:use-module (gnu packages python)
#:use-module (gnu packages python-check)
#:use-module (gnu packages python-crypto)
#:use-module (gnu packages python-web)
#:use-module (gnu packages python-xyz)
@ -148,39 +150,30 @@ (define-public python2-debtcollector
(define-public python-hacking
(package
(name "python-hacking")
(version "1.1.0")
(version "4.0.0")
(source
(origin
(method url-fetch)
(uri (pypi-uri "hacking" version))
(sha256
(base32
"1vlgh81v4vsw3q3cf7qggsp043vq16knp203lrll82h7l7rhd8r3"))))
"062rvbkvbavqqz55f7q00ikwipkn5j0rdls1rrajdbfwgckjcrsm"))))
(build-system python-build-system)
(arguments
`(#:phases
(modify-phases %standard-phases
(add-after 'unpack 'delete-broken-test
(lambda _
;; TODO: Just one test fails:
;; hacking.tests.test_doctest.HackingTestCase.test_pycodestyle
;; (H403-hacking_docstring_multiline_end-line-5)
(delete-file "hacking/tests/test_doctest.py")
#t)))))
(propagated-inputs
`(("python-flake8" ,python-flake8-2.6)
("python-mccabe-0.2.1" ,python-mccabe-0.2.1)
("python-pbr" ,python-pbr)
("python-pep8-1.5.7" ,python-pep8-1.5.7)
("python-pyflakes-1.2" ,python-pyflakes-1.2)
("python-six" ,python-six)))
(propagated-inputs
`(("python-flake8" ,python-flake8)))
(native-inputs
`( ;; Tests
("python-coverage" ,python-coverage)
("python-ddt" ,python-ddt)
("python-dnspython" ,python-dnspython)
("python-fixtures" ,python-fixtures)
("python-eventlet" ,python-eventlet)
("python-mock" ,python-mock)
("python-reno" ,python-reno)
("python-testrepository" ,python-testrepository)
("python-testscenarios" ,python-testscenarios)))
("python-monotonic" ,python-monotonic)
("python-subunit" ,python-subunit)
("python-stestr" ,python-stestr)
("python-testscenarios" ,python-testscenarios)
("python-testtools" ,python-testtools)))
(home-page "https://github.com/openstack-dev/hacking")
(synopsis "OpenStack hacking guideline enforcement")
(description
@ -189,9 +182,6 @@ (define-public python-hacking
guidelines}.")
(license asl2.0)))
(define-public python2-hacking
(package-with-python2 python-hacking))
(define-public python-mox3
(package
(name "python-mox3")

View file

@ -8137,27 +8137,6 @@ (define-public python-pyflakes
(define-public python2-pyflakes
(package-with-python2 python-pyflakes))
;; Flake8 2.6 requires an older version of pyflakes.
;; This should be removed ASAP.
(define-public python-pyflakes-1.2
(package (inherit python-pyflakes)
(version "1.2.3")
(source
(origin
(method url-fetch)
(uri (pypi-uri "pyflakes" version))
(sha256
(base32
"17hkw8yd44cr8fz13phy4aih3r5j2p7ild4zlvqdh2c8dmiinjif"))))
(arguments
'(#:phases
(modify-phases %standard-phases
;; This one test fails.
(replace 'check
(lambda _ (invoke "pytest" "-vv" "-k" "not test_f_string"))))))
(native-inputs
`(("python-pytest" ,python-pytest)))))
(define-public python-mccabe
(package
(name "python-mccabe")
@ -8183,39 +8162,6 @@ (define-public python-mccabe
(define-public python2-mccabe
(package-with-python2 python-mccabe))
(define-public python-mccabe-0.2.1
(package (inherit python-mccabe)
(version "0.2.1")
(source
(origin
(method url-fetch)
(uri (pypi-uri "mccabe" version))
(sha256
(base32
"0fi4a81kr5bcv5p4xgibqr595hyj5dafkqgsmfk96mfy8w71fajs"))))))
(define-public python2-mccabe-0.2.1
(package-with-python2 python-mccabe-0.2.1))
;; Flake8 2.4.1 requires an older version of pep8.
;; This should be removed ASAP.
(define-public python-pep8-1.5.7
(package (inherit python-pep8)
(version "1.5.7")
(source
(origin
(method url-fetch)
(uri (pypi-uri "pep8" version))
(sha256
(base32
"12b9bbdbwnspxgak14xg58c130x2n0blxzlms5jn2dszn8qj3d0m"))))
(arguments
;; XXX Tests not compatible with Python 3.5.
'(#:tests? #f))))
(define-public python2-pep8-1.5.7
(package-with-python2 python-pep8-1.5.7))
(define-public python-flake8
(package
(name "python-flake8")
@ -8262,40 +8208,6 @@ (define-public python2-flake8
("python2-typing" ,python2-typing)
,@(package-propagated-inputs base))))))
;; python-hacking requires flake8 <2.7.0.
(define-public python-flake8-2.6
(package
(inherit python-flake8)
(version "2.6.2")
(source (origin
(method url-fetch)
(uri (pypi-uri "flake8" version))
(sha256
(base32
"0y57hzal0j84dh9i1g1g6dc4aywvrnhy2fjmmbglpv5ajihxh713"))))
(arguments
`(#:phases
(modify-phases %standard-phases
(add-after 'unpack 'use-later-pycodestyles
(lambda __
(substitute* '("flake8.egg-info/requires.txt"
"setup.py")
(("pycodestyle >= 2.0, < 2.1")
"pycodestyle >= 2.0"))
#t))
(delete 'check)
(add-after 'install 'check
(lambda* (#:key inputs outputs #:allow-other-keys)
(add-installed-pythonpath inputs outputs)
(invoke "pytest" "-v")
#t)))))
(propagated-inputs
`(("python-pep8" ,python-pep8)
("python-pycodestyle" ,python-pycodestyle)
("python-entrypoints" ,python-entrypoints)
("python-pyflakes" ,python-pyflakes-1.2)
("python-mccabe" ,python-mccabe)))))
(define-public python-flake8-bugbear
(package
(name "python-flake8-bugbear")