summaryrefslogtreecommitdiff
path: root/gnu/packages/python-web.scm
diff options
context:
space:
mode:
authorMorgan Smith <Morgan.J.Smith@outlook.com>2021-12-28 16:37:07 -0500
committerNicolas Goaziou <mail@nicolasgoaziou.fr>2021-12-30 00:15:56 +0100
commitdded2d2b454c180c0d3d0cff43af70e99508264f (patch)
tree8194aeb766199087f8c813c8ebb4a262072d222a /gnu/packages/python-web.scm
parent016fcb3f3e94061e1b7c53a14efe7b11f0362da8 (diff)
downloadguix-patches-dded2d2b454c180c0d3d0cff43af70e99508264f.tar
guix-patches-dded2d2b454c180c0d3d0cff43af70e99508264f.tar.gz
gnu: python-cssselect2: Fix build.
* gnu/packages/python-web.scm (python-cssselect2): [phases]: Add disable-linters phase. Make check phase respect #:tests?. [native-inputs]: Remove python-pytest-flake8 and python-pytest-isort. Signed-off-by: Nicolas Goaziou <mail@nicolasgoaziou.fr>
Diffstat (limited to 'gnu/packages/python-web.scm')
-rw-r--r--gnu/packages/python-web.scm15
1 files changed, 12 insertions, 3 deletions
diff --git a/gnu/packages/python-web.scm b/gnu/packages/python-web.scm
index 61a34bfc63..f424c6a103 100644
--- a/gnu/packages/python-web.scm
+++ b/gnu/packages/python-web.scm
@@ -4582,13 +4582,22 @@ in various CSS modules.")
(arguments
`(#:phases
(modify-phases %standard-phases
+ (add-after 'unpack 'disable-linters
+ ;; Their check fails; none of our business.
+ (lambda _
+ (substitute* '("setup.py" "pyproject.toml")
+ (("'pytest-flake8',") "")
+ (("'pytest-isort',") "")
+ (("--flake8") "")
+ (("--isort") ""))))
(replace 'check
- (lambda _ (invoke "pytest"))))))
+ (lambda* (#:key tests? #:allow-other-keys)
+ (when tests?
+ (lambda _ (invoke "pytest"))))))))
(propagated-inputs
(list python-tinycss2))
(native-inputs
- (list python-pytest-cov python-pytest-flake8 python-pytest-isort
- python-pytest-runner))
+ (list python-pytest-cov python-pytest-runner))
(home-page "https://cssselect2.readthedocs.io/")
(synopsis "CSS selectors for Python ElementTree")
(description "@code{cssselect2} is a straightforward implementation of