gnu: python-ipython: Update to 8.2.0 [fixes CVE-2022-21699].
* gnu/packages/python-xyz.scm (python-ipython): Update to 8.2.0. [phases]{fix-tests}: Delete phase. {check}: Remove extraneous add-installed-pythonpath call. Invoke Pytest directly. Reported-by: Leo Famulari <leo@famulari.name>master
parent
23d2319f9a
commit
1c8264d62e
|
@ -9101,13 +9101,13 @@ than the default.")
|
||||||
(define-public python-ipython
|
(define-public python-ipython
|
||||||
(package
|
(package
|
||||||
(name "python-ipython")
|
(name "python-ipython")
|
||||||
(version "7.27.0")
|
(version "8.2.0")
|
||||||
(source
|
(source
|
||||||
(origin
|
(origin
|
||||||
(method url-fetch)
|
(method url-fetch)
|
||||||
(uri (pypi-uri "ipython" version ".tar.gz"))
|
(uri (pypi-uri "ipython" version ".tar.gz"))
|
||||||
(sha256
|
(sha256
|
||||||
(base32 "04xgymypnbfgf2q0d5b0hanjbjsp53f055sh1p8xlq52vyzmxdaq"))))
|
(base32 "1hcxa713wh3axa57412iy02rj0494ljvv6gpnls4lndc5h9yprbh"))))
|
||||||
(build-system python-build-system)
|
(build-system python-build-system)
|
||||||
(arguments
|
(arguments
|
||||||
`(#:phases
|
`(#:phases
|
||||||
|
@ -9118,34 +9118,15 @@ than the default.")
|
||||||
((".*import datetime") "")
|
((".*import datetime") "")
|
||||||
((".*datetime.datetime.now\\(\\)") "")
|
((".*datetime.datetime.now\\(\\)") "")
|
||||||
(("%timeit") "# %timeit"))))
|
(("%timeit") "# %timeit"))))
|
||||||
(add-before 'check 'fix-tests
|
|
||||||
(lambda* (#:key inputs #:allow-other-keys)
|
|
||||||
(substitute* "./IPython/utils/_process_posix.py"
|
|
||||||
(("/usr/bin/env', 'which") (which "which")))
|
|
||||||
(substitute* "./IPython/core/tests/test_inputtransformer.py"
|
|
||||||
(("#!/usr/bin/env python")
|
|
||||||
(string-append "#!" (which "python"))))
|
|
||||||
;; This test introduces a circular dependency on ipykernel
|
|
||||||
;; (which depends on ipython).
|
|
||||||
(delete-file "IPython/core/tests/test_display.py")
|
|
||||||
;; AttributeError: module 'IPython.core' has no attribute 'formatters'
|
|
||||||
(delete-file "IPython/core/tests/test_interactiveshell.py")
|
|
||||||
;; AttributeError: module 'matplotlib_inline' has no
|
|
||||||
;; attribute 'backend_inline'
|
|
||||||
(delete-file "IPython/core/tests/test_pylabtools.py")))
|
|
||||||
(replace 'check
|
(replace 'check
|
||||||
(lambda* (#:key inputs outputs tests? #:allow-other-keys)
|
(lambda* (#:key inputs outputs tests? #:allow-other-keys)
|
||||||
(when tests?
|
(when tests?
|
||||||
;; Make installed package available for running the tests
|
(setenv "HOME" "/tmp/") ;required by some tests
|
||||||
(add-installed-pythonpath inputs outputs)
|
(invoke "python" "-m" "pytest" "-vv")))))))
|
||||||
(setenv "HOME" "/tmp/") ;; required by a test
|
|
||||||
;; We only test the core because one of the other tests
|
|
||||||
;; tries to import ipykernel.
|
|
||||||
(invoke "python" "IPython/testing/iptest.py"
|
|
||||||
"-v" "IPython/core/tests")))))))
|
|
||||||
(inputs (list readline which))
|
(inputs (list readline which))
|
||||||
(propagated-inputs
|
(propagated-inputs
|
||||||
(list python-backcall
|
(list python-backcall
|
||||||
|
python-decorator
|
||||||
python-jedi
|
python-jedi
|
||||||
python-jinja2
|
python-jinja2
|
||||||
python-jsonschema
|
python-jsonschema
|
||||||
|
@ -9157,18 +9138,20 @@ than the default.")
|
||||||
python-numpydoc
|
python-numpydoc
|
||||||
python-pexpect
|
python-pexpect
|
||||||
python-pickleshare
|
python-pickleshare
|
||||||
python-prompt-toolkit-2
|
python-prompt-toolkit
|
||||||
python-pygments
|
python-pygments
|
||||||
python-pyzmq
|
python-pyzmq
|
||||||
python-simplegeneric
|
python-simplegeneric
|
||||||
|
python-stack-data
|
||||||
python-terminado
|
python-terminado
|
||||||
python-traitlets))
|
python-traitlets))
|
||||||
(native-inputs
|
(native-inputs
|
||||||
(list graphviz
|
(list graphviz
|
||||||
pkg-config
|
pkg-config
|
||||||
python-requests ;for tests
|
;; For tests.
|
||||||
python-testpath
|
python-pytest
|
||||||
python-nose))
|
python-requests
|
||||||
|
python-testpath))
|
||||||
(home-page "https://ipython.org")
|
(home-page "https://ipython.org")
|
||||||
(synopsis "IPython is a tool for interactive computing in Python")
|
(synopsis "IPython is a tool for interactive computing in Python")
|
||||||
(description
|
(description
|
||||||
|
@ -9215,14 +9198,14 @@ computing.")
|
||||||
(mkdir-p info)
|
(mkdir-p info)
|
||||||
;; (copy-file "docs/build/texinfo/ipython.info"
|
;; (copy-file "docs/build/texinfo/ipython.info"
|
||||||
;; (string-append info "/ipython.info"))
|
;; (string-append info "/ipython.info"))
|
||||||
(copy-file "COPYING.rst" (string-append doc "/COPYING.rst")))
|
(copy-file "COPYING.rst" (string-append doc "/COPYING.rst"))))))))
|
||||||
#t)))))
|
|
||||||
(inputs
|
(inputs
|
||||||
(list python-ipython python-ipykernel))
|
(list python-ipython python-ipykernel))
|
||||||
(native-inputs
|
(native-inputs
|
||||||
`(("python-sphinx" ,python-sphinx)
|
`(("python-sphinx" ,python-sphinx)
|
||||||
("python-sphinx-rtd-theme" ,python-sphinx-rtd-theme)
|
("python-sphinx-rtd-theme" ,python-sphinx-rtd-theme)
|
||||||
;; FIXME: It's possible that a smaller union would work just as well.
|
;; FIXME: It's possible that a smaller updmap.cfg would work just as
|
||||||
|
;; well.
|
||||||
("texlive" ,(texlive-updmap.cfg (list texlive-amsfonts
|
("texlive" ,(texlive-updmap.cfg (list texlive-amsfonts
|
||||||
texlive-capt-of
|
texlive-capt-of
|
||||||
texlive-fonts-ec
|
texlive-fonts-ec
|
||||||
|
|
Reference in New Issue