Message ID | 727bc4f11c03e2406521ccf177f9fe19ef46d0ac.1684828094.git.ivan@selidor.net |
---|---|
State | New |
Headers | show |
Series | [bug#63657] gnu: python-py3status: Update to 3.50, compatible with Python 3.10. | expand |
Ivan Vilata i Balaguer (2023-05-23 09:49:29 +0200) wrote: > This avoids "ImportError: cannot import name 'Iterable' from 'collections'" > from py3status version < 3.25. > > * gnu/packages/python-xyz.scm (python-py3status): Update to 3.50. To add some context to this patch, the issue is with the main package program crashing with current Python 3.10 on execution (building doesn't fail): ``` $ guix shell -CW which procps python-py3status user@computer /tmp [env]$ guix describe guix 14c0380 repository URL: https://git.savannah.gnu.org/git/guix.git branch: master commit: 14c03807ba4bc81d42cf869f5b827f7da54ff843 user@computer /tmp [env]$ py3status Traceback (most recent call last): File "/gnu/store/73w4jp96ib943bzxc3g4wg1ja8xdg7ha-python-py3status-3.21/bin/.py3status-real", line 13, in <module> sys.exit(main()) File "/gnu/store/73w4jp96ib943bzxc3g4wg1ja8xdg7ha-python-py3status-3.21/lib/python3.10/site-packages/py3status/__init__.py", line 34, in main from py3status.core import Py3statusWrapper File "/gnu/store/73w4jp96ib943bzxc3g4wg1ja8xdg7ha-python-py3status-3.21/lib/python3.10/site-packages/py3status/core.py", line 22, in <module> from py3status.i3status import I3status File "/gnu/store/73w4jp96ib943bzxc3g4wg1ja8xdg7ha-python-py3status-3.21/lib/python3.10/site-packages/py3status/i3status.py", line 14, in <module> from py3status.py3 import Py3 File "/gnu/store/73w4jp96ib943bzxc3g4wg1ja8xdg7ha-python-py3status-3.21/lib/python3.10/site-packages/py3status/py3.py", line 19, in <module> from py3status.storage import Storage File "/gnu/store/73w4jp96ib943bzxc3g4wg1ja8xdg7ha-python-py3status-3.21/lib/python3.10/site-packages/py3status/storage.py", line 5, in <module> from collections import Iterable, Mapping ImportError: cannot import name 'Iterable' from 'collections' (/gnu/store/dy3xh053ahkhrp2jamggq8cpsyvp8mg0-python-3.10.7/lib/python3.10/collections/__init__.py) ``` Newer versions use `from collections.abc`. Cheers,
Ivan Vilata i Balaguer <ivan@selidor.net> writes: > [[PGP Signed Part:Good signature from 3DECC105F5DD2382 Ivan Vilata i Balaguer <ivan@selidor.net> (trust undefined) created at 2023-05-23T08:49:29+0100 using RSA]] > This avoids "ImportError: cannot import name 'Iterable' from 'collections'" > from py3status version < 3.25. > > * gnu/packages/python-xyz.scm (python-py3status): Update to 3.50. > --- > gnu/packages/python-xyz.scm | 5 +++-- > 1 file changed, 3 insertions(+), 2 deletions(-) This looks good to me, I've pushed to master as 3cc08bbdd960879e97ae5a9683ede3e630caf28e. Thanks, Chris
diff --git a/gnu/packages/python-xyz.scm b/gnu/packages/python-xyz.scm index f7e3f6f538..a2aed948d4 100644 --- a/gnu/packages/python-xyz.scm +++ b/gnu/packages/python-xyz.scm @@ -137,6 +137,7 @@ ;;; Copyright © 2023 Bruno Victal <mirai@makinata.eu> ;;; Copyright © 2023 Kaelyn Takata <kaelyn.alexi@protonmail.com> ;;; Copyright © 2023 Dominik Delgado Steuter <d@delgado.nrw> +;;; Copyright © 2023 Ivan Vilata-i-Balaguer <ivan@selidor.net> ;;; ;;; This file is part of GNU Guix. ;;; @@ -17785,13 +17786,13 @@ (define-public python-rope (define-public python-py3status (package (name "python-py3status") - (version "3.21") + (version "3.50") (source (origin (method url-fetch) (uri (pypi-uri "py3status" version)) (sha256 - (base32 "16z8zq83hxy48g6hh4xczbdz50qvxv9k1aahr4fqq7jis60cc262")))) + (base32 "0j2dx9lzpic15r8p0r0s3jmcskxpacahxl640b4864ldn5rlnh9d")))) (build-system python-build-system) (inputs (list file))