summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorRicardo Wurmus <rekado@elephly.net>2025-01-16 12:31:05 +0100
committerRicardo Wurmus <rekado@elephly.net>2025-01-20 21:37:59 +0100
commitd42e59c5750644a572eff6ebbf820e18345f45ac (patch)
tree1d9b6ce4141378d44d02ff509fa8fedff3e2e1cf
parent4de70c1a77c0a8c7e588319916ff256d9717e860 (diff)
gnu: python-internetarchive: Update to 5.1.0.
* gnu/packages/web.scm (python-internetarchive): Update to 5.1.0. [source]: Remove snippet. [build-system]: Use pyproject-build-system. [arguments]: Remove custom 'check phase; use test-flags. [propagated-inputs]: Add python-importlib-metadata and python-tqdm; update python-jsonpatch and python-schema. [native-inputs]: Add nss-certs-for-test, python-setuptools, and python-wheel. Change-Id: I8b5ea44e118ccb30b4e470957823a3f4dde89f43
-rw-r--r--gnu/packages/web.scm61
1 files changed, 24 insertions, 37 deletions
diff --git a/gnu/packages/web.scm b/gnu/packages/web.scm
index 701fa918764..b781c13b620 100644
--- a/gnu/packages/web.scm
+++ b/gnu/packages/web.scm
@@ -7160,7 +7160,7 @@ command-line arguments or read from stdin.")
(define-public python-internetarchive
(package
(name "python-internetarchive")
- (version "1.8.5")
+ (version "5.1.0")
(source
(origin
(method git-fetch)
@@ -7170,47 +7170,34 @@ command-line arguments or read from stdin.")
(file-name (git-file-name name version))
(sha256
(base32
- "0ih7hplv92wbv6cmgc1gs0v35qkajwicalwcq8vcljw30plr24fp"))
- (modules '((guix build utils)))
- (snippet
- '(begin
- ;; Python 3.7 removed `_pattern_type'.
- (for-each (lambda (file)
- (chmod file #o644)
- (substitute* file
- (("^import re\n" line)
- (string-append line "re._pattern_type = re.Pattern\n"))))
- (find-files "." "\\.py$"))
- ;; Mapping got moved to collections.abc
- (substitute* "internetarchive/utils.py"
- (("from collections import Mapping")
- "from collections.abc import Mapping"))))))
- (build-system python-build-system)
+ "186nx0dj0lgqrqkg9kzng5h0scbz3m6bk44vj83wzckr8yh3q08z"))))
+ (build-system pyproject-build-system)
(arguments
- `(#:phases
- (modify-phases %standard-phases
- (delete 'check)
- (add-after 'install 'check
- (lambda* (#:key inputs outputs #:allow-other-keys)
- (add-installed-pythonpath inputs outputs)
- (setenv "PATH" (string-append (assoc-ref outputs "out") "/bin"
- ":" (getenv "PATH")))
- (invoke "py.test" "-v" "-k"
- (string-append
- ;; These tests attempt to make a connection to
- ;; an external web service.
- "not test_get_item_with_kwargs"
- " and not test_ia")))))))
+ (list
+ #:test-flags
+ '(list "-k"
+ (string-append
+ ;; These tests need Internet access.
+ "not test_get_item_with_kwargs"
+ " and not test_upload"
+ " and not test_ia"))))
(propagated-inputs
- (list python-requests
- python-jsonpatch-0.4
- python-docopt
+ (list python-backports-csv
python-clint
+ python-docopt
+ python-importlib-metadata
+ python-jsonpatch
+ python-requests
python-six
- python-schema-0.5
- python-backports-csv))
+ python-schema
+ python-tqdm))
(native-inputs
- (list python-pytest python-pytest-capturelog python-responses))
+ (list nss-certs-for-test
+ python-pytest
+ python-pytest-capturelog
+ python-responses
+ python-setuptools
+ python-wheel))
(home-page "https://github.com/jjjake/internetarchive")
(synopsis "Command-line interface to archive.org")
(description "@code{ia} is a command-line tool for using