all messages for Guix-related lists mirrored at yhetil.org
 help / color / mirror / code / Atom feed
* [bug#39447] [PATCH] gnu: Add python-gandi.cli.
@ 2020-02-06  3:13 Amin Bandali
  2020-02-13 22:25 ` Ludovic Courtès
                   ` (2 more replies)
  0 siblings, 3 replies; 7+ messages in thread
From: Amin Bandali @ 2020-02-06  3:13 UTC (permalink / raw)
  To: 39447; +Cc: Amin Bandali

* gnu/packages/python-xyz.scm (python-gandi.cli): 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 dcc1595446..2472890dae 100644
--- a/gnu/packages/python-xyz.scm
+++ b/gnu/packages/python-xyz.scm
@@ -69,6 +69,7 @@
 ;;; Copyright © 2019 Tanguy Le Carrour <tanguy@bioneland.org>
 ;;; Copyright © 2019 Mădălin Ionel Patrașcu <madalinionel.patrascu@mdc-berlin.de>
 ;;; Copyright © 2020 Jakub Kądziołka <kuba@kadziolka.net>
+;;; Copyright © 2020 Amin Bandali <mab@gnu.org>
 ;;;
 ;;; This file is part of GNU Guix.
 ;;;
@@ -17467,3 +17468,35 @@ extensive support of PNG features.  It can also read and write Netpbm PAM
 files, with a focus on its use as an intermediate format for implementing
 custom PNG processing.")
     (license license:expat)))
+
+(define-public python-gandi.cli
+  (package
+    (name "python-gandi.cli")
+    (version "1.5")
+    (source
+     (origin
+       (method url-fetch)
+       (uri (pypi-uri "gandi.cli" version))
+       (sha256
+        (base32
+         "110wc9zgxsrvw4yzp21p0ian5lcf7vhcpxhnmsc4fg9pzl2bwxd5"))))
+    (build-system python-build-system)
+    (propagated-inputs
+     `(("git" ,git)
+       ("openssh" ,openssh)
+       ("openssl" ,openssl)
+       ("python-click" ,python-click)
+       ("python-ipy" ,python-ipy)
+       ("python-pyyaml" ,python-pyyaml)
+       ("python-requests" ,python-requests)
+       ("python-setuptools" ,python-setuptools)))
+    (native-inputs
+     `(("python-pytest" ,python-pytest)
+       ("python-pytest-cov" ,python-pytest-cov)
+       ("python-tox" ,python-tox)))
+    (home-page "https://github.com/Gandi/gandi.cli")
+    (synopsis "Gandi command line interface")
+    (description "Gandi CLI is a command line interface for creating and
+managing Gandi.net products (domains, certificates, servers, etc) using
+Gandi's public API.")
+    (license license:gpl3+)))
-- 
2.25.0

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

* [bug#39447] [PATCH] gnu: Add python-gandi.cli.
  2020-02-06  3:13 [bug#39447] [PATCH] gnu: Add python-gandi.cli Amin Bandali
@ 2020-02-13 22:25 ` Ludovic Courtès
  2020-02-13 23:25 ` bug#39447: " Tobias Geerinckx-Rice via Guix-patches via
  2020-03-11  3:54 ` Useless gandi.cli (was: [bug#39447] [PATCH] gnu: Add python-gandi.cli.) Tobias Geerinckx-Rice
  2 siblings, 0 replies; 7+ messages in thread
From: Ludovic Courtès @ 2020-02-13 22:25 UTC (permalink / raw)
  To: Amin Bandali; +Cc: 39447

Hi,

Amin Bandali <mab@gnu.org> skribis:

> * gnu/packages/python-xyz.scm (python-gandi.cli): New variable.

LGTM, thanks!

Ludo’.

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

* bug#39447: [PATCH] gnu: Add python-gandi.cli.
  2020-02-06  3:13 [bug#39447] [PATCH] gnu: Add python-gandi.cli Amin Bandali
  2020-02-13 22:25 ` Ludovic Courtès
@ 2020-02-13 23:25 ` Tobias Geerinckx-Rice via Guix-patches via
  2020-03-11  3:54 ` Useless gandi.cli (was: [bug#39447] [PATCH] gnu: Add python-gandi.cli.) Tobias Geerinckx-Rice
  2 siblings, 0 replies; 7+ messages in thread
From: Tobias Geerinckx-Rice via Guix-patches via @ 2020-02-13 23:25 UTC (permalink / raw)
  To: 39447-close, Amin Bandali

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

Amin,

Amin Bandali 写道:
> * gnu/packages/python-xyz.scm (python-gandi.cli): New variable.

Thanks!  This package is already in Guix as ‘gandi.cli’ — we avoid 
the ‘python-’ prefix for stand-alone programmes since being 
written in Python (or any other language) is irrelevant.

+    (propagated-inputs
+     `(("git" ,git)
+       ("openssh" ,openssh)
+       ("openssl" ,openssl)
+       ("python-click" ,python-click)
+       ("python-ipy" ,python-ipy)
+       ("python-pyyaml" ,python-pyyaml)
+       ("python-requests" ,python-requests)
+       ("python-setuptools" ,python-setuptools)))

Propagation should be avoided when possible, although it's (sadly) 
more common in Python packages than elsewhere.

However, propagating inputs like git, openssh, openssl, 
python-setuptools… is definitely wrong.  Was this deliberate? 
Which problem were you trying to solve?  Take a look at 
gandi.cli's ‘embed-store-file-names’ for a different approach that 
avoids propagation altogether.

I'm closing this bug, but please let me know if the existing 
gandi.cli is missing features.  I added it but haven't used it in 
a while.

Kind regards,

T G-R

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

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

* Useless gandi.cli (was: [bug#39447] [PATCH] gnu: Add python-gandi.cli.)
  2020-02-06  3:13 [bug#39447] [PATCH] gnu: Add python-gandi.cli Amin Bandali
  2020-02-13 22:25 ` Ludovic Courtès
  2020-02-13 23:25 ` bug#39447: " Tobias Geerinckx-Rice via Guix-patches via
@ 2020-03-11  3:54 ` Tobias Geerinckx-Rice
  2020-03-17  8:06   ` Giovanni Biscuolo
  2 siblings, 1 reply; 7+ messages in thread
From: Tobias Geerinckx-Rice @ 2020-03-11  3:54 UTC (permalink / raw)
  To: Amin Bandali; +Cc: help-guix mailing list

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

Amin,

Amin Bandali 写道:
> * gnu/packages/python-xyz.scm (python-gandi.cli): New variable.

Does it do anything for you?  After reading the issue tracker it's 
clear to me that gandi.cli is unusable and unmaintained.  I'd love 
to be proven wrong.

Here ‘gandi domain list’ returns ‘Invalid API key, please use 
'gandi setup' command’ no matter what I do.  All non-trivial 
operations require an old XMLRPC key which isn't ever possible to 
generate nowadays[0].

Kind regards,

T G-R

[0]: 
https://github.com/Gandi/gandi.cli/issues/292#issuecomment-560370741

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

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

* Re: Useless gandi.cli (was: [bug#39447] [PATCH] gnu: Add python-gandi.cli.)
  2020-03-11  3:54 ` Useless gandi.cli (was: [bug#39447] [PATCH] gnu: Add python-gandi.cli.) Tobias Geerinckx-Rice
@ 2020-03-17  8:06   ` Giovanni Biscuolo
  2020-03-17 10:52     ` Tobias Geerinckx-Rice
  0 siblings, 1 reply; 7+ messages in thread
From: Giovanni Biscuolo @ 2020-03-17  8:06 UTC (permalink / raw)
  To: Tobias Geerinckx-Rice, Amin Bandali; +Cc: help-guix mailing list

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

Hello Tobias,

sorry for the late reply

Tobias Geerinckx-Rice <me@tobias.gr> writes:

> Amin,
>
> Amin Bandali 写道:
>> * gnu/packages/python-xyz.scm (python-gandi.cli): New variable.
>
> Does it do anything for you?  After reading the issue tracker it's 
> clear to me that gandi.cli is unusable and unmaintained.  I'd love 
> to be proven wrong.
>
> Here ‘gandi domain list’ returns ‘Invalid API key, please use 
> 'gandi setup' command’ no matter what I do.  All non-trivial 
> operations require an old XMLRPC key which isn't ever possible to 
> generate nowadays[0].
>
> Kind regards,
>
> T G-R
>
> [0]: 
> https://github.com/Gandi/gandi.cli/issues/292#issuecomment-560370741

I'm not a regular user of gandi.cli (hope I will) so I've not tested all
the features now, but it is working for me

You have to use Gandi V4 customer web interface to get the "legacy"
XMLRPC API key and it worked for me, done 3 minutes ago

https://v4.gandi.net/admin/api_key

They are planning to close the v4 customer web interface, I hope they
will fix this before... but fortunately it's still working

HTH! Gio'

-- 
Giovanni Biscuolo

Xelera IT Infrastructures

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

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

* Re: Useless gandi.cli (was: [bug#39447] [PATCH] gnu: Add python-gandi.cli.)
  2020-03-17  8:06   ` Giovanni Biscuolo
@ 2020-03-17 10:52     ` Tobias Geerinckx-Rice
  2020-03-18 15:36       ` Giovanni Biscuolo
  0 siblings, 1 reply; 7+ messages in thread
From: Tobias Geerinckx-Rice @ 2020-03-17 10:52 UTC (permalink / raw)
  To: Giovanni Biscuolo; +Cc: help-guix mailing list

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

Giovanni,

Giovanni Biscuolo 写道:
> sorry for the late reply

No, thank you for your reply :-)

> You have to use Gandi V4 customer web interface to get the 
> "legacy"
> XMLRPC API key and it worked for me, done 3 minutes ago
>
> https://v4.gandi.net/admin/api_key

I'd love to, but that doesn't work for everyone anymore:

  Account already migrated
  This account has already been migrated to Gandi's new 
  website. […]

That message is new.  When I opened this bug a week ago, logging 
into V4 still broke IceCat with a redirect loop, with no 
indication of what went wrong.  I haven't changed or updated my 
browser since.

> They are planning to close the v4 customer web interface, I hope 
> they
> will fix this before... but fortunately it's still working

I'm glad to hear it's still working for you, at least, and I 
suspect someone who really needs the CLI could ask support for an 
XMLRPC key.  That's enough to keep it in Guix.  It was not enough 
to keep me with Gandi.

Kind regards,

T G-R

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

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

* Re: Useless gandi.cli (was: [bug#39447] [PATCH] gnu: Add python-gandi.cli.)
  2020-03-17 10:52     ` Tobias Geerinckx-Rice
@ 2020-03-18 15:36       ` Giovanni Biscuolo
  0 siblings, 0 replies; 7+ messages in thread
From: Giovanni Biscuolo @ 2020-03-18 15:36 UTC (permalink / raw)
  To: Tobias Geerinckx-Rice; +Cc: help-guix mailing list

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

Tobias Geerinckx-Rice <me@tobias.gr> writes:

[...]

>> https://v4.gandi.net/admin/api_key
>
> I'd love to, but that doesn't work for everyone anymore:
>
>   Account already migrated
>   This account has already been migrated to Gandi's new 
>   website. […]

Mumble... actually I don't know why but I'm able to log in in V4 (using
the "legacy" handle") and V5

> That message is new.  When I opened this bug a week ago, logging 
> into V4 still broke IceCat with a redirect loop, with no 
> indication of what went wrong.  I haven't changed or updated my 
> browser since.

The joy of web interfaces :-S

>> They are planning to close the v4 customer web interface, I hope 
>> they
>> will fix this before... but fortunately it's still working
>
> I'm glad to hear it's still working for you

ehrm, ehrm: actually I never used gandi.cli and I'm testing it in my
spare time

1. the legacy "gandi domain list" just lists the domanins of my "legacy"
v4 handle

2. "gandi dns domain.list" (the v5 equivalent) gives an empty list

3. curl -H "Authorization: Apikey $GANDI_APIKEY" https://api.gandi.net/v5/domain/domains
gives me the complete list (that means the domains in all the organizations I'm part of)

> at least, and I suspect someone who really needs the CLI could ask
> support for an XMLRPC key.  That's enough to keep it in Guix.  It was
> not enough to keep me with Gandi.

gandi.cli needs more love:

1. https://github.com/Gandi/gandi.cli/issues/279
Unable to manage domains migrated to Gandi-V5

2. https://github.com/Gandi/gandi.cli/issues/288 (Order domain name via API V5)

and probably also the API:

1. https://github.com/Gandi/gandi.cli/issues/285
dns update command reports "Remote API service is unreachable"

that bugs are still open, they made some commits since the 1.5 release
but AFAIU by a quick look at the code that ploblems are still open (and
probably upgrading gandi.cli to a newer commit won't enhance the
situation)

[...]

Ciao, Gio'

-- 
Giovanni Biscuolo

Xelera IT Infrastructures

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

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

end of thread, other threads:[~2020-03-18 15:37 UTC | newest]

Thread overview: 7+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2020-02-06  3:13 [bug#39447] [PATCH] gnu: Add python-gandi.cli Amin Bandali
2020-02-13 22:25 ` Ludovic Courtès
2020-02-13 23:25 ` bug#39447: " Tobias Geerinckx-Rice via Guix-patches via
2020-03-11  3:54 ` Useless gandi.cli (was: [bug#39447] [PATCH] gnu: Add python-gandi.cli.) Tobias Geerinckx-Rice
2020-03-17  8:06   ` Giovanni Biscuolo
2020-03-17 10:52     ` Tobias Geerinckx-Rice
2020-03-18 15:36       ` Giovanni Biscuolo

Code repositories for project(s) associated with this external index

	https://git.savannah.gnu.org/cgit/guix.git

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.