unofficial mirror of guix-patches@gnu.org 
 help / color / Atom feed
* [bug#41395] [PATCH 0/2] gnu: Add python-questionary
@ 2020-05-19  9:53 Edouard Klein
  2020-05-19  9:58 ` [bug#41395] [PATCH 1/2] gnu: python-prompt-toolkit: Update to 3.0.5 Edouard Klein
                   ` (13 more replies)
  0 siblings, 14 replies; 34+ messages in thread
From: Edouard Klein @ 2020-05-19  9:53 UTC (permalink / raw)
  To: 41395

Hi all,

This is my first time submitting a multicommit patch. Please do not
hesitate to point out any mistakes in the way I did it so that I can fix
them in the future.

These two patches are my attempt to add python-questionary, which
depends on a update to python-prompt-toolkit.

With many thanks to Julien Lepiller and zimoun for their help on
guix-devel :)

Cheers,

Edouard.




^ permalink raw reply	[flat|nested] 34+ messages in thread

* [bug#41395] [PATCH 1/2] gnu: python-prompt-toolkit: Update to 3.0.5
  2020-05-19  9:53 [bug#41395] [PATCH 0/2] gnu: Add python-questionary Edouard Klein
@ 2020-05-19  9:58 ` Edouard Klein
  2020-05-23 18:35   ` Marius Bakke
  2020-05-19  9:59 ` [bug#41395] [PATCH 2/2] gnu: Add python-questionary Edouard Klein
                   ` (12 subsequent siblings)
  13 siblings, 1 reply; 34+ messages in thread
From: Edouard Klein @ 2020-05-19  9:58 UTC (permalink / raw)
  To: 41395

* /gnu/packages/python-xyz.scm (python-widgetsnbextension): Pin python-prompt-toolkit to version 2
* /gnu/packages/python-xyz.scm (python-ipywidgets): Pin python-prompt-toolkit to version 2
* /gnu/packages/python-xyz.scm (python-jupyter-console): Pin python-prompt-toolkit to version 2
* /gnu/packages/python-xyz.scm (python-prompt-toolkit): Update to 3.0.5
* /gnu/packages/python-xyz.scm (python-prompt-toolkit-2): New variable
* /gnu/packages/python-xyz.scm (python-prompt-toolkit-2-instead-of-prompt-toolkit): New variable
* /gnu/packages/machine-learning.scm (python-iml): Pin ipython to python-prompt-toolkit-2 variant
---
 gnu/packages/machine-learning.scm |  9 ++++--
 gnu/packages/python-xyz.scm       | 48 +++++++++++++++++++++++++++++--
 2 files changed, 52 insertions(+), 5 deletions(-)

diff --git a/gnu/packages/machine-learning.scm b/gnu/packages/machine-learning.scm
index 6552d171bf..5553b31bb5 100644
--- a/gnu/packages/machine-learning.scm
+++ b/gnu/packages/machine-learning.scm
@@ -14,6 +14,7 @@
 ;;; Copyright © 2019 Guillaume Le Vaillant <glv@posteo.net>
 ;;; Copyright © 2019 Brett Gilio <brettg@gnu.org>
 ;;; Copyright © 2020 Konrad Hinsen <konrad.hinsen@fastmail.net>
+;;; Copyright © 2020 Edouard Klein <edk@beaver-labs.com>
 ;;;
 ;;; This file is part of GNU Guix.
 ;;;
@@ -1803,12 +1804,14 @@ advanced research.")
          "1k8szlpm19rcwcxdny9qdm3gmaqq8akb4xlvrzyz8c2d679aak6l"))))
     (build-system python-build-system)
     (propagated-inputs
-     `(("ipython" ,python-ipython)
-       ("nose" ,python-nose)
+     `(("ipython" ,(prompt-toolkit-2-instead-of-prompt-toolkit
+                    python-ipython))
        ("numpy" ,python-numpy)
        ("pandas" ,python-pandas)
        ("scipy" ,python-scipy)))
-    (home-page "http://github.com/interpretable-ml/iml")
+    (native-inputs
+     `(("nose" ,python-nose)))
+    (home-page "https://github.com/interpretable-ml/iml")
     (synopsis "Interpretable Machine Learning (iML) package")
     (description "Interpretable ML (iML) is a set of data type objects,
 visualizations, and interfaces that can be used by any method designed to
diff --git a/gnu/packages/python-xyz.scm b/gnu/packages/python-xyz.scm
index b8a51570c3..5fd7e274e9 100644
--- a/gnu/packages/python-xyz.scm
+++ b/gnu/packages/python-xyz.scm
@@ -8922,6 +8922,7 @@ interactive computing.")
     (build-system python-build-system)
     (propagated-inputs
      `(("python-ipykernel" ,python-ipykernel)
+       ("python-prompt-toolkit" ,python-prompt-toolkit-2)
        ("python-notebook" ,python-notebook)))
     (native-inputs
      `(("python-certifi" ,python-certifi)
@@ -8950,6 +8951,7 @@ notebooks.")
     (propagated-inputs
      `(("python-ipython" ,python-ipython)
        ("python-traitlets" ,python-traitlets)
+       ("python-prompt-toolkit" ,python-prompt-toolkit-2)
        ("python-widgetsnbextension" ,python-widgetsnbextension)))
     (native-inputs
      `(("python-nose" ,python-nose)
@@ -8980,7 +8982,7 @@ in the data.")
     (propagated-inputs
      `(("python-ipykernel" ,python-ipykernel)
        ("python-jupyter-client" ,python-jupyter-client)
-       ("python-prompt-toolkit" ,python-prompt-toolkit)
+       ("python-prompt-toolkit" ,python-prompt-toolkit-2)
        ("python-pygments" ,python-pygments)))
     (native-inputs
      `(("python-nose" ,python-nose)))
@@ -12049,6 +12051,44 @@ collections of data.")
   (package-with-python2 python-backpack))
 
 (define-public python-prompt-toolkit
+  (package
+    (name "python-prompt-toolkit")
+    (version "3.0.5")
+    (source
+     (origin
+       (method url-fetch)
+       (uri (pypi-uri "prompt_toolkit" version))
+       (sha256
+        (base32
+         "1j3x5s4gp4ih73sbcni0a0vffbzvrxbrbnkvb3fzjgxn810ilgan"))))
+    (build-system python-build-system)
+    (arguments
+     `(#:phases
+       (modify-phases %standard-phases
+         (delete 'check)
+         (add-after 'install 'post-install-check
+           (lambda* (#:key inputs outputs #:allow-other-keys)
+             ;; HOME is needed for the test
+             ;; "test_pathcompleter_can_expanduser".
+             (setenv "HOME" "/tmp")
+             (add-installed-pythonpath inputs outputs)
+             (invoke "py.test"))))))
+    (propagated-inputs
+     `(("python-wcwidth" ,python-wcwidth)))
+    (native-inputs
+     `(("python-pytest" ,python-pytest)))
+    (home-page
+     "https://github.com/prompt-toolkit/python-prompt-toolkit")
+    (synopsis "Library for building command line interfaces in Python")
+    (description
+     "Prompt-Toolkit is a library for building interactive command line
+interfaces in Python.  It's like GNU Readline but it also features syntax
+highlighting while typing, out-of-the-box multi-line input editing, advanced
+code completion, incremental search, support for Chinese double-width
+characters, mouse support, and auto suggestions.")
+    (license license:bsd-3)))
+
+(define-public python-prompt-toolkit-2
   (package
     (name "python-prompt-toolkit")
     (version "2.0.7")
@@ -12077,7 +12117,7 @@ collections of data.")
        ("python-pygments" ,python-pygments)))
     (native-inputs
      `(("python-pytest" ,python-pytest)))
-    (home-page "https://github.com/jonathanslenders/python-prompt-toolkit")
+    (home-page "https://github.com/prompt-toolkit/python-prompt-toolkit")
     (synopsis "Library for building command line interfaces in Python")
     (description
      "Prompt-Toolkit is a library for building interactive command line
@@ -12104,6 +12144,10 @@ characters, mouse support, and auto suggestions.")
 (define-public python2-prompt-toolkit-1
   (package-with-python2 python-prompt-toolkit-1))
 
+(define-public prompt-toolkit-2-instead-of-prompt-toolkit
+  (package-input-rewriting/spec
+   `(("python-prompt-toolkit" . ,(const python-prompt-toolkit-2)))))
+
 (define-public python-jedi
   (package
     (name "python-jedi")
-- 
2.26.2




^ permalink raw reply	[flat|nested] 34+ messages in thread

* [bug#41395] [PATCH 2/2] gnu: Add python-questionary
  2020-05-19  9:53 [bug#41395] [PATCH 0/2] gnu: Add python-questionary Edouard Klein
  2020-05-19  9:58 ` [bug#41395] [PATCH 1/2] gnu: python-prompt-toolkit: Update to 3.0.5 Edouard Klein
@ 2020-05-19  9:59 ` Edouard Klein
  2020-05-23 18:39   ` Marius Bakke
  2020-05-25 11:24 ` [bug#41395] [PATCH 1/4] gnu: Update python-iml homepage to https Edouard Klein
                   ` (11 subsequent siblings)
  13 siblings, 1 reply; 34+ messages in thread
From: Edouard Klein @ 2020-05-19  9:59 UTC (permalink / raw)
  To: 41395

* /gnu/packages/python-xyz.scm (python-questionary): New variable
* /gnu/packages/python-check.scm (python-pytest-pycodestyle): New variable
---
 gnu/packages/python-check.scm | 25 +++++++++++++++++++++++++
 gnu/packages/python-xyz.scm   | 34 ++++++++++++++++++++++++++++++++++
 2 files changed, 59 insertions(+)

diff --git a/gnu/packages/python-check.scm b/gnu/packages/python-check.scm
index 22b9ea8df5..50911673b2 100644
--- a/gnu/packages/python-check.scm
+++ b/gnu/packages/python-check.scm
@@ -337,6 +337,31 @@ testing framework.")
 framework.")
     (license license:expat)))
 
+(define-public python-pytest-pycodestyle
+  (package
+    (name "python-pytest-pycodestyle")
+    (version "2.0.0")  ;; Any version higher than that requires python-pytest~=5.4
+    ;; (python-pytest is at version 5.3.5 as I write this comment
+    ;; and 5478 packages depend on it.)
+    (source
+     (origin
+       (method url-fetch)
+       (uri (pypi-uri "pytest-pycodestyle" version))
+       (sha256
+        (base32
+         "02i5gl7pm9cwxk15sn29inz3n8flpj1r3p1l110h43f2na5w8h7z"))))
+    (build-system python-build-system)
+    (propagated-inputs
+     `(("python-pycodestyle" ,python-pycodestyle)))
+    (native-inputs
+     `(("python-pytest" ,python-pytest)))
+    (home-page
+     "https://github.com/henry0312/pytest-pycodestyle")
+    (synopsis "Pytest plugin to run pycodestyle")
+    (description "This package provides a plugin to run pycodestyle for the py.test
+framework.")
+    (license license:expat)))
+
 (define-public python-codacy-coverage
   (package
     (name "python-codacy-coverage")
diff --git a/gnu/packages/python-xyz.scm b/gnu/packages/python-xyz.scm
index 5fd7e274e9..26a737febb 100644
--- a/gnu/packages/python-xyz.scm
+++ b/gnu/packages/python-xyz.scm
@@ -19985,3 +19985,37 @@ allows you, from Python code, to “fix” invalid (X)HTML markup.")
 It builds upon tmux's target and formats to create an object mapping to traverse,
  inspect and interact with live tmux sessions.")
     (license license:expat)))
+
+(define-public python-questionary
+  (package
+   (name "python-questionary")
+   (version "1.5.2")
+   (source
+    (origin
+     (method url-fetch)
+     (uri (pypi-uri "questionary" version))
+     (sha256
+      (base32
+       "09n737qmvzbibl8hmbd5zfg1502fd9n0r8qjzz1y0vy8nqv1xr7n"))))
+   (build-system python-build-system)
+   (propagated-inputs
+    `(("python-prompt-toolkit" ,python-prompt-toolkit)))
+   (native-inputs
+    `(("python-coveralls" ,python-coveralls)
+      ("python-pytest-cov" ,python-pytest-cov)
+      ("python-pytest-pycodestyle"
+       ,python-pytest-pycodestyle)
+      ))
+   (arguments
+    `(#:phases
+      (modify-phases %standard-phases
+        (replace 'check
+          (lambda _
+            (invoke "py.test"))))))
+   (home-page "https://github.com/tmbo/questionary")
+   (synopsis
+    "Pretty command line user prompts")
+   (description
+    "Questionary helps make the input prompts easy to read and answer for the user
+using multi-select lists, confirmations, free text prompts, completion, etc.")
+  (license license:expat)))
-- 
2.26.2




^ permalink raw reply	[flat|nested] 34+ messages in thread

* [bug#41395] [PATCH 1/2] gnu: python-prompt-toolkit: Update to 3.0.5
  2020-05-19  9:58 ` [bug#41395] [PATCH 1/2] gnu: python-prompt-toolkit: Update to 3.0.5 Edouard Klein
@ 2020-05-23 18:35   ` Marius Bakke
  2020-05-25 10:52     ` Edouard Klein
  0 siblings, 1 reply; 34+ messages in thread
From: Marius Bakke @ 2020-05-23 18:35 UTC (permalink / raw)
  To: Edouard Klein, 41395

[-- Attachment #1: Type: text/plain, Size: 6072 bytes --]

Edouard Klein <edk@beaver-labs.com> writes:

> * /gnu/packages/python-xyz.scm (python-widgetsnbextension): Pin python-prompt-toolkit to version 2
> * /gnu/packages/python-xyz.scm (python-ipywidgets): Pin python-prompt-toolkit to version 2
> * /gnu/packages/python-xyz.scm (python-jupyter-console): Pin python-prompt-toolkit to version 2
> * /gnu/packages/python-xyz.scm (python-prompt-toolkit): Update to 3.0.5
> * /gnu/packages/python-xyz.scm (python-prompt-toolkit-2): New variable
> * /gnu/packages/python-xyz.scm (python-prompt-toolkit-2-instead-of-prompt-toolkit): New variable
> * /gnu/packages/machine-learning.scm (python-iml): Pin ipython to python-prompt-toolkit-2 variant

You only need to mention the file name once.

> @@ -1803,12 +1804,14 @@ advanced research.")
>           "1k8szlpm19rcwcxdny9qdm3gmaqq8akb4xlvrzyz8c2d679aak6l"))))
>      (build-system python-build-system)
>      (propagated-inputs
> -     `(("ipython" ,python-ipython)
> -       ("nose" ,python-nose)
> +     `(("ipython" ,(prompt-toolkit-2-instead-of-prompt-toolkit
> +                    python-ipython))
>         ("numpy" ,python-numpy)
>         ("pandas" ,python-pandas)
>         ("scipy" ,python-scipy)))
> -    (home-page "http://github.com/interpretable-ml/iml")
> +    (native-inputs
> +     `(("nose" ,python-nose)))
> +    (home-page "https://github.com/interpretable-ml/iml")

Can you submit the home page and inputs change of this package as two
separate patches?

>      (synopsis "Interpretable Machine Learning (iML) package")
>      (description "Interpretable ML (iML) is a set of data type objects,
>  visualizations, and interfaces that can be used by any method designed to
> diff --git a/gnu/packages/python-xyz.scm b/gnu/packages/python-xyz.scm
> index b8a51570c3..5fd7e274e9 100644
> --- a/gnu/packages/python-xyz.scm
> +++ b/gnu/packages/python-xyz.scm
> @@ -8922,6 +8922,7 @@ interactive computing.")
>      (build-system python-build-system)
>      (propagated-inputs
>       `(("python-ipykernel" ,python-ipykernel)
> +       ("python-prompt-toolkit" ,python-prompt-toolkit-2)
>         ("python-notebook" ,python-notebook)))
>      (native-inputs
>       `(("python-certifi" ,python-certifi)
> @@ -8950,6 +8951,7 @@ notebooks.")
>      (propagated-inputs
>       `(("python-ipython" ,python-ipython)
>         ("python-traitlets" ,python-traitlets)
> +       ("python-prompt-toolkit" ,python-prompt-toolkit-2)
>         ("python-widgetsnbextension" ,python-widgetsnbextension)))
>      (native-inputs
>       `(("python-nose" ,python-nose)
> @@ -8980,7 +8982,7 @@ in the data.")
>      (propagated-inputs
>       `(("python-ipykernel" ,python-ipykernel)
>         ("python-jupyter-client" ,python-jupyter-client)
> -       ("python-prompt-toolkit" ,python-prompt-toolkit)
> +       ("python-prompt-toolkit" ,python-prompt-toolkit-2)
>         ("python-pygments" ,python-pygments)))
>      (native-inputs
>       `(("python-nose" ,python-nose)))
> @@ -12049,6 +12051,44 @@ collections of data.")
>    (package-with-python2 python-backpack))

It would be great to update these packages instead of pinning to the old
version.  I won't blame you if you don't feel like embarking on that
journey though.

>  (define-public python-prompt-toolkit
> +  (package
> +    (name "python-prompt-toolkit")
> +    (version "3.0.5")
> +    (source
> +     (origin
> +       (method url-fetch)
> +       (uri (pypi-uri "prompt_toolkit" version))
> +       (sha256
> +        (base32
> +         "1j3x5s4gp4ih73sbcni0a0vffbzvrxbrbnkvb3fzjgxn810ilgan"))))
> +    (build-system python-build-system)
> +    (arguments
> +     `(#:phases
> +       (modify-phases %standard-phases
> +         (delete 'check)
> +         (add-after 'install 'post-install-check
> +           (lambda* (#:key inputs outputs #:allow-other-keys)
> +             ;; HOME is needed for the test
> +             ;; "test_pathcompleter_can_expanduser".
> +             (setenv "HOME" "/tmp")
> +             (add-installed-pythonpath inputs outputs)
> +             (invoke "py.test"))))))
> +    (propagated-inputs
> +     `(("python-wcwidth" ,python-wcwidth)))
> +    (native-inputs
> +     `(("python-pytest" ,python-pytest)))
> +    (home-page
> +     "https://github.com/prompt-toolkit/python-prompt-toolkit")
> +    (synopsis "Library for building command line interfaces in Python")
> +    (description
> +     "Prompt-Toolkit is a library for building interactive command line
> +interfaces in Python.  It's like GNU Readline but it also features syntax
> +highlighting while typing, out-of-the-box multi-line input editing, advanced
> +code completion, incremental search, support for Chinese double-width
> +characters, mouse support, and auto suggestions.")
> +    (license license:bsd-3)))

Can you make python-prompt-toolkit-2 inherit from this package to avoid
duplicating the entire expression?

> +(define-public python-prompt-toolkit-2
>    (package
>      (name "python-prompt-toolkit")
>      (version "2.0.7")
> @@ -12077,7 +12117,7 @@ collections of data.")
>         ("python-pygments" ,python-pygments)))
>      (native-inputs
>       `(("python-pytest" ,python-pytest)))
> -    (home-page "https://github.com/jonathanslenders/python-prompt-toolkit")
> +    (home-page "https://github.com/prompt-toolkit/python-prompt-toolkit")
>      (synopsis "Library for building command line interfaces in Python")
>      (description
>       "Prompt-Toolkit is a library for building interactive command line
> @@ -12104,6 +12144,10 @@ characters, mouse support, and auto suggestions.")
>  (define-public python2-prompt-toolkit-1
>    (package-with-python2 python-prompt-toolkit-1))
>  
> +(define-public prompt-toolkit-2-instead-of-prompt-toolkit
> +  (package-input-rewriting/spec
> +   `(("python-prompt-toolkit" . ,(const python-prompt-toolkit-2)))))

Is this actually necessary?  Just changing the inputs as you did above
should be sufficient I think.

[-- Attachment #2: signature.asc --]
[-- Type: application/pgp-signature, Size: 487 bytes --]

^ permalink raw reply	[flat|nested] 34+ messages in thread

* [bug#41395] [PATCH 2/2] gnu: Add python-questionary
  2020-05-19  9:59 ` [bug#41395] [PATCH 2/2] gnu: Add python-questionary Edouard Klein
@ 2020-05-23 18:39   ` Marius Bakke
  2020-05-25 11:23     ` Edouard Klein
  0 siblings, 1 reply; 34+ messages in thread
From: Marius Bakke @ 2020-05-23 18:39 UTC (permalink / raw)
  To: Edouard Klein, 41395

[-- Attachment #1: Type: text/plain, Size: 1779 bytes --]

Edouard Klein <edk@beaver-labs.com> writes:

> * /gnu/packages/python-xyz.scm (python-questionary): New variable
> * /gnu/packages/python-check.scm (python-pytest-pycodestyle): New variable

Can you submit these packages as two separate patches?

[...]

> +(define-public python-pytest-pycodestyle
> +  (package
> +    (name "python-pytest-pycodestyle")
> +    (version "2.0.0")  ;; Any version higher than that requires python-pytest~=5.4
> +    ;; (python-pytest is at version 5.3.5 as I write this comment
> +    ;; and 5478 packages depend on it.)

You can create a 'python-pytest-5.4' variable instead of sticking to
this old version, we'll probably need it sooner or later.  No strong
opinion though.

[...]

> +(define-public python-questionary
> +  (package
> +   (name "python-questionary")
> +   (version "1.5.2")
> +   (source
> +    (origin
> +     (method url-fetch)
> +     (uri (pypi-uri "questionary" version))
> +     (sha256
> +      (base32
> +       "09n737qmvzbibl8hmbd5zfg1502fd9n0r8qjzz1y0vy8nqv1xr7n"))))
> +   (build-system python-build-system)
> +   (propagated-inputs
> +    `(("python-prompt-toolkit" ,python-prompt-toolkit)))
> +   (native-inputs
> +    `(("python-coveralls" ,python-coveralls)
> +      ("python-pytest-cov" ,python-pytest-cov)
> +      ("python-pytest-pycodestyle"
> +       ,python-pytest-pycodestyle)
> +      ))

These parens feel lonely.  :-)

> +   (arguments
> +    `(#:phases
> +      (modify-phases %standard-phases
> +        (replace 'check
> +          (lambda _
> +            (invoke "py.test"))))))
> +   (home-page "https://github.com/tmbo/questionary")
> +   (synopsis
> +    "Pretty command line user prompts")

The line break here is not necessary.

LGTM with these changes, can you send updated patches?

Thanks!

[-- Attachment #2: signature.asc --]
[-- Type: application/pgp-signature, Size: 487 bytes --]

^ permalink raw reply	[flat|nested] 34+ messages in thread

* [bug#41395] [PATCH 1/2] gnu: python-prompt-toolkit: Update to 3.0.5
  2020-05-23 18:35   ` Marius Bakke
@ 2020-05-25 10:52     ` Edouard Klein
  2020-05-25 22:21       ` Marius Bakke
  0 siblings, 1 reply; 34+ messages in thread
From: Edouard Klein @ 2020-05-25 10:52 UTC (permalink / raw)
  To: 41395

Thank you for your comments :)

Marius Bakke writes:

> Edouard Klein <edk@beaver-labs.com> writes:
>
>> * /gnu/packages/python-xyz.scm (python-widgetsnbextension): Pin python-prompt-toolkit to version 2
>> * /gnu/packages/python-xyz.scm (python-ipywidgets): Pin python-prompt-toolkit to version 2
>> * /gnu/packages/python-xyz.scm (python-jupyter-console): Pin python-prompt-toolkit to version 2
>> * /gnu/packages/python-xyz.scm (python-prompt-toolkit): Update to 3.0.5
>> * /gnu/packages/python-xyz.scm (python-prompt-toolkit-2): New variable
>> * /gnu/packages/python-xyz.scm (python-prompt-toolkit-2-instead-of-prompt-toolkit): New variable
>> * /gnu/packages/machine-learning.scm (python-iml): Pin ipython to python-prompt-toolkit-2 variant
>
> You only need to mention the file name once.

OK :)

>
>> @@ -1803,12 +1804,14 @@ advanced research.")
>>           "1k8szlpm19rcwcxdny9qdm3gmaqq8akb4xlvrzyz8c2d679aak6l"))))
>>      (build-system python-build-system)
>>      (propagated-inputs
>> -     `(("ipython" ,python-ipython)
>> -       ("nose" ,python-nose)
>> +     `(("ipython" ,(prompt-toolkit-2-instead-of-prompt-toolkit
>> +                    python-ipython))
>>         ("numpy" ,python-numpy)
>>         ("pandas" ,python-pandas)
>>         ("scipy" ,python-scipy)))
>> -    (home-page "http://github.com/interpretable-ml/iml")
>> +    (native-inputs
>> +     `(("nose" ,python-nose)))
>> +    (home-page "https://github.com/interpretable-ml/iml")
>
> Can you submit the home page and inputs change of this package as two
> separate patches?
>

Done

>>      (synopsis "Interpretable Machine Learning (iML) package")
>>      (description "Interpretable ML (iML) is a set of data type objects,
>>  visualizations, and interfaces that can be used by any method designed to
>> diff --git a/gnu/packages/python-xyz.scm b/gnu/packages/python-xyz.scm
>> index b8a51570c3..5fd7e274e9 100644
>> --- a/gnu/packages/python-xyz.scm
>> +++ b/gnu/packages/python-xyz.scm
>> @@ -8922,6 +8922,7 @@ interactive computing.")
>>      (build-system python-build-system)
>>      (propagated-inputs
>>       `(("python-ipykernel" ,python-ipykernel)
>> +       ("python-prompt-toolkit" ,python-prompt-toolkit-2)
>>         ("python-notebook" ,python-notebook)))
>>      (native-inputs
>>       `(("python-certifi" ,python-certifi)
>> @@ -8950,6 +8951,7 @@ notebooks.")
>>      (propagated-inputs
>>       `(("python-ipython" ,python-ipython)
>>         ("python-traitlets" ,python-traitlets)
>> +       ("python-prompt-toolkit" ,python-prompt-toolkit-2)
>>         ("python-widgetsnbextension" ,python-widgetsnbextension)))
>>      (native-inputs
>>       `(("python-nose" ,python-nose)
>> @@ -8980,7 +8982,7 @@ in the data.")
>>      (propagated-inputs
>>       `(("python-ipykernel" ,python-ipykernel)
>>         ("python-jupyter-client" ,python-jupyter-client)
>> -       ("python-prompt-toolkit" ,python-prompt-toolkit)
>> +       ("python-prompt-toolkit" ,python-prompt-toolkit-2)
>>         ("python-pygments" ,python-pygments)))
>>      (native-inputs
>>       `(("python-nose" ,python-nose)))
>> @@ -12049,6 +12051,44 @@ collections of data.")
>>    (package-with-python2 python-backpack))
>
> It would be great to update these packages instead of pinning to the old
> version.  I won't blame you if you don't feel like embarking on that
> journey though.
>

In the new patches I'm about to send, I updated them. Alas even their
latest versions still require python-prompt-toolkit <=2.1, so I had to
pin the dependencies. I did it in a cleaner way, though.


>>  (define-public python-prompt-toolkit
>> +  (package
>> +    (name "python-prompt-toolkit")
>> +    (version "3.0.5")
>> +    (source
>> +     (origin
>> +       (method url-fetch)
>> +       (uri (pypi-uri "prompt_toolkit" version))
>> +       (sha256
>> +        (base32
>> +         "1j3x5s4gp4ih73sbcni0a0vffbzvrxbrbnkvb3fzjgxn810ilgan"))))
>> +    (build-system python-build-system)
>> +    (arguments
>> +     `(#:phases
>> +       (modify-phases %standard-phases
>> +         (delete 'check)
>> +         (add-after 'install 'post-install-check
>> +           (lambda* (#:key inputs outputs #:allow-other-keys)
>> +             ;; HOME is needed for the test
>> +             ;; "test_pathcompleter_can_expanduser".
>> +             (setenv "HOME" "/tmp")
>> +             (add-installed-pythonpath inputs outputs)
>> +             (invoke "py.test"))))))
>> +    (propagated-inputs
>> +     `(("python-wcwidth" ,python-wcwidth)))
>> +    (native-inputs
>> +     `(("python-pytest" ,python-pytest)))
>> +    (home-page
>> +     "https://github.com/prompt-toolkit/python-prompt-toolkit")
>> +    (synopsis "Library for building command line interfaces in Python")
>> +    (description
>> +     "Prompt-Toolkit is a library for building interactive command line
>> +interfaces in Python.  It's like GNU Readline but it also features syntax
>> +highlighting while typing, out-of-the-box multi-line input editing, advanced
>> +code completion, incremental search, support for Chinese double-width
>> +characters, mouse support, and auto suggestions.")
>> +    (license license:bsd-3)))
>
> Can you make python-prompt-toolkit-2 inherit from this package to avoid
> duplicating the entire expression?
>
Done

>> +(define-public python-prompt-toolkit-2
>>    (package
>>      (name "python-prompt-toolkit")
>>      (version "2.0.7")
>> @@ -12077,7 +12117,7 @@ collections of data.")
>>         ("python-pygments" ,python-pygments)))
>>      (native-inputs
>>       `(("python-pytest" ,python-pytest)))
>> -    (home-page "https://github.com/jonathanslenders/python-prompt-toolkit")
>> +    (home-page "https://github.com/prompt-toolkit/python-prompt-toolkit")
>>      (synopsis "Library for building command line interfaces in Python")
>>      (description
>>       "Prompt-Toolkit is a library for building interactive command line
>> @@ -12104,6 +12144,10 @@ characters, mouse support, and auto suggestions.")
>>  (define-public python2-prompt-toolkit-1
>>    (package-with-python2 python-prompt-toolkit-1))
>>  
>> +(define-public prompt-toolkit-2-instead-of-prompt-toolkit
>> +  (package-input-rewriting/spec
>> +   `(("python-prompt-toolkit" . ,(const python-prompt-toolkit-2)))))
>
> Is this actually necessary?  Just changing the inputs as you did above
> should be sufficient I think.

If one dependency is OK with python-prompt-toolkit in version 3, but a
package has an implicit dependency on python-prompt-toolkit in version
2, then we either have to pin them all to version 2, and the OK
dependency does not get to envoy the update, or we have to resort to this.

I did it because python-ipython (19 dependents) is OK with
the update, and I did not want to pin it (and all its dependents) to python-prompt-toolkit-2.

This is my first time making such an involved update, so I'm open to
suggestions as to alternative ways of doing this.





^ permalink raw reply	[flat|nested] 34+ messages in thread

* [bug#41395] [PATCH 2/2] gnu: Add python-questionary
  2020-05-23 18:39   ` Marius Bakke
@ 2020-05-25 11:23     ` Edouard Klein
  0 siblings, 0 replies; 34+ messages in thread
From: Edouard Klein @ 2020-05-25 11:23 UTC (permalink / raw)
  To: 41395


Marius Bakke writes:

> Edouard Klein <edk@beaver-labs.com> writes:
>
>> * /gnu/packages/python-xyz.scm (python-questionary): New variable
>> * /gnu/packages/python-check.scm (python-pytest-pycodestyle): New variable
>
> Can you submit these packages as two separate patches?
>
> [...]
>
Done

>> +(define-public python-pytest-pycodestyle
>> +  (package
>> +    (name "python-pytest-pycodestyle")
>> +    (version "2.0.0")  ;; Any version higher than that requires python-pytest~=5.4
>> +    ;; (python-pytest is at version 5.3.5 as I write this comment
>> +    ;; and 5478 packages depend on it.)
>
> You can create a 'python-pytest-5.4' variable instead of sticking to
> this old version, we'll probably need it sooner or later.  No strong
> opinion though.
>

I did not understand that pinning dependencies was also allowed for
future versions. I tried but I can't get python-pytest 5.4's tests to
pass, so I'll leave it like that for now and try to come back and
revisit that if I have some time.

> [...]
>
>> +(define-public python-questionary
>> +  (package
>> +   (name "python-questionary")
>> +   (version "1.5.2")
>> +   (source
>> +    (origin
>> +     (method url-fetch)
>> +     (uri (pypi-uri "questionary" version))
>> +     (sha256
>> +      (base32
>> +       "09n737qmvzbibl8hmbd5zfg1502fd9n0r8qjzz1y0vy8nqv1xr7n"))))
>> +   (build-system python-build-system)
>> +   (propagated-inputs
>> +    `(("python-prompt-toolkit" ,python-prompt-toolkit)))
>> +   (native-inputs
>> +    `(("python-coveralls" ,python-coveralls)
>> +      ("python-pytest-cov" ,python-pytest-cov)
>> +      ("python-pytest-pycodestyle"
>> +       ,python-pytest-pycodestyle)
>> +      ))
>
> These parens feel lonely.  :-)

I did a last minute edit and forgot to lint again, sorry :)

>
>> +   (arguments
>> +    `(#:phases
>> +      (modify-phases %standard-phases
>> +        (replace 'check
>> +          (lambda _
>> +            (invoke "py.test"))))))
>> +   (home-page "https://github.com/tmbo/questionary")
>> +   (synopsis
>> +    "Pretty command line user prompts")
>
> The line break here is not necessary.
>
> LGTM with these changes, can you send updated patches?
>
> Thanks!

Thank you for reviewing the changes and for the suggestions :)




^ permalink raw reply	[flat|nested] 34+ messages in thread

* [bug#41395] [PATCH 1/4] gnu: Update python-iml homepage to https
  2020-05-19  9:53 [bug#41395] [PATCH 0/2] gnu: Add python-questionary Edouard Klein
  2020-05-19  9:58 ` [bug#41395] [PATCH 1/2] gnu: python-prompt-toolkit: Update to 3.0.5 Edouard Klein
  2020-05-19  9:59 ` [bug#41395] [PATCH 2/2] gnu: Add python-questionary Edouard Klein
@ 2020-05-25 11:24 ` Edouard Klein
  2020-05-25 22:23   ` Marius Bakke
  2020-05-25 11:26 ` [bug#41395] [PATCH 2/4] gnu: Update python-prompt-toolkit to version 3.0.5 Edouard Klein
                   ` (10 subsequent siblings)
  13 siblings, 1 reply; 34+ messages in thread
From: Edouard Klein @ 2020-05-25 11:24 UTC (permalink / raw)
  To: 41395


* gnu/packages/machine-learning.scm (python-iml): s/http/https/
---
 gnu/packages/machine-learning.scm | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/gnu/packages/machine-learning.scm b/gnu/packages/machine-learning.scm
index 6552d171bf..2395dbfe80 100644
--- a/gnu/packages/machine-learning.scm
+++ b/gnu/packages/machine-learning.scm
@@ -1808,7 +1808,7 @@ advanced research.")
        ("numpy" ,python-numpy)
        ("pandas" ,python-pandas)
        ("scipy" ,python-scipy)))
-    (home-page "http://github.com/interpretable-ml/iml")
+    (home-page "https://github.com/interpretable-ml/iml")
     (synopsis "Interpretable Machine Learning (iML) package")
     (description "Interpretable ML (iML) is a set of data type objects,
 visualizations, and interfaces that can be used by any method designed to
-- 
2.26.2




^ permalink raw reply	[flat|nested] 34+ messages in thread

* [bug#41395] [PATCH 2/4] gnu: Update python-prompt-toolkit to version 3.0.5
  2020-05-19  9:53 [bug#41395] [PATCH 0/2] gnu: Add python-questionary Edouard Klein
                   ` (2 preceding siblings ...)
  2020-05-25 11:24 ` [bug#41395] [PATCH 1/4] gnu: Update python-iml homepage to https Edouard Klein
@ 2020-05-25 11:26 ` Edouard Klein
  2020-05-25 22:28   ` Marius Bakke
  2020-05-25 11:27 ` [bug#41395] [PATCH 3/4] gnu: Add python-pytest-pycodestyle Edouard Klein
                   ` (9 subsequent siblings)
  13 siblings, 1 reply; 34+ messages in thread
From: Edouard Klein @ 2020-05-25 11:26 UTC (permalink / raw)
  To: 41395


* gnu/packages/machine-learning.scm (python-iml): Move python-nose from
propagated to native input.
(python-iml): Pin implicit python-prompt-toolkit dependency to version 2.

* gnu/packages/python-xyz.scm (python-widgetsnbextension): Update to version
3.5.1.
(python-widgetsnbextension): Pin implicit python-prompt-toolkit dependency to
version 2.
(python-ipywidgets): Update to version 7.5.1.
(python-ipywidgets): Pin implicit python-prompt-toolkit dependency to version
2.
(python-jupyter-console): Update to version 6.1.0.
(python-jupyter-console): Pin implicit python-prompt-toolkit dependency to
version 2.
(python-jupyter-console): Pin explicit python-prompt-toolkit dependency to
version 2.
(python-prompt-toolkit): Update to version 3.0.5.
(python-prompt-toolkit-2): New variable
(prompt-toolkit-2-instead-of-prompt-toolkit): New variable

---
 gnu/packages/machine-learning.scm |  7 +++--
 gnu/packages/python-xyz.scm       | 52 +++++++++++++++++++++----------
 2 files changed, 40 insertions(+), 19 deletions(-)

diff --git a/gnu/packages/machine-learning.scm b/gnu/packages/machine-learning.scm
index 2395dbfe80..5553b31bb5 100644
--- a/gnu/packages/machine-learning.scm
+++ b/gnu/packages/machine-learning.scm
@@ -14,6 +14,7 @@
 ;;; Copyright © 2019 Guillaume Le Vaillant <glv@posteo.net>
 ;;; Copyright © 2019 Brett Gilio <brettg@gnu.org>
 ;;; Copyright © 2020 Konrad Hinsen <konrad.hinsen@fastmail.net>
+;;; Copyright © 2020 Edouard Klein <edk@beaver-labs.com>
 ;;;
 ;;; This file is part of GNU Guix.
 ;;;
@@ -1803,11 +1804,13 @@ advanced research.")
          "1k8szlpm19rcwcxdny9qdm3gmaqq8akb4xlvrzyz8c2d679aak6l"))))
     (build-system python-build-system)
     (propagated-inputs
-     `(("ipython" ,python-ipython)
-       ("nose" ,python-nose)
+     `(("ipython" ,(prompt-toolkit-2-instead-of-prompt-toolkit
+                    python-ipython))
        ("numpy" ,python-numpy)
        ("pandas" ,python-pandas)
        ("scipy" ,python-scipy)))
+    (native-inputs
+     `(("nose" ,python-nose)))
     (home-page "https://github.com/interpretable-ml/iml")
     (synopsis "Interpretable Machine Learning (iML) package")
     (description "Interpretable ML (iML) is a set of data type objects,
diff --git a/gnu/packages/python-xyz.scm b/gnu/packages/python-xyz.scm
index 9aa5635ab8..f60d4cc0ab 100644
--- a/gnu/packages/python-xyz.scm
+++ b/gnu/packages/python-xyz.scm
@@ -8970,17 +8970,18 @@ interactive computing.")
 (define-public python-widgetsnbextension
   (package
     (name "python-widgetsnbextension")
-    (version "3.4.2")
+    (version "3.5.1")
     (source
      (origin
        (method url-fetch)
        (uri (pypi-uri "widgetsnbextension" version))
        (sha256
         (base32
-         "0rc2nivdy7k4m3vljx7wdh2jh11djapcgwhvzlbs0isl8gl8nqgs"))))
+         "1ismyaxbv9d56yqqqb8xl58hg0iq0bbyy014a53y1g3hfbc8g7q7"))))
     (build-system python-build-system)
     (propagated-inputs
-     `(("python-ipykernel" ,python-ipykernel)
+     `(("python-ipykernel"
+        ,(prompt-toolkit-2-instead-of-prompt-toolkit python-ipykernel))
        ("python-notebook" ,python-notebook)))
     (native-inputs
      `(("python-certifi" ,python-certifi)
@@ -8997,17 +8998,18 @@ notebooks.")
 (define-public python-ipywidgets
   (package
     (name "python-ipywidgets")
-    (version "5.2.2")
+    (version "7.5.1")
     (source
      (origin
        (method url-fetch)
        (uri (pypi-uri "ipywidgets" version))
        (sha256
         (base32
-         "1lk0qrr5l9a0z7qkkn30hv5832whxwxymf1l576fmmad0n7hkxms"))))
+         "15sww2mvnkqlvx55gwa82v05062a8j1xpncnqna4k9sl53hgcig9"))))
     (build-system python-build-system)
     (propagated-inputs
-     `(("python-ipython" ,python-ipython)
+     `(("python-ipython" ,(prompt-toolkit-2-instead-of-prompt-toolkit
+                           python-ipython))
        ("python-traitlets" ,python-traitlets)
        ("python-widgetsnbextension" ,python-widgetsnbextension)))
     (native-inputs
@@ -9027,19 +9029,20 @@ in the data.")
 (define-public python-jupyter-console
   (package
     (name "python-jupyter-console")
-    (version "6.0.0")
+    (version "6.1.0")
     (source
      (origin
        (method url-fetch)
        (uri (pypi-uri "jupyter_console" version))
        (sha256
         (base32
-         "1xdjw11cppf1fxvwkw2bk13ckkwas3bdah8baingn9296mvfi31h"))))
+         "06s3kr5vx0l1y1b7fxb04dmrppscl7q69sl9yyfr0d057d1ssvkg"))))
     (build-system python-build-system)
     (propagated-inputs
-     `(("python-ipykernel" ,python-ipykernel)
+     `(("python-ipykernel" ,(prompt-toolkit-2-instead-of-prompt-toolkit
+        python-ipykernel))
        ("python-jupyter-client" ,python-jupyter-client)
-       ("python-prompt-toolkit" ,python-prompt-toolkit)
+       ("python-prompt-toolkit" ,python-prompt-toolkit-2)
        ("python-pygments" ,python-pygments)))
     (native-inputs
      `(("python-nose" ,python-nose)))
@@ -12105,14 +12108,14 @@ collections of data.")
 (define-public python-prompt-toolkit
   (package
     (name "python-prompt-toolkit")
-    (version "2.0.7")
+    (version "3.0.5")
     (source
      (origin
        (method url-fetch)
-       (uri (pypi-uri "prompt_toolkit" version ".tar.gz"))
+       (uri (pypi-uri "prompt_toolkit" version))
        (sha256
         (base32
-         "0fgacqk73w7s932vy46pan2yp8rvjmlkag20xvaydh9mhf6h85zx"))))
+         "1j3x5s4gp4ih73sbcni0a0vffbzvrxbrbnkvb3fzjgxn810ilgan"))))
     (build-system python-build-system)
     (arguments
      `(#:phases
@@ -12126,12 +12129,11 @@ collections of data.")
              (add-installed-pythonpath inputs outputs)
              (invoke "py.test"))))))
     (propagated-inputs
-     `(("python-wcwidth" ,python-wcwidth)
-       ("python-six" ,python-six)
-       ("python-pygments" ,python-pygments)))
+     `(("python-wcwidth" ,python-wcwidth)))
     (native-inputs
      `(("python-pytest" ,python-pytest)))
-    (home-page "https://github.com/jonathanslenders/python-prompt-toolkit")
+    (home-page
+     "https://github.com/prompt-toolkit/python-prompt-toolkit")
     (synopsis "Library for building command line interfaces in Python")
     (description
      "Prompt-Toolkit is a library for building interactive command line
@@ -12141,6 +12143,22 @@ code completion, incremental search, support for Chinese double-width
 characters, mouse support, and auto suggestions.")
     (license license:bsd-3)))
 
+(define-public python-prompt-toolkit-2
+  (package (inherit python-prompt-toolkit)
+    (name "python-prompt-toolkit")
+    (version "2.0.7")
+    (source
+     (origin
+       (method url-fetch)
+       (uri (pypi-uri "prompt_toolkit" version ".tar.gz"))
+       (sha256
+        (base32
+         "0fgacqk73w7s932vy46pan2yp8rvjmlkag20xvaydh9mhf6h85zx"))))))
+
+(define-public prompt-toolkit-2-instead-of-prompt-toolkit
+  (package-input-rewriting/spec
+   `(("python-prompt-toolkit" . ,(const python-prompt-toolkit-2)))))
+
 (define-public python2-prompt-toolkit
   (package-with-python2 python-prompt-toolkit))
 
-- 
2.26.2




^ permalink raw reply	[flat|nested] 34+ messages in thread

* [bug#41395] [PATCH 3/4] gnu: Add python-pytest-pycodestyle
  2020-05-19  9:53 [bug#41395] [PATCH 0/2] gnu: Add python-questionary Edouard Klein
                   ` (3 preceding siblings ...)
  2020-05-25 11:26 ` [bug#41395] [PATCH 2/4] gnu: Update python-prompt-toolkit to version 3.0.5 Edouard Klein
@ 2020-05-25 11:27 ` Edouard Klein
  2020-05-25 22:33   ` Marius Bakke
  2020-05-25 11:28 ` [bug#41395] [PATCH 4/4] gnu: Add python-questionary Edouard Klein
                   ` (8 subsequent siblings)
  13 siblings, 1 reply; 34+ messages in thread
From: Edouard Klein @ 2020-05-25 11:27 UTC (permalink / raw)
  To: 41395


* gnu/packages/python-check.scm (python-pytest-pycodestyle): New variable
---
 gnu/packages/python-check.scm | 25 +++++++++++++++++++++++++
 1 file changed, 25 insertions(+)

diff --git a/gnu/packages/python-check.scm b/gnu/packages/python-check.scm
index 22b9ea8df5..50911673b2 100644
--- a/gnu/packages/python-check.scm
+++ b/gnu/packages/python-check.scm
@@ -337,6 +337,31 @@ testing framework.")
 framework.")
     (license license:expat)))
 
+(define-public python-pytest-pycodestyle
+  (package
+    (name "python-pytest-pycodestyle")
+    (version "2.0.0")  ;; Any version higher than that requires python-pytest~=5.4
+    ;; (python-pytest is at version 5.3.5 as I write this comment
+    ;; and 5478 packages depend on it.)
+    (source
+     (origin
+       (method url-fetch)
+       (uri (pypi-uri "pytest-pycodestyle" version))
+       (sha256
+        (base32
+         "02i5gl7pm9cwxk15sn29inz3n8flpj1r3p1l110h43f2na5w8h7z"))))
+    (build-system python-build-system)
+    (propagated-inputs
+     `(("python-pycodestyle" ,python-pycodestyle)))
+    (native-inputs
+     `(("python-pytest" ,python-pytest)))
+    (home-page
+     "https://github.com/henry0312/pytest-pycodestyle")
+    (synopsis "Pytest plugin to run pycodestyle")
+    (description "This package provides a plugin to run pycodestyle for the py.test
+framework.")
+    (license license:expat)))
+
 (define-public python-codacy-coverage
   (package
     (name "python-codacy-coverage")
-- 
2.26.2




^ permalink raw reply	[flat|nested] 34+ messages in thread

* [bug#41395] [PATCH 4/4] gnu: Add python-questionary
  2020-05-19  9:53 [bug#41395] [PATCH 0/2] gnu: Add python-questionary Edouard Klein
                   ` (4 preceding siblings ...)
  2020-05-25 11:27 ` [bug#41395] [PATCH 3/4] gnu: Add python-pytest-pycodestyle Edouard Klein
@ 2020-05-25 11:28 ` Edouard Klein
  2020-05-26  9:30 ` [bug#41395] [PATCH 1/3] gnu: Update python-widgetsnbextension to 3.5.1 Edouard Klein
                   ` (7 subsequent siblings)
  13 siblings, 0 replies; 34+ messages in thread
From: Edouard Klein @ 2020-05-25 11:28 UTC (permalink / raw)
  To: 41395


gnu/packages/python-xyz.scm (python-questionary): New variable.
---
 gnu/packages/python-xyz.scm | 33 +++++++++++++++++++++++++++++++++
 1 file changed, 33 insertions(+)

diff --git a/gnu/packages/python-xyz.scm b/gnu/packages/python-xyz.scm
index f60d4cc0ab..f2ce71946c 100644
--- a/gnu/packages/python-xyz.scm
+++ b/gnu/packages/python-xyz.scm
@@ -9406,6 +9406,39 @@ be set via config files and/or environment variables.")
 @code{ArgumentParser} object.")
     (license license:asl2.0)))
 
+(define-public python-questionary
+  (package
+   (name "python-questionary")
+   (version "1.5.2")
+   (source
+    (origin
+     (method url-fetch)
+     (uri (pypi-uri "questionary" version))
+     (sha256
+      (base32
+       "09n737qmvzbibl8hmbd5zfg1502fd9n0r8qjzz1y0vy8nqv1xr7n"))))
+   (build-system python-build-system)
+   (propagated-inputs
+    `(("python-prompt-toolkit" ,python-prompt-toolkit)))
+   (native-inputs
+    `(("python-coveralls" ,python-coveralls)
+      ("python-pytest-cov" ,python-pytest-cov)
+      ("python-pytest-pycodestyle"
+       ,python-pytest-pycodestyle)))
+   (arguments
+    `(#:phases
+      (modify-phases %standard-phases
+        (replace 'check
+          (lambda _
+            (invoke "py.test"))))))
+   (home-page "https://github.com/tmbo/questionary")
+   (synopsis
+    "Pretty command line user prompts")
+   (description
+    "Questionary helps make the input prompts easy to read and answer for the user
+using multi-select lists, confirmations, free text prompts, completion, etc.")
+  (license license:expat)))
+
 (define-public python-contextlib2
   (package
     (name "python-contextlib2")
-- 
2.26.2




^ permalink raw reply	[flat|nested] 34+ messages in thread

* [bug#41395] [PATCH 1/2] gnu: python-prompt-toolkit: Update to 3.0.5
  2020-05-25 10:52     ` Edouard Klein
@ 2020-05-25 22:21       ` Marius Bakke
  2020-05-26  9:28         ` Edouard Klein
  0 siblings, 1 reply; 34+ messages in thread
From: Marius Bakke @ 2020-05-25 22:21 UTC (permalink / raw)
  To: Edouard Klein, 41395

[-- Attachment #1: Type: text/plain, Size: 4283 bytes --]

Edouard Klein <edou@rdklein.fr> writes:

>>>      (synopsis "Interpretable Machine Learning (iML) package")
>>>      (description "Interpretable ML (iML) is a set of data type objects,
>>>  visualizations, and interfaces that can be used by any method designed to
>>> diff --git a/gnu/packages/python-xyz.scm b/gnu/packages/python-xyz.scm
>>> index b8a51570c3..5fd7e274e9 100644
>>> --- a/gnu/packages/python-xyz.scm
>>> +++ b/gnu/packages/python-xyz.scm
>>> @@ -8922,6 +8922,7 @@ interactive computing.")
>>>      (build-system python-build-system)
>>>      (propagated-inputs
>>>       `(("python-ipykernel" ,python-ipykernel)
>>> +       ("python-prompt-toolkit" ,python-prompt-toolkit-2)
>>>         ("python-notebook" ,python-notebook)))
>>>      (native-inputs
>>>       `(("python-certifi" ,python-certifi)
>>> @@ -8950,6 +8951,7 @@ notebooks.")
>>>      (propagated-inputs
>>>       `(("python-ipython" ,python-ipython)
>>>         ("python-traitlets" ,python-traitlets)
>>> +       ("python-prompt-toolkit" ,python-prompt-toolkit-2)
>>>         ("python-widgetsnbextension" ,python-widgetsnbextension)))
>>>      (native-inputs
>>>       `(("python-nose" ,python-nose)
>>> @@ -8980,7 +8982,7 @@ in the data.")
>>>      (propagated-inputs
>>>       `(("python-ipykernel" ,python-ipykernel)
>>>         ("python-jupyter-client" ,python-jupyter-client)
>>> -       ("python-prompt-toolkit" ,python-prompt-toolkit)
>>> +       ("python-prompt-toolkit" ,python-prompt-toolkit-2)
>>>         ("python-pygments" ,python-pygments)))
>>>      (native-inputs
>>>       `(("python-nose" ,python-nose)))
>>> @@ -12049,6 +12051,44 @@ collections of data.")
>>>    (package-with-python2 python-backpack))
>>
>> It would be great to update these packages instead of pinning to the old
>> version.  I won't blame you if you don't feel like embarking on that
>> journey though.
>>
>
> In the new patches I'm about to send, I updated them. Alas even their
> latest versions still require python-prompt-toolkit <=2.1, so I had to
> pin the dependencies. I did it in a cleaner way, though.

Oh too bad that updating did not work.  Terrible that these are so tied
to the version of python-prompt-toolkit.  Can you split those updates
out to separate patches, preceding the prompt-toolkit patch?  Then they
can be reverted and tested individually without having to revert the
whole thing in case there are problems.

>>> +(define-public python-prompt-toolkit-2
>>>    (package
>>>      (name "python-prompt-toolkit")
>>>      (version "2.0.7")
>>> @@ -12077,7 +12117,7 @@ collections of data.")
>>>         ("python-pygments" ,python-pygments)))
>>>      (native-inputs
>>>       `(("python-pytest" ,python-pytest)))
>>> -    (home-page "https://github.com/jonathanslenders/python-prompt-toolkit")
>>> +    (home-page "https://github.com/prompt-toolkit/python-prompt-toolkit")
>>>      (synopsis "Library for building command line interfaces in Python")
>>>      (description
>>>       "Prompt-Toolkit is a library for building interactive command line
>>> @@ -12104,6 +12144,10 @@ characters, mouse support, and auto suggestions.")
>>>  (define-public python2-prompt-toolkit-1
>>>    (package-with-python2 python-prompt-toolkit-1))
>>>  
>>> +(define-public prompt-toolkit-2-instead-of-prompt-toolkit
>>> +  (package-input-rewriting/spec
>>> +   `(("python-prompt-toolkit" . ,(const python-prompt-toolkit-2)))))
>>
>> Is this actually necessary?  Just changing the inputs as you did above
>> should be sufficient I think.
>
> If one dependency is OK with python-prompt-toolkit in version 3, but a
> package has an implicit dependency on python-prompt-toolkit in version
> 2, then we either have to pin them all to version 2, and the OK
> dependency does not get to envoy the update, or we have to resort to this.
>
> I did it because python-ipython (19 dependents) is OK with
> the update, and I did not want to pin it (and all its dependents) to python-prompt-toolkit-2.
>
> This is my first time making such an involved update, so I'm open to
> suggestions as to alternative ways of doing this.

Oh I see, makes sense.  The new patch is much clearer.  I will send a
separate reply with further comments.

[-- Attachment #2: signature.asc --]
[-- Type: application/pgp-signature, Size: 487 bytes --]

^ permalink raw reply	[flat|nested] 34+ messages in thread

* [bug#41395] [PATCH 1/4] gnu: Update python-iml homepage to https
  2020-05-25 11:24 ` [bug#41395] [PATCH 1/4] gnu: Update python-iml homepage to https Edouard Klein
@ 2020-05-25 22:23   ` Marius Bakke
  0 siblings, 0 replies; 34+ messages in thread
From: Marius Bakke @ 2020-05-25 22:23 UTC (permalink / raw)
  To: Edouard Klein, 41395

[-- Attachment #1: Type: text/plain, Size: 193 bytes --]

Edouard Klein <edk@beaver-labs.com> writes:

> * gnu/packages/machine-learning.scm (python-iml): s/http/https/

Applied, with a slightly edited commit message to closer follow our
conventions.

[-- Attachment #2: signature.asc --]
[-- Type: application/pgp-signature, Size: 487 bytes --]

^ permalink raw reply	[flat|nested] 34+ messages in thread

* [bug#41395] [PATCH 2/4] gnu: Update python-prompt-toolkit to version 3.0.5
  2020-05-25 11:26 ` [bug#41395] [PATCH 2/4] gnu: Update python-prompt-toolkit to version 3.0.5 Edouard Klein
@ 2020-05-25 22:28   ` Marius Bakke
  2020-05-26 11:39     ` Edouard Klein
  0 siblings, 1 reply; 34+ messages in thread
From: Marius Bakke @ 2020-05-25 22:28 UTC (permalink / raw)
  To: Edouard Klein, 41395

[-- Attachment #1: Type: text/plain, Size: 1641 bytes --]

Edouard Klein <edk@beaver-labs.com> writes:

> * gnu/packages/machine-learning.scm (python-iml): Move python-nose from
> propagated to native input.

Can you submit this change as a separate patch, as it is unrelated to
the python-prompt-toolkit update?

[...]

> @@ -12105,14 +12108,14 @@ collections of data.")
>  (define-public python-prompt-toolkit
>    (package
>      (name "python-prompt-toolkit")
> -    (version "2.0.7")
> +    (version "3.0.5")
>      (source
>       (origin
>         (method url-fetch)
> -       (uri (pypi-uri "prompt_toolkit" version ".tar.gz"))
> +       (uri (pypi-uri "prompt_toolkit" version))
>         (sha256
>          (base32
> -         "0fgacqk73w7s932vy46pan2yp8rvjmlkag20xvaydh9mhf6h85zx"))))
> +         "1j3x5s4gp4ih73sbcni0a0vffbzvrxbrbnkvb3fzjgxn810ilgan"))))
>      (build-system python-build-system)
>      (arguments
>       `(#:phases
> @@ -12126,12 +12129,11 @@ collections of data.")
>               (add-installed-pythonpath inputs outputs)
>               (invoke "py.test"))))))
>      (propagated-inputs
> -     `(("python-wcwidth" ,python-wcwidth)
> -       ("python-six" ,python-six)
> -       ("python-pygments" ,python-pygments)))
> +     `(("python-wcwidth" ,python-wcwidth)))

I think you need to re-add these inputs in 'python-prompt-toolkit-2'.
'python2-prompt-toolkit' should probably inherit from
'python-prompt-toolkit-2' too, given that the dependency on Six is
removed in version 3.

Finally 'python-prompt-toolkit-1' (!!!) also needs to inherit from
'python-prompt-toolkit-2' so that the inputs don't change, unless
version 1 can be removed entirely.

Quite the cabal!

[-- Attachment #2: signature.asc --]
[-- Type: application/pgp-signature, Size: 487 bytes --]

^ permalink raw reply	[flat|nested] 34+ messages in thread

* [bug#41395] [PATCH 3/4] gnu: Add python-pytest-pycodestyle
  2020-05-25 11:27 ` [bug#41395] [PATCH 3/4] gnu: Add python-pytest-pycodestyle Edouard Klein
@ 2020-05-25 22:33   ` Marius Bakke
  0 siblings, 0 replies; 34+ messages in thread
From: Marius Bakke @ 2020-05-25 22:33 UTC (permalink / raw)
  To: Edouard Klein, 41395

[-- Attachment #1: Type: text/plain, Size: 180 bytes --]

Edouard Klein <edk@beaver-labs.com> writes:

> * gnu/packages/python-check.scm (python-pytest-pycodestyle): New variable

Applied with minor editorializations + copyright, thanks!

[-- Attachment #2: signature.asc --]
[-- Type: application/pgp-signature, Size: 487 bytes --]

^ permalink raw reply	[flat|nested] 34+ messages in thread

* [bug#41395] [PATCH 1/2] gnu: python-prompt-toolkit: Update to 3.0.5
  2020-05-25 22:21       ` Marius Bakke
@ 2020-05-26  9:28         ` Edouard Klein
  0 siblings, 0 replies; 34+ messages in thread
From: Edouard Klein @ 2020-05-26  9:28 UTC (permalink / raw)
  To: 41395


Marius Bakke writes:

> Edouard Klein <edou@rdklein.fr> writes:
>
>>>>      (synopsis "Interpretable Machine Learning (iML) package")
>>>>      (description "Interpretable ML (iML) is a set of data type objects,
>>>>  visualizations, and interfaces that can be used by any method designed to
>>>> diff --git a/gnu/packages/python-xyz.scm b/gnu/packages/python-xyz.scm
>>>> index b8a51570c3..5fd7e274e9 100644
>>>> --- a/gnu/packages/python-xyz.scm
>>>> +++ b/gnu/packages/python-xyz.scm
>>>> @@ -8922,6 +8922,7 @@ interactive computing.")
>>>>      (build-system python-build-system)
>>>>      (propagated-inputs
>>>>       `(("python-ipykernel" ,python-ipykernel)
>>>> +       ("python-prompt-toolkit" ,python-prompt-toolkit-2)
>>>>         ("python-notebook" ,python-notebook)))
>>>>      (native-inputs
>>>>       `(("python-certifi" ,python-certifi)
>>>> @@ -8950,6 +8951,7 @@ notebooks.")
>>>>      (propagated-inputs
>>>>       `(("python-ipython" ,python-ipython)
>>>>         ("python-traitlets" ,python-traitlets)
>>>> +       ("python-prompt-toolkit" ,python-prompt-toolkit-2)
>>>>         ("python-widgetsnbextension" ,python-widgetsnbextension)))
>>>>      (native-inputs
>>>>       `(("python-nose" ,python-nose)
>>>> @@ -8980,7 +8982,7 @@ in the data.")
>>>>      (propagated-inputs
>>>>       `(("python-ipykernel" ,python-ipykernel)
>>>>         ("python-jupyter-client" ,python-jupyter-client)
>>>> -       ("python-prompt-toolkit" ,python-prompt-toolkit)
>>>> +       ("python-prompt-toolkit" ,python-prompt-toolkit-2)
>>>>         ("python-pygments" ,python-pygments)))
>>>>      (native-inputs
>>>>       `(("python-nose" ,python-nose)))
>>>> @@ -12049,6 +12051,44 @@ collections of data.")
>>>>    (package-with-python2 python-backpack))
>>>
>>> It would be great to update these packages instead of pinning to the old
>>> version.  I won't blame you if you don't feel like embarking on that
>>> journey though.
>>>
>>
>> In the new patches I'm about to send, I updated them. Alas even their
>> latest versions still require python-prompt-toolkit <=2.1, so I had to
>> pin the dependencies. I did it in a cleaner way, though.
>
> Oh too bad that updating did not work.  Terrible that these are so tied
> to the version of python-prompt-toolkit.  Can you split those updates
> out to separate patches, preceding the prompt-toolkit patch?  Then they
> can be reverted and tested individually without having to revert the
> whole thing in case there are problems.
>

Of course :) I should have thought about it, sorry.


>>>> +(define-public python-prompt-toolkit-2
>>>>    (package
>>>>      (name "python-prompt-toolkit")
>>>>      (version "2.0.7")
>>>> @@ -12077,7 +12117,7 @@ collections of data.")
>>>>         ("python-pygments" ,python-pygments)))
>>>>      (native-inputs
>>>>       `(("python-pytest" ,python-pytest)))
>>>> -    (home-page "https://github.com/jonathanslenders/python-prompt-toolkit")
>>>> +    (home-page "https://github.com/prompt-toolkit/python-prompt-toolkit")
>>>>      (synopsis "Library for building command line interfaces in Python")
>>>>      (description
>>>>       "Prompt-Toolkit is a library for building interactive command line
>>>> @@ -12104,6 +12144,10 @@ characters, mouse support, and auto suggestions.")
>>>>  (define-public python2-prompt-toolkit-1
>>>>    (package-with-python2 python-prompt-toolkit-1))
>>>>  
>>>> +(define-public prompt-toolkit-2-instead-of-prompt-toolkit
>>>> +  (package-input-rewriting/spec
>>>> +   `(("python-prompt-toolkit" . ,(const python-prompt-toolkit-2)))))
>>>
>>> Is this actually necessary?  Just changing the inputs as you did above
>>> should be sufficient I think.
>>
>> If one dependency is OK with python-prompt-toolkit in version 3, but a
>> package has an implicit dependency on python-prompt-toolkit in version
>> 2, then we either have to pin them all to version 2, and the OK
>> dependency does not get to envoy the update, or we have to resort to this.
>>
>> I did it because python-ipython (19 dependents) is OK with
>> the update, and I did not want to pin it (and all its dependents) to python-prompt-toolkit-2.
>>
>> This is my first time making such an involved update, so I'm open to
>> suggestions as to alternative ways of doing this.
>
> Oh I see, makes sense.  The new patch is much clearer.  I will send a
> separate reply with further comments.





^ permalink raw reply	[flat|nested] 34+ messages in thread

* [bug#41395] [PATCH 1/3] gnu: Update python-widgetsnbextension to 3.5.1
  2020-05-19  9:53 [bug#41395] [PATCH 0/2] gnu: Add python-questionary Edouard Klein
                   ` (5 preceding siblings ...)
  2020-05-25 11:28 ` [bug#41395] [PATCH 4/4] gnu: Add python-questionary Edouard Klein
@ 2020-05-26  9:30 ` Edouard Klein
  2020-05-30 13:16   ` Marius Bakke
  2020-05-26  9:31 ` [bug#41395] [PATCH 2/3] gnu: Update python-ipywidgets to 7.5.1 Edouard Klein
                   ` (6 subsequent siblings)
  13 siblings, 1 reply; 34+ messages in thread
From: Edouard Klein @ 2020-05-26  9:30 UTC (permalink / raw)
  To: 41395


* gnu/packages/python-xyz.scm (python-widgetsnbextension): Update to 3.5.1.
---
 gnu/packages/python-xyz.scm | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/gnu/packages/python-xyz.scm b/gnu/packages/python-xyz.scm
index efd92beb9f..c95a63dacc 100644
--- a/gnu/packages/python-xyz.scm
+++ b/gnu/packages/python-xyz.scm
@@ -8970,14 +8970,14 @@ interactive computing.")
 (define-public python-widgetsnbextension
   (package
     (name "python-widgetsnbextension")
-    (version "3.4.2")
+    (version "3.5.1")
     (source
      (origin
        (method url-fetch)
        (uri (pypi-uri "widgetsnbextension" version))
        (sha256
         (base32
-         "0rc2nivdy7k4m3vljx7wdh2jh11djapcgwhvzlbs0isl8gl8nqgs"))))
+         "1ismyaxbv9d56yqqqb8xl58hg0iq0bbyy014a53y1g3hfbc8g7q7"))))
     (build-system python-build-system)
     (propagated-inputs
      `(("python-ipykernel" ,python-ipykernel)
-- 
2.26.2




^ permalink raw reply	[flat|nested] 34+ messages in thread

* [bug#41395] [PATCH 2/3] gnu: Update python-ipywidgets to 7.5.1
  2020-05-19  9:53 [bug#41395] [PATCH 0/2] gnu: Add python-questionary Edouard Klein
                   ` (6 preceding siblings ...)
  2020-05-26  9:30 ` [bug#41395] [PATCH 1/3] gnu: Update python-widgetsnbextension to 3.5.1 Edouard Klein
@ 2020-05-26  9:31 ` Edouard Klein
  2020-05-30 13:18   ` Marius Bakke
  2020-05-26  9:33 ` [bug#41395] [PATCH 3/3] gnu: Update python-jupyter-console to 6.1.0 Edouard Klein
                   ` (5 subsequent siblings)
  13 siblings, 1 reply; 34+ messages in thread
From: Edouard Klein @ 2020-05-26  9:31 UTC (permalink / raw)
  To: 41395


* gnu/packages/python-xyz.scm (python-ipywidgets): Update to 7.5.1.
---
 gnu/packages/python-xyz.scm | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/gnu/packages/python-xyz.scm b/gnu/packages/python-xyz.scm
index c95a63dacc..5e6627a587 100644
--- a/gnu/packages/python-xyz.scm
+++ b/gnu/packages/python-xyz.scm
@@ -8997,14 +8997,14 @@ notebooks.")
 (define-public python-ipywidgets
   (package
     (name "python-ipywidgets")
-    (version "5.2.2")
+    (version "7.5.1")
     (source
      (origin
        (method url-fetch)
        (uri (pypi-uri "ipywidgets" version))
        (sha256
         (base32
-         "1lk0qrr5l9a0z7qkkn30hv5832whxwxymf1l576fmmad0n7hkxms"))))
+         "15sww2mvnkqlvx55gwa82v05062a8j1xpncnqna4k9sl53hgcig9"))))
     (build-system python-build-system)
     (propagated-inputs
      `(("python-ipython" ,python-ipython)
-- 
2.26.2




^ permalink raw reply	[flat|nested] 34+ messages in thread

* [bug#41395] [PATCH 3/3] gnu: Update python-jupyter-console to 6.1.0
  2020-05-19  9:53 [bug#41395] [PATCH 0/2] gnu: Add python-questionary Edouard Klein
                   ` (7 preceding siblings ...)
  2020-05-26  9:31 ` [bug#41395] [PATCH 2/3] gnu: Update python-ipywidgets to 7.5.1 Edouard Klein
@ 2020-05-26  9:33 ` Edouard Klein
  2020-05-30 13:19   ` Marius Bakke
  2020-05-26 11:21 ` [bug#41395] [PATCH] gnu: Move nose from propagated to native in python-iml Edouard Klein
                   ` (4 subsequent siblings)
  13 siblings, 1 reply; 34+ messages in thread
From: Edouard Klein @ 2020-05-26  9:33 UTC (permalink / raw)
  To: 41395


* /gnu/packages/python-xyz.scm (python-jupyter-console): Update to 6.1.0.
---
 gnu/packages/python-xyz.scm | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/gnu/packages/python-xyz.scm b/gnu/packages/python-xyz.scm
index 5e6627a587..76a1635b12 100644
--- a/gnu/packages/python-xyz.scm
+++ b/gnu/packages/python-xyz.scm
@@ -9027,14 +9027,14 @@ in the data.")
 (define-public python-jupyter-console
   (package
     (name "python-jupyter-console")
-    (version "6.0.0")
+    (version "6.1.0")
     (source
      (origin
        (method url-fetch)
        (uri (pypi-uri "jupyter_console" version))
        (sha256
         (base32
-         "1xdjw11cppf1fxvwkw2bk13ckkwas3bdah8baingn9296mvfi31h"))))
+         "06s3kr5vx0l1y1b7fxb04dmrppscl7q69sl9yyfr0d057d1ssvkg"))))
     (build-system python-build-system)
     (propagated-inputs
      `(("python-ipykernel" ,python-ipykernel)
-- 
2.26.2




^ permalink raw reply	[flat|nested] 34+ messages in thread

* [bug#41395] [PATCH] gnu: Move nose from propagated to native in python-iml
  2020-05-19  9:53 [bug#41395] [PATCH 0/2] gnu: Add python-questionary Edouard Klein
                   ` (8 preceding siblings ...)
  2020-05-26  9:33 ` [bug#41395] [PATCH 3/3] gnu: Update python-jupyter-console to 6.1.0 Edouard Klein
@ 2020-05-26 11:21 ` Edouard Klein
  2020-05-30 13:21   ` Marius Bakke
  2020-05-26 11:40 ` [bug#41395] [PATCH 1/3] " Edouard Klein
                   ` (3 subsequent siblings)
  13 siblings, 1 reply; 34+ messages in thread
From: Edouard Klein @ 2020-05-26 11:21 UTC (permalink / raw)
  To: 41395


* gnu/packages/machine-learning.scm (python-iml): Make python-nose
a native input instead of a propagated input.
---
 gnu/packages/machine-learning.scm | 4 +++-
 1 file changed, 3 insertions(+), 1 deletion(-)

diff --git a/gnu/packages/machine-learning.scm b/gnu/packages/machine-learning.scm
index 1b678d3d20..17d01bc656 100644
--- a/gnu/packages/machine-learning.scm
+++ b/gnu/packages/machine-learning.scm
@@ -14,6 +14,7 @@
 ;;; Copyright © 2019 Guillaume Le Vaillant <glv@posteo.net>
 ;;; Copyright © 2019 Brett Gilio <brettg@gnu.org>
 ;;; Copyright © 2020 Konrad Hinsen <konrad.hinsen@fastmail.net>
+;;; Copyright © 2020 Edouard Klein <edk@beaver-labs.com>
 ;;;
 ;;; This file is part of GNU Guix.
 ;;;
@@ -1817,10 +1818,11 @@ advanced research.")
     (build-system python-build-system)
     (propagated-inputs
      `(("ipython" ,python-ipython)
-       ("nose" ,python-nose)
        ("numpy" ,python-numpy)
        ("pandas" ,python-pandas)
        ("scipy" ,python-scipy)))
+    (native-inputs
+     `(("nose" ,python-nose)))
     (home-page "https://github.com/interpretable-ml/iml")
     (synopsis "Interpretable Machine Learning (iML) package")
     (description "Interpretable ML (iML) is a set of data type objects,
-- 
2.26.2




^ permalink raw reply	[flat|nested] 34+ messages in thread

* [bug#41395] [PATCH 2/4] gnu: Update python-prompt-toolkit to version 3.0.5
  2020-05-25 22:28   ` Marius Bakke
@ 2020-05-26 11:39     ` Edouard Klein
  0 siblings, 0 replies; 34+ messages in thread
From: Edouard Klein @ 2020-05-26 11:39 UTC (permalink / raw)
  To: 41395


Marius Bakke writes:

> Edouard Klein <edk@beaver-labs.com> writes:
>
>> * gnu/packages/machine-learning.scm (python-iml): Move python-nose from
>> propagated to native input.
>
> Can you submit this change as a separate patch, as it is unrelated to
> the python-prompt-toolkit update?
>
> [...]
Done

>
>> @@ -12105,14 +12108,14 @@ collections of data.")
>>  (define-public python-prompt-toolkit
>>    (package
>>      (name "python-prompt-toolkit")
>> -    (version "2.0.7")
>> +    (version "3.0.5")
>>      (source
>>       (origin
>>         (method url-fetch)
>> -       (uri (pypi-uri "prompt_toolkit" version ".tar.gz"))
>> +       (uri (pypi-uri "prompt_toolkit" version))
>>         (sha256
>>          (base32
>> -         "0fgacqk73w7s932vy46pan2yp8rvjmlkag20xvaydh9mhf6h85zx"))))
>> +         "1j3x5s4gp4ih73sbcni0a0vffbzvrxbrbnkvb3fzjgxn810ilgan"))))
>>      (build-system python-build-system)
>>      (arguments
>>       `(#:phases
>> @@ -12126,12 +12129,11 @@ collections of data.")
>>               (add-installed-pythonpath inputs outputs)
>>               (invoke "py.test"))))))
>>      (propagated-inputs
>> -     `(("python-wcwidth" ,python-wcwidth)
>> -       ("python-six" ,python-six)
>> -       ("python-pygments" ,python-pygments)))
>> +     `(("python-wcwidth" ,python-wcwidth)))
>
> I think you need to re-add these inputs in 'python-prompt-toolkit-2'.
> 'python2-prompt-toolkit' should probably inherit from
> 'python-prompt-toolkit-2' too, given that the dependency on Six is
> removed in version 3.
>
That makes sense, done.

> Finally 'python-prompt-toolkit-1' (!!!) also needs to inherit from
> 'python-prompt-toolkit-2' so that the inputs don't change, unless
> version 1 can be removed entirely.

I grepped and did not find any user anywhere so I went ahead and removed it.

>
> Quite the cabal!





^ permalink raw reply	[flat|nested] 34+ messages in thread

* [bug#41395] [PATCH 1/3] gnu: Move nose from propagated to native in python-iml
  2020-05-19  9:53 [bug#41395] [PATCH 0/2] gnu: Add python-questionary Edouard Klein
                   ` (9 preceding siblings ...)
  2020-05-26 11:21 ` [bug#41395] [PATCH] gnu: Move nose from propagated to native in python-iml Edouard Klein
@ 2020-05-26 11:40 ` Edouard Klein
  2020-05-26 11:41 ` [bug#41395] [PATCH 2/3] gnu: Remove python-prompt-toolkit-1 Edouard Klein
                   ` (2 subsequent siblings)
  13 siblings, 0 replies; 34+ messages in thread
From: Edouard Klein @ 2020-05-26 11:40 UTC (permalink / raw)
  To: 41395


* gnu/packages/machine-learning.scm (python-iml): Make python-nose
a native input instead of a propagated input.
---
 gnu/packages/machine-learning.scm | 4 +++-
 1 file changed, 3 insertions(+), 1 deletion(-)

diff --git a/gnu/packages/machine-learning.scm b/gnu/packages/machine-learning.scm
index 1b678d3d20..17d01bc656 100644
--- a/gnu/packages/machine-learning.scm
+++ b/gnu/packages/machine-learning.scm
@@ -14,6 +14,7 @@
 ;;; Copyright © 2019 Guillaume Le Vaillant <glv@posteo.net>
 ;;; Copyright © 2019 Brett Gilio <brettg@gnu.org>
 ;;; Copyright © 2020 Konrad Hinsen <konrad.hinsen@fastmail.net>
+;;; Copyright © 2020 Edouard Klein <edk@beaver-labs.com>
 ;;;
 ;;; This file is part of GNU Guix.
 ;;;
@@ -1817,10 +1818,11 @@ advanced research.")
     (build-system python-build-system)
     (propagated-inputs
      `(("ipython" ,python-ipython)
-       ("nose" ,python-nose)
        ("numpy" ,python-numpy)
        ("pandas" ,python-pandas)
        ("scipy" ,python-scipy)))
+    (native-inputs
+     `(("nose" ,python-nose)))
     (home-page "https://github.com/interpretable-ml/iml")
     (synopsis "Interpretable Machine Learning (iML) package")
     (description "Interpretable ML (iML) is a set of data type objects,
-- 
2.26.2




^ permalink raw reply	[flat|nested] 34+ messages in thread

* [bug#41395] [PATCH 2/3] gnu: Remove python-prompt-toolkit-1
  2020-05-19  9:53 [bug#41395] [PATCH 0/2] gnu: Add python-questionary Edouard Klein
                   ` (10 preceding siblings ...)
  2020-05-26 11:40 ` [bug#41395] [PATCH 1/3] " Edouard Klein
@ 2020-05-26 11:41 ` Edouard Klein
  2020-05-26 13:41   ` Edouard Klein
  2020-05-30 13:26   ` Marius Bakke
  2020-05-26 11:42 ` [bug#41395] [PATCH 3/3] gnu: Update python-prompt-toolkit to version 3.0.5 Edouard Klein
  2020-05-26 13:53 ` [bug#41395] [PATCH] " Edouard Klein
  13 siblings, 2 replies; 34+ messages in thread
From: Edouard Klein @ 2020-05-26 11:41 UTC (permalink / raw)
  To: 41395


* gnu/packages/python-xyz.scm (python-prompt-toolkit-1): Remove variable.
---
 gnu/packages/python-xyz.scm | 14 --------------
 1 file changed, 14 deletions(-)

diff --git a/gnu/packages/python-xyz.scm b/gnu/packages/python-xyz.scm
index 76a1635b12..04cfb98eef 100644
--- a/gnu/packages/python-xyz.scm
+++ b/gnu/packages/python-xyz.scm
@@ -12144,20 +12144,6 @@ characters, mouse support, and auto suggestions.")
 (define-public python2-prompt-toolkit
   (package-with-python2 python-prompt-toolkit))
 
-(define-public python-prompt-toolkit-1
-  (package (inherit python-prompt-toolkit)
-    (version "1.0.15")
-    (source
-     (origin
-       (method url-fetch)
-       (uri (pypi-uri "prompt_toolkit" version ".tar.gz"))
-       (sha256
-        (base32
-         "05v9h5nydljwpj5nm8n804ms0glajwfy1zagrzqrg91wk3qqi1c5"))))))
-
-(define-public python2-prompt-toolkit-1
-  (package-with-python2 python-prompt-toolkit-1))
-
 (define-public python-jedi
   (package
     (name "python-jedi")
-- 
2.26.2




^ permalink raw reply	[flat|nested] 34+ messages in thread

* [bug#41395] [PATCH 3/3] gnu: Update python-prompt-toolkit to version 3.0.5
  2020-05-19  9:53 [bug#41395] [PATCH 0/2] gnu: Add python-questionary Edouard Klein
                   ` (11 preceding siblings ...)
  2020-05-26 11:41 ` [bug#41395] [PATCH 2/3] gnu: Remove python-prompt-toolkit-1 Edouard Klein
@ 2020-05-26 11:42 ` Edouard Klein
  2020-05-26 13:55   ` Edouard Klein
  2020-05-26 13:53 ` [bug#41395] [PATCH] " Edouard Klein
  13 siblings, 1 reply; 34+ messages in thread
From: Edouard Klein @ 2020-05-26 11:42 UTC (permalink / raw)
  To: 41395


* gnu/packages/machine-learning.scm (python-iml): Pin implicit
python-prompt-toolkit dependency to version 2.

* gnu/packages/python-xyz.scm (python-widgetsnbextension): Pin implicit
python-prompt-toolkit dependency to version 2.
(python-ipywidgets): Update to version 7.5.1.
(python-ipywidgets): Pin implicit python-prompt-toolkit dependency to version
2.
(python-jupyter-console): Update to version 6.1.0.
(python-jupyter-console): Pin implicit python-prompt-toolkit dependency to
version 2.
(python-jupyter-console): Pin explicit python-prompt-toolkit dependency to
version 2.
(python-prompt-toolkit): Update to version 3.0.5.
(python-prompt-toolkit-2): New variable
(prompt-toolkit-2-instead-of-prompt-toolkit): New variable
(python2-prompt-toolkit): keep at version 2.
---
 gnu/packages/machine-learning.scm |  3 +-
 gnu/packages/python-xyz.scm       | 47 +++++++++++++++++++++++--------
 2 files changed, 37 insertions(+), 13 deletions(-)

diff --git a/gnu/packages/machine-learning.scm b/gnu/packages/machine-learning.scm
index 17d01bc656..e26768267b 100644
--- a/gnu/packages/machine-learning.scm
+++ b/gnu/packages/machine-learning.scm
@@ -1817,7 +1817,8 @@ advanced research.")
          "1k8szlpm19rcwcxdny9qdm3gmaqq8akb4xlvrzyz8c2d679aak6l"))))
     (build-system python-build-system)
     (propagated-inputs
-     `(("ipython" ,python-ipython)
+     `(("ipython" ,(prompt-toolkit-2-instead-of-prompt-toolkit
+                    python-ipython))
        ("numpy" ,python-numpy)
        ("pandas" ,python-pandas)
        ("scipy" ,python-scipy)))
diff --git a/gnu/packages/python-xyz.scm b/gnu/packages/python-xyz.scm
index 04cfb98eef..e7d8c69472 100644
--- a/gnu/packages/python-xyz.scm
+++ b/gnu/packages/python-xyz.scm
@@ -8980,7 +8980,8 @@ interactive computing.")
          "1ismyaxbv9d56yqqqb8xl58hg0iq0bbyy014a53y1g3hfbc8g7q7"))))
     (build-system python-build-system)
     (propagated-inputs
-     `(("python-ipykernel" ,python-ipykernel)
+     `(("python-ipykernel"
+        ,(prompt-toolkit-2-instead-of-prompt-toolkit python-ipykernel))
        ("python-notebook" ,python-notebook)))
     (native-inputs
      `(("python-certifi" ,python-certifi)
@@ -9007,7 +9008,8 @@ notebooks.")
          "15sww2mvnkqlvx55gwa82v05062a8j1xpncnqna4k9sl53hgcig9"))))
     (build-system python-build-system)
     (propagated-inputs
-     `(("python-ipython" ,python-ipython)
+     `(("python-ipython" ,(prompt-toolkit-2-instead-of-prompt-toolkit
+                           python-ipython))
        ("python-traitlets" ,python-traitlets)
        ("python-widgetsnbextension" ,python-widgetsnbextension)))
     (native-inputs
@@ -9037,9 +9039,10 @@ in the data.")
          "06s3kr5vx0l1y1b7fxb04dmrppscl7q69sl9yyfr0d057d1ssvkg"))))
     (build-system python-build-system)
     (propagated-inputs
-     `(("python-ipykernel" ,python-ipykernel)
+     `(("python-ipykernel" ,(prompt-toolkit-2-instead-of-prompt-toolkit
+        python-ipykernel))
        ("python-jupyter-client" ,python-jupyter-client)
-       ("python-prompt-toolkit" ,python-prompt-toolkit)
+       ("python-prompt-toolkit" ,python-prompt-toolkit-2)
        ("python-pygments" ,python-pygments)))
     (native-inputs
      `(("python-nose" ,python-nose)))
@@ -12105,14 +12108,14 @@ collections of data.")
 (define-public python-prompt-toolkit
   (package
     (name "python-prompt-toolkit")
-    (version "2.0.7")
+    (version "3.0.5")
     (source
      (origin
        (method url-fetch)
-       (uri (pypi-uri "prompt_toolkit" version ".tar.gz"))
+       (uri (pypi-uri "prompt_toolkit" version))
        (sha256
         (base32
-         "0fgacqk73w7s932vy46pan2yp8rvjmlkag20xvaydh9mhf6h85zx"))))
+         "1j3x5s4gp4ih73sbcni0a0vffbzvrxbrbnkvb3fzjgxn810ilgan"))))
     (build-system python-build-system)
     (arguments
      `(#:phases
@@ -12126,12 +12129,11 @@ collections of data.")
              (add-installed-pythonpath inputs outputs)
              (invoke "py.test"))))))
     (propagated-inputs
-     `(("python-wcwidth" ,python-wcwidth)
-       ("python-six" ,python-six)
-       ("python-pygments" ,python-pygments)))
+     `(("python-wcwidth" ,python-wcwidth)))
     (native-inputs
      `(("python-pytest" ,python-pytest)))
-    (home-page "https://github.com/jonathanslenders/python-prompt-toolkit")
+    (home-page
+     "https://github.com/prompt-toolkit/python-prompt-toolkit")
     (synopsis "Library for building command line interfaces in Python")
     (description
      "Prompt-Toolkit is a library for building interactive command line
@@ -12141,8 +12143,29 @@ code completion, incremental search, support for Chinese double-width
 characters, mouse support, and auto suggestions.")
     (license license:bsd-3)))
 
+(define-public python-prompt-toolkit-2
+  (package (inherit python-prompt-toolkit)
+    (name "python-prompt-toolkit")
+    (version "2.0.7")
+    (source
+     (origin
+       (method url-fetch)
+       (uri (pypi-uri "prompt_toolkit" version ".tar.gz"))
+       (sha256
+        (base32
+         "0fgacqk73w7s932vy46pan2yp8rvjmlkag20xvaydh9mhf6h85zx"))))
+    (propagated-inputs
+     `(("python-wcwidth" ,python-wcwidth)
+       ("python-six" ,python-six)
+       ("python-pygments" ,python-pygments)
+       ("python-wcwidth" ,python-wcwidth)))))
+
+(define-public prompt-toolkit-2-instead-of-prompt-toolkit
+  (package-input-rewriting/spec
+   `(("python-prompt-toolkit" . ,(const python-prompt-toolkit-2)))))
+
 (define-public python2-prompt-toolkit
-  (package-with-python2 python-prompt-toolkit))
+  (package-with-python2 python-prompt-toolkit-2))
 
 (define-public python-jedi
   (package
-- 
2.26.2





^ permalink raw reply	[flat|nested] 34+ messages in thread

* [bug#41395] [PATCH 2/3] gnu: Remove python-prompt-toolkit-1
  2020-05-26 11:41 ` [bug#41395] [PATCH 2/3] gnu: Remove python-prompt-toolkit-1 Edouard Klein
@ 2020-05-26 13:41   ` Edouard Klein
  2020-05-30 13:27     ` Marius Bakke
  2020-05-30 13:26   ` Marius Bakke
  1 sibling, 1 reply; 34+ messages in thread
From: Edouard Klein @ 2020-05-26 13:41 UTC (permalink / raw)
  To: 41395

Please disregard this patch, as it turns out that
python2-jupyter-console and python2-ipython still depend on
python2-prompt-toolkit-1.

My apologies for this mistake (and many thanks to Tobias for figuring it
out).

Edouard Klein writes:

> * gnu/packages/python-xyz.scm (python-prompt-toolkit-1): Remove variable.
> ---
>  gnu/packages/python-xyz.scm | 14 --------------
>  1 file changed, 14 deletions(-)
>
> diff --git a/gnu/packages/python-xyz.scm b/gnu/packages/python-xyz.scm
> index 76a1635b12..04cfb98eef 100644
> --- a/gnu/packages/python-xyz.scm
> +++ b/gnu/packages/python-xyz.scm
> @@ -12144,20 +12144,6 @@ characters, mouse support, and auto suggestions.")
>  (define-public python2-prompt-toolkit
>    (package-with-python2 python-prompt-toolkit))
>  
> -(define-public python-prompt-toolkit-1
> -  (package (inherit python-prompt-toolkit)
> -    (version "1.0.15")
> -    (source
> -     (origin
> -       (method url-fetch)
> -       (uri (pypi-uri "prompt_toolkit" version ".tar.gz"))
> -       (sha256
> -        (base32
> -         "05v9h5nydljwpj5nm8n804ms0glajwfy1zagrzqrg91wk3qqi1c5"))))))
> -
> -(define-public python2-prompt-toolkit-1
> -  (package-with-python2 python-prompt-toolkit-1))
> -
>  (define-public python-jedi
>    (package
>      (name "python-jedi")





^ permalink raw reply	[flat|nested] 34+ messages in thread

* [bug#41395] [PATCH] gnu: Update python-prompt-toolkit to version 3.0.5
  2020-05-19  9:53 [bug#41395] [PATCH 0/2] gnu: Add python-questionary Edouard Klein
                   ` (12 preceding siblings ...)
  2020-05-26 11:42 ` [bug#41395] [PATCH 3/3] gnu: Update python-prompt-toolkit to version 3.0.5 Edouard Klein
@ 2020-05-26 13:53 ` Edouard Klein
  2020-05-30 13:48   ` bug#41395: " Marius Bakke
  13 siblings, 1 reply; 34+ messages in thread
From: Edouard Klein @ 2020-05-26 13:53 UTC (permalink / raw)
  To: 41395


* gnu/packages/machine-learning.scm (python-iml): Pin implicit
python-prompt-toolkit dependency to version 2.

* gnu/packages/python-xyz.scm (python-widgetsnbextension): Pin implicit
python-prompt-toolkit dependency to version 2.
(python-ipywidgets): Update to version 7.5.1.
(python-ipywidgets): Pin implicit python-prompt-toolkit dependency to version
2.
(python-jupyter-console): Update to version 6.1.0.
(python-jupyter-console): Pin implicit python-prompt-toolkit dependency to
version 2.
(python-jupyter-console): Pin explicit python-prompt-toolkit dependency to
version 2.
(python-prompt-toolkit): Update to version 3.0.5.
(python-prompt-toolkit-2): New variable
(prompt-toolkit-2-instead-of-prompt-toolkit): New variable
(python2-prompt-toolkit): keep at version 2.
(python-prompt-toolkit-1): inherit from version 2.
---
 gnu/packages/machine-learning.scm |  3 +-
 gnu/packages/python-xyz.scm       | 49 +++++++++++++++++++++++--------
 2 files changed, 38 insertions(+), 14 deletions(-)

diff --git a/gnu/packages/machine-learning.scm b/gnu/packages/machine-learning.scm
index 17d01bc656..e26768267b 100644
--- a/gnu/packages/machine-learning.scm
+++ b/gnu/packages/machine-learning.scm
@@ -1817,7 +1817,8 @@ advanced research.")
          "1k8szlpm19rcwcxdny9qdm3gmaqq8akb4xlvrzyz8c2d679aak6l"))))
     (build-system python-build-system)
     (propagated-inputs
-     `(("ipython" ,python-ipython)
+     `(("ipython" ,(prompt-toolkit-2-instead-of-prompt-toolkit
+                    python-ipython))
        ("numpy" ,python-numpy)
        ("pandas" ,python-pandas)
        ("scipy" ,python-scipy)))
diff --git a/gnu/packages/python-xyz.scm b/gnu/packages/python-xyz.scm
index 76a1635b12..aea4d5aab6 100644
--- a/gnu/packages/python-xyz.scm
+++ b/gnu/packages/python-xyz.scm
@@ -8980,7 +8980,8 @@ interactive computing.")
          "1ismyaxbv9d56yqqqb8xl58hg0iq0bbyy014a53y1g3hfbc8g7q7"))))
     (build-system python-build-system)
     (propagated-inputs
-     `(("python-ipykernel" ,python-ipykernel)
+     `(("python-ipykernel"
+        ,(prompt-toolkit-2-instead-of-prompt-toolkit python-ipykernel))
        ("python-notebook" ,python-notebook)))
     (native-inputs
      `(("python-certifi" ,python-certifi)
@@ -9007,7 +9008,8 @@ notebooks.")
          "15sww2mvnkqlvx55gwa82v05062a8j1xpncnqna4k9sl53hgcig9"))))
     (build-system python-build-system)
     (propagated-inputs
-     `(("python-ipython" ,python-ipython)
+     `(("python-ipython" ,(prompt-toolkit-2-instead-of-prompt-toolkit
+                           python-ipython))
        ("python-traitlets" ,python-traitlets)
        ("python-widgetsnbextension" ,python-widgetsnbextension)))
     (native-inputs
@@ -9037,9 +9039,10 @@ in the data.")
          "06s3kr5vx0l1y1b7fxb04dmrppscl7q69sl9yyfr0d057d1ssvkg"))))
     (build-system python-build-system)
     (propagated-inputs
-     `(("python-ipykernel" ,python-ipykernel)
+     `(("python-ipykernel" ,(prompt-toolkit-2-instead-of-prompt-toolkit
+        python-ipykernel))
        ("python-jupyter-client" ,python-jupyter-client)
-       ("python-prompt-toolkit" ,python-prompt-toolkit)
+       ("python-prompt-toolkit" ,python-prompt-toolkit-2)
        ("python-pygments" ,python-pygments)))
     (native-inputs
      `(("python-nose" ,python-nose)))
@@ -12105,14 +12108,14 @@ collections of data.")
 (define-public python-prompt-toolkit
   (package
     (name "python-prompt-toolkit")
-    (version "2.0.7")
+    (version "3.0.5")
     (source
      (origin
        (method url-fetch)
-       (uri (pypi-uri "prompt_toolkit" version ".tar.gz"))
+       (uri (pypi-uri "prompt_toolkit" version))
        (sha256
         (base32
-         "0fgacqk73w7s932vy46pan2yp8rvjmlkag20xvaydh9mhf6h85zx"))))
+         "1j3x5s4gp4ih73sbcni0a0vffbzvrxbrbnkvb3fzjgxn810ilgan"))))
     (build-system python-build-system)
     (arguments
      `(#:phases
@@ -12126,12 +12129,11 @@ collections of data.")
              (add-installed-pythonpath inputs outputs)
              (invoke "py.test"))))))
     (propagated-inputs
-     `(("python-wcwidth" ,python-wcwidth)
-       ("python-six" ,python-six)
-       ("python-pygments" ,python-pygments)))
+     `(("python-wcwidth" ,python-wcwidth)))
     (native-inputs
      `(("python-pytest" ,python-pytest)))
-    (home-page "https://github.com/jonathanslenders/python-prompt-toolkit")
+    (home-page
+     "https://github.com/prompt-toolkit/python-prompt-toolkit")
     (synopsis "Library for building command line interfaces in Python")
     (description
      "Prompt-Toolkit is a library for building interactive command line
@@ -12141,11 +12143,32 @@ code completion, incremental search, support for Chinese double-width
 characters, mouse support, and auto suggestions.")
     (license license:bsd-3)))
 
+(define-public python-prompt-toolkit-2
+  (package (inherit python-prompt-toolkit)
+    (name "python-prompt-toolkit")
+    (version "2.0.7")
+    (source
+     (origin
+       (method url-fetch)
+       (uri (pypi-uri "prompt_toolkit" version ".tar.gz"))
+       (sha256
+        (base32
+         "0fgacqk73w7s932vy46pan2yp8rvjmlkag20xvaydh9mhf6h85zx"))))
+    (propagated-inputs
+     `(("python-wcwidth" ,python-wcwidth)
+       ("python-six" ,python-six)
+       ("python-pygments" ,python-pygments)
+       ("python-wcwidth" ,python-wcwidth)))))
+
+(define-public prompt-toolkit-2-instead-of-prompt-toolkit
+  (package-input-rewriting/spec
+   `(("python-prompt-toolkit" . ,(const python-prompt-toolkit-2)))))
+
 (define-public python2-prompt-toolkit
-  (package-with-python2 python-prompt-toolkit))
+  (package-with-python2 python-prompt-toolkit-2))
 
 (define-public python-prompt-toolkit-1
-  (package (inherit python-prompt-toolkit)
+  (package (inherit python-prompt-toolkit-2)
     (version "1.0.15")
     (source
      (origin
-- 
2.26.2




^ permalink raw reply	[flat|nested] 34+ messages in thread

* [bug#41395] [PATCH 3/3] gnu: Update python-prompt-toolkit to version 3.0.5
  2020-05-26 11:42 ` [bug#41395] [PATCH 3/3] gnu: Update python-prompt-toolkit to version 3.0.5 Edouard Klein
@ 2020-05-26 13:55   ` Edouard Klein
  0 siblings, 0 replies; 34+ messages in thread
From: Edouard Klein @ 2020-05-26 13:55 UTC (permalink / raw)
  To: 41395

Please disregard this one (as it is the one that follows the erroneous
deletion of python-prompt-toolkit-1), and use the one I just sent with
the same name instead.

Thanks in advance, and sorry for the mistake.


Edouard Klein writes:

> * gnu/packages/machine-learning.scm (python-iml): Pin implicit
> python-prompt-toolkit dependency to version 2.
>
> * gnu/packages/python-xyz.scm (python-widgetsnbextension): Pin implicit
> python-prompt-toolkit dependency to version 2.
> (python-ipywidgets): Update to version 7.5.1.
> (python-ipywidgets): Pin implicit python-prompt-toolkit dependency to version
> 2.
> (python-jupyter-console): Update to version 6.1.0.
> (python-jupyter-console): Pin implicit python-prompt-toolkit dependency to
> version 2.
> (python-jupyter-console): Pin explicit python-prompt-toolkit dependency to
> version 2.
> (python-prompt-toolkit): Update to version 3.0.5.
> (python-prompt-toolkit-2): New variable
> (prompt-toolkit-2-instead-of-prompt-toolkit): New variable
> (python2-prompt-toolkit): keep at version 2.
> ---
>  gnu/packages/machine-learning.scm |  3 +-
>  gnu/packages/python-xyz.scm       | 47 +++++++++++++++++++++++--------
>  2 files changed, 37 insertions(+), 13 deletions(-)
>
> diff --git a/gnu/packages/machine-learning.scm b/gnu/packages/machine-learning.scm
> index 17d01bc656..e26768267b 100644
> --- a/gnu/packages/machine-learning.scm
> +++ b/gnu/packages/machine-learning.scm
> @@ -1817,7 +1817,8 @@ advanced research.")
>           "1k8szlpm19rcwcxdny9qdm3gmaqq8akb4xlvrzyz8c2d679aak6l"))))
>      (build-system python-build-system)
>      (propagated-inputs
> -     `(("ipython" ,python-ipython)
> +     `(("ipython" ,(prompt-toolkit-2-instead-of-prompt-toolkit
> +                    python-ipython))
>         ("numpy" ,python-numpy)
>         ("pandas" ,python-pandas)
>         ("scipy" ,python-scipy)))
> diff --git a/gnu/packages/python-xyz.scm b/gnu/packages/python-xyz.scm
> index 04cfb98eef..e7d8c69472 100644
> --- a/gnu/packages/python-xyz.scm
> +++ b/gnu/packages/python-xyz.scm
> @@ -8980,7 +8980,8 @@ interactive computing.")
>           "1ismyaxbv9d56yqqqb8xl58hg0iq0bbyy014a53y1g3hfbc8g7q7"))))
>      (build-system python-build-system)
>      (propagated-inputs
> -     `(("python-ipykernel" ,python-ipykernel)
> +     `(("python-ipykernel"
> +        ,(prompt-toolkit-2-instead-of-prompt-toolkit python-ipykernel))
>         ("python-notebook" ,python-notebook)))
>      (native-inputs
>       `(("python-certifi" ,python-certifi)
> @@ -9007,7 +9008,8 @@ notebooks.")
>           "15sww2mvnkqlvx55gwa82v05062a8j1xpncnqna4k9sl53hgcig9"))))
>      (build-system python-build-system)
>      (propagated-inputs
> -     `(("python-ipython" ,python-ipython)
> +     `(("python-ipython" ,(prompt-toolkit-2-instead-of-prompt-toolkit
> +                           python-ipython))
>         ("python-traitlets" ,python-traitlets)
>         ("python-widgetsnbextension" ,python-widgetsnbextension)))
>      (native-inputs
> @@ -9037,9 +9039,10 @@ in the data.")
>           "06s3kr5vx0l1y1b7fxb04dmrppscl7q69sl9yyfr0d057d1ssvkg"))))
>      (build-system python-build-system)
>      (propagated-inputs
> -     `(("python-ipykernel" ,python-ipykernel)
> +     `(("python-ipykernel" ,(prompt-toolkit-2-instead-of-prompt-toolkit
> +        python-ipykernel))
>         ("python-jupyter-client" ,python-jupyter-client)
> -       ("python-prompt-toolkit" ,python-prompt-toolkit)
> +       ("python-prompt-toolkit" ,python-prompt-toolkit-2)
>         ("python-pygments" ,python-pygments)))
>      (native-inputs
>       `(("python-nose" ,python-nose)))
> @@ -12105,14 +12108,14 @@ collections of data.")
>  (define-public python-prompt-toolkit
>    (package
>      (name "python-prompt-toolkit")
> -    (version "2.0.7")
> +    (version "3.0.5")
>      (source
>       (origin
>         (method url-fetch)
> -       (uri (pypi-uri "prompt_toolkit" version ".tar.gz"))
> +       (uri (pypi-uri "prompt_toolkit" version))
>         (sha256
>          (base32
> -         "0fgacqk73w7s932vy46pan2yp8rvjmlkag20xvaydh9mhf6h85zx"))))
> +         "1j3x5s4gp4ih73sbcni0a0vffbzvrxbrbnkvb3fzjgxn810ilgan"))))
>      (build-system python-build-system)
>      (arguments
>       `(#:phases
> @@ -12126,12 +12129,11 @@ collections of data.")
>               (add-installed-pythonpath inputs outputs)
>               (invoke "py.test"))))))
>      (propagated-inputs
> -     `(("python-wcwidth" ,python-wcwidth)
> -       ("python-six" ,python-six)
> -       ("python-pygments" ,python-pygments)))
> +     `(("python-wcwidth" ,python-wcwidth)))
>      (native-inputs
>       `(("python-pytest" ,python-pytest)))
> -    (home-page "https://github.com/jonathanslenders/python-prompt-toolkit")
> +    (home-page
> +     "https://github.com/prompt-toolkit/python-prompt-toolkit")
>      (synopsis "Library for building command line interfaces in Python")
>      (description
>       "Prompt-Toolkit is a library for building interactive command line
> @@ -12141,8 +12143,29 @@ code completion, incremental search, support for Chinese double-width
>  characters, mouse support, and auto suggestions.")
>      (license license:bsd-3)))
>  
> +(define-public python-prompt-toolkit-2
> +  (package (inherit python-prompt-toolkit)
> +    (name "python-prompt-toolkit")
> +    (version "2.0.7")
> +    (source
> +     (origin
> +       (method url-fetch)
> +       (uri (pypi-uri "prompt_toolkit" version ".tar.gz"))
> +       (sha256
> +        (base32
> +         "0fgacqk73w7s932vy46pan2yp8rvjmlkag20xvaydh9mhf6h85zx"))))
> +    (propagated-inputs
> +     `(("python-wcwidth" ,python-wcwidth)
> +       ("python-six" ,python-six)
> +       ("python-pygments" ,python-pygments)
> +       ("python-wcwidth" ,python-wcwidth)))))
> +
> +(define-public prompt-toolkit-2-instead-of-prompt-toolkit
> +  (package-input-rewriting/spec
> +   `(("python-prompt-toolkit" . ,(const python-prompt-toolkit-2)))))
> +
>  (define-public python2-prompt-toolkit
> -  (package-with-python2 python-prompt-toolkit))
> +  (package-with-python2 python-prompt-toolkit-2))
>  
>  (define-public python-jedi
>    (package





^ permalink raw reply	[flat|nested] 34+ messages in thread

* [bug#41395] [PATCH 1/3] gnu: Update python-widgetsnbextension to 3.5.1
  2020-05-26  9:30 ` [bug#41395] [PATCH 1/3] gnu: Update python-widgetsnbextension to 3.5.1 Edouard Klein
@ 2020-05-30 13:16   ` Marius Bakke
  0 siblings, 0 replies; 34+ messages in thread
From: Marius Bakke @ 2020-05-30 13:16 UTC (permalink / raw)
  To: Edouard Klein, 41395

[-- Attachment #1: Type: text/plain, Size: 171 bytes --]

Edouard Klein <edk@beaver-labs.com> writes:

> * gnu/packages/python-xyz.scm (python-widgetsnbextension): Update to 3.5.1.

Applied (with a fixed commit message), thanks!

[-- Attachment #2: signature.asc --]
[-- Type: application/pgp-signature, Size: 487 bytes --]

^ permalink raw reply	[flat|nested] 34+ messages in thread

* [bug#41395] [PATCH 2/3] gnu: Update python-ipywidgets to 7.5.1
  2020-05-26  9:31 ` [bug#41395] [PATCH 2/3] gnu: Update python-ipywidgets to 7.5.1 Edouard Klein
@ 2020-05-30 13:18   ` Marius Bakke
  0 siblings, 0 replies; 34+ messages in thread
From: Marius Bakke @ 2020-05-30 13:18 UTC (permalink / raw)
  To: Edouard Klein, 41395

[-- Attachment #1: Type: text/plain, Size: 163 bytes --]

Edouard Klein <edk@beaver-labs.com> writes:

> * gnu/packages/python-xyz.scm (python-ipywidgets): Update to 7.5.1.

Applied (with a fixed commit message), thanks!

[-- Attachment #2: signature.asc --]
[-- Type: application/pgp-signature, Size: 487 bytes --]

^ permalink raw reply	[flat|nested] 34+ messages in thread

* [bug#41395] [PATCH 3/3] gnu: Update python-jupyter-console to 6.1.0
  2020-05-26  9:33 ` [bug#41395] [PATCH 3/3] gnu: Update python-jupyter-console to 6.1.0 Edouard Klein
@ 2020-05-30 13:19   ` Marius Bakke
  0 siblings, 0 replies; 34+ messages in thread
From: Marius Bakke @ 2020-05-30 13:19 UTC (permalink / raw)
  To: Edouard Klein, 41395

[-- Attachment #1: Type: text/plain, Size: 169 bytes --]

Edouard Klein <edk@beaver-labs.com> writes:

> * /gnu/packages/python-xyz.scm (python-jupyter-console): Update to 6.1.0.

Applied (with a fixed commit message), thanks!

[-- Attachment #2: signature.asc --]
[-- Type: application/pgp-signature, Size: 487 bytes --]

^ permalink raw reply	[flat|nested] 34+ messages in thread

* [bug#41395] [PATCH] gnu: Move nose from propagated to native in python-iml
  2020-05-26 11:21 ` [bug#41395] [PATCH] gnu: Move nose from propagated to native in python-iml Edouard Klein
@ 2020-05-30 13:21   ` Marius Bakke
  0 siblings, 0 replies; 34+ messages in thread
From: Marius Bakke @ 2020-05-30 13:21 UTC (permalink / raw)
  To: Edouard Klein, 41395

[-- Attachment #1: Type: text/plain, Size: 210 bytes --]

Edouard Klein <edk@beaver-labs.com> writes:

> * gnu/packages/machine-learning.scm (python-iml): Make python-nose
> a native input instead of a propagated input.

Applied (with a fixed commit message), thanks!

[-- Attachment #2: signature.asc --]
[-- Type: application/pgp-signature, Size: 487 bytes --]

^ permalink raw reply	[flat|nested] 34+ messages in thread

* [bug#41395] [PATCH 2/3] gnu: Remove python-prompt-toolkit-1
  2020-05-26 11:41 ` [bug#41395] [PATCH 2/3] gnu: Remove python-prompt-toolkit-1 Edouard Klein
  2020-05-26 13:41   ` Edouard Klein
@ 2020-05-30 13:26   ` Marius Bakke
  1 sibling, 0 replies; 34+ messages in thread
From: Marius Bakke @ 2020-05-30 13:26 UTC (permalink / raw)
  To: Edouard Klein, 41395

[-- Attachment #1: Type: text/plain, Size: 289 bytes --]

Edouard Klein <edk@beaver-labs.com> writes:

> * gnu/packages/python-xyz.scm (python-prompt-toolkit-1): Remove variable.

This also removes 'python2-prompt-toolkit-1' contrary to what the commit
message says.  Unfortunately that variable is still in use.  So I
skipped this patch for now.

[-- Attachment #2: signature.asc --]
[-- Type: application/pgp-signature, Size: 487 bytes --]

^ permalink raw reply	[flat|nested] 34+ messages in thread

* [bug#41395] [PATCH 2/3] gnu: Remove python-prompt-toolkit-1
  2020-05-26 13:41   ` Edouard Klein
@ 2020-05-30 13:27     ` Marius Bakke
  0 siblings, 0 replies; 34+ messages in thread
From: Marius Bakke @ 2020-05-30 13:27 UTC (permalink / raw)
  To: Edouard Klein, 41395

[-- Attachment #1: Type: text/plain, Size: 364 bytes --]

Edouard Klein <edou@rdklein.fr> writes:

> Please disregard this patch, as it turns out that
> python2-jupyter-console and python2-ipython still depend on
> python2-prompt-toolkit-1.
>
> My apologies for this mistake (and many thanks to Tobias for figuring it
> out).

Oh, I should learn to read the entire patch series instead of applying
them one-by-one...  :-P

[-- Attachment #2: signature.asc --]
[-- Type: application/pgp-signature, Size: 487 bytes --]

^ permalink raw reply	[flat|nested] 34+ messages in thread

* bug#41395: [PATCH] gnu: Update python-prompt-toolkit to version 3.0.5
  2020-05-26 13:53 ` [bug#41395] [PATCH] " Edouard Klein
@ 2020-05-30 13:48   ` Marius Bakke
  0 siblings, 0 replies; 34+ messages in thread
From: Marius Bakke @ 2020-05-30 13:48 UTC (permalink / raw)
  To: Edouard Klein, 41395-done

[-- Attachment #1: Type: text/plain, Size: 2186 bytes --]

Edouard Klein <edk@beaver-labs.com> writes:

> * gnu/packages/machine-learning.scm (python-iml): Pin implicit
> python-prompt-toolkit dependency to version 2.

I added a [propagated-inputs] here.

> * gnu/packages/python-xyz.scm (python-widgetsnbextension): Pin implicit
> python-prompt-toolkit dependency to version 2.

And here.

> (python-ipywidgets): Update to version 7.5.1.

And removed this.

> (python-ipywidgets): Pin implicit python-prompt-toolkit dependency to version
> 2.

[propagated-inputs]

> (python-jupyter-console): Update to version 6.1.0.

Removed.

> (python-jupyter-console): Pin implicit python-prompt-toolkit dependency to
> version 2.
> (python-jupyter-console): Pin explicit python-prompt-toolkit dependency to
> version 2.

Duplicate.

> (python-prompt-toolkit): Update to version 3.0.5.

I mentioned the changes to [home-page] and [propagated-inputs] here.

> (python-prompt-toolkit-2): New variable
> (prompt-toolkit-2-instead-of-prompt-toolkit): New variable
> (python2-prompt-toolkit): keep at version 2.
> (python-prompt-toolkit-1): inherit from version 2.

And added capitalizations and full stops here.

[...]

> +(define-public python-prompt-toolkit-2
> +  (package (inherit python-prompt-toolkit)
> +    (name "python-prompt-toolkit")
> +    (version "2.0.7")
> +    (source
> +     (origin
> +       (method url-fetch)
> +       (uri (pypi-uri "prompt_toolkit" version ".tar.gz"))
> +       (sha256
> +        (base32
> +         "0fgacqk73w7s932vy46pan2yp8rvjmlkag20xvaydh9mhf6h85zx"))))
> +    (propagated-inputs
> +     `(("python-wcwidth" ,python-wcwidth)
> +       ("python-six" ,python-six)
> +       ("python-pygments" ,python-pygments)
> +       ("python-wcwidth" ,python-wcwidth)))))

Duplicate wcwidth input (fixed).

> +(define-public prompt-toolkit-2-instead-of-prompt-toolkit
> +  (package-input-rewriting/spec
> +   `(("python-prompt-toolkit" . ,(const python-prompt-toolkit-2)))))

So this procedure is extremely greedy, and creates new derivations of
python-sphinx, python-cython and others for the affected packages.  Not
sure what's going on, but went ahead and applied it anyway.

The patches will be pushed shortly.  Thank you!

[-- Attachment #2: signature.asc --]
[-- Type: application/pgp-signature, Size: 487 bytes --]

^ permalink raw reply	[flat|nested] 34+ messages in thread

end of thread, back to index

Thread overview: 34+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2020-05-19  9:53 [bug#41395] [PATCH 0/2] gnu: Add python-questionary Edouard Klein
2020-05-19  9:58 ` [bug#41395] [PATCH 1/2] gnu: python-prompt-toolkit: Update to 3.0.5 Edouard Klein
2020-05-23 18:35   ` Marius Bakke
2020-05-25 10:52     ` Edouard Klein
2020-05-25 22:21       ` Marius Bakke
2020-05-26  9:28         ` Edouard Klein
2020-05-19  9:59 ` [bug#41395] [PATCH 2/2] gnu: Add python-questionary Edouard Klein
2020-05-23 18:39   ` Marius Bakke
2020-05-25 11:23     ` Edouard Klein
2020-05-25 11:24 ` [bug#41395] [PATCH 1/4] gnu: Update python-iml homepage to https Edouard Klein
2020-05-25 22:23   ` Marius Bakke
2020-05-25 11:26 ` [bug#41395] [PATCH 2/4] gnu: Update python-prompt-toolkit to version 3.0.5 Edouard Klein
2020-05-25 22:28   ` Marius Bakke
2020-05-26 11:39     ` Edouard Klein
2020-05-25 11:27 ` [bug#41395] [PATCH 3/4] gnu: Add python-pytest-pycodestyle Edouard Klein
2020-05-25 22:33   ` Marius Bakke
2020-05-25 11:28 ` [bug#41395] [PATCH 4/4] gnu: Add python-questionary Edouard Klein
2020-05-26  9:30 ` [bug#41395] [PATCH 1/3] gnu: Update python-widgetsnbextension to 3.5.1 Edouard Klein
2020-05-30 13:16   ` Marius Bakke
2020-05-26  9:31 ` [bug#41395] [PATCH 2/3] gnu: Update python-ipywidgets to 7.5.1 Edouard Klein
2020-05-30 13:18   ` Marius Bakke
2020-05-26  9:33 ` [bug#41395] [PATCH 3/3] gnu: Update python-jupyter-console to 6.1.0 Edouard Klein
2020-05-30 13:19   ` Marius Bakke
2020-05-26 11:21 ` [bug#41395] [PATCH] gnu: Move nose from propagated to native in python-iml Edouard Klein
2020-05-30 13:21   ` Marius Bakke
2020-05-26 11:40 ` [bug#41395] [PATCH 1/3] " Edouard Klein
2020-05-26 11:41 ` [bug#41395] [PATCH 2/3] gnu: Remove python-prompt-toolkit-1 Edouard Klein
2020-05-26 13:41   ` Edouard Klein
2020-05-30 13:27     ` Marius Bakke
2020-05-30 13:26   ` Marius Bakke
2020-05-26 11:42 ` [bug#41395] [PATCH 3/3] gnu: Update python-prompt-toolkit to version 3.0.5 Edouard Klein
2020-05-26 13:55   ` Edouard Klein
2020-05-26 13:53 ` [bug#41395] [PATCH] " Edouard Klein
2020-05-30 13:48   ` bug#41395: " Marius Bakke

unofficial mirror of guix-patches@gnu.org 

Archives are clonable:
	git clone --mirror https://yhetil.org/guix-patches/1 guix-patches/git/1.git

	# If you have public-inbox 1.1+ installed, you may
	# initialize and index your mirror using the following commands:
	public-inbox-init -V2 guix-patches guix-patches/ https://yhetil.org/guix-patches \
		guix-patches@gnu.org
	public-inbox-index guix-patches

Example config snippet for mirrors

Newsgroup available over NNTP:
	nntp://news.yhetil.org/yhetil.gnu.guix.patches


AGPL code for this site: git clone https://public-inbox.org/public-inbox.git