unofficial mirror of guix-patches@gnu.org 
 help / color / mirror / code / Atom feed
From: Xinglu Chen <public@yoctocell.xyz>
To: 51108@debbugs.gnu.org
Subject: [bug#51108] [PATCH] import: pypi: Support 'input-changes'.
Date: Sat, 09 Oct 2021 12:21:15 +0200	[thread overview]
Message-ID: <b0e9d12e4b2f560c8d3f20d863ef30907291ec49.1633774845.git.public@yoctocell.xyz> (raw)

* guix/import/pypi.scm (latest-release): Specify the ‘input-changes’ field.
---
 guix/import/pypi.scm | 10 +++++++---
 1 file changed, 7 insertions(+), 3 deletions(-)

diff --git a/guix/import/pypi.scm b/guix/import/pypi.scm
index b7859c8341..52835cf44d 100644
--- a/guix/import/pypi.scm
+++ b/guix/import/pypi.scm
@@ -532,7 +532,8 @@ (define pypi-package?
 (define (latest-release package)
   "Return an <upstream-source> for the latest release of PACKAGE."
   (let* ((pypi-name    (guix-package->pypi-name package))
-         (pypi-package (pypi-fetch pypi-name)))
+         (pypi-package (pypi-fetch pypi-name))
+         (name (package-name package)))
     (and pypi-package
          (guard (c ((missing-source-error? c) #f))
            (let* ((info    (pypi-project-info pypi-package))
@@ -540,9 +541,12 @@ (define (latest-release package)
                   (url     (distribution-url
                             (latest-source-release pypi-package))))
              (upstream-source
-              (package (package-name package))
+              (package name)
               (version version)
-              (urls (list url))))))))
+              (urls (list url))
+              (input-changes
+               (changed-inputs name
+                               (pypi->guix-package pypi-name)))))))))
 
 (define %pypi-updater
   (upstream-updater

base-commit: fd8ea9abf5b4ded096b7ccadb5e36fde4bac0867
-- 
2.33.0







             reply	other threads:[~2021-10-09 10:22 UTC|newest]

Thread overview: 2+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2021-10-09 10:21 Xinglu Chen [this message]
2021-10-15 21:22 ` bug#51108: [PATCH] import: pypi: Support 'input-changes' Ludovic Courtès

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

  List information: https://guix.gnu.org/

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=b0e9d12e4b2f560c8d3f20d863ef30907291ec49.1633774845.git.public@yoctocell.xyz \
    --to=public@yoctocell.xyz \
    --cc=51108@debbugs.gnu.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
Code repositories for project(s) associated with this public inbox

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

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).