summaryrefslogtreecommitdiff
path: root/gnu/packages/python-web.scm
diff options
context:
space:
mode:
authorLeo Prikler <leo.prikler@student.tugraz.at>2020-11-17 13:02:07 +0100
committerLeo Prikler <leo.prikler@student.tugraz.at>2020-12-29 13:54:49 +0100
commite5c258b65a3051b0962b2cff74b011b731efac83 (patch)
treed72352dee5893ad2f6e4d198c6ce252571b784f1 /gnu/packages/python-web.scm
parent142f8713ab647ecb8833dcf9eb98e3bdc62cd44a (diff)
downloadguix-patches-e5c258b65a3051b0962b2cff74b011b731efac83.tar
guix-patches-e5c258b65a3051b0962b2cff74b011b731efac83.tar.gz
gnu: python-cloudscraper: Drop interpreters at build time.
* gnu/packages/python-web.scm (python-cloudscraper)[snippet]: Keep interpreters. [arguments]<#:phases>: Add drop-unsupported-sources.
Diffstat (limited to 'gnu/packages/python-web.scm')
-rw-r--r--gnu/packages/python-web.scm16
1 files changed, 13 insertions, 3 deletions
diff --git a/gnu/packages/python-web.scm b/gnu/packages/python-web.scm
index c1de8197e0..622f5fc6e2 100644
--- a/gnu/packages/python-web.scm
+++ b/gnu/packages/python-web.scm
@@ -5597,15 +5597,25 @@ Encoding for HTTP.")
'("captcha/2captcha.py"
"captcha/9kw.py"
"captcha/anticaptcha.py"
- "captcha/deathbycaptcha.py"
- "interpreters/js2py.py"
- "interpreters/v8.py"))
+ "captcha/deathbycaptcha.py"))
(substitute* "__init__.py"
;; Perhaps it's a joke, but don't promote proprietary software.
(("([Th]is feature is not available) in the .*'" _ prefix)
(string-append prefix ".'")))
#t))))
(build-system python-build-system)
+ (arguments
+ `(#:phases
+ (modify-phases %standard-phases
+ ;; XXX: Dependencies, that have not yet been packaged
+ ;; and cause an import error when included.
+ (add-after 'unpack 'drop-unsupported-sources
+ (lambda _
+ (with-directory-excursion "cloudscraper"
+ (for-each delete-file
+ '("interpreters/js2py.py"
+ "interpreters/v8.py")))
+ #t)))))
(propagated-inputs
`(("python-requests" ,python-requests)
("python-requests-toolbelt" ,python-requests-toolbelt-0.9.1)