unofficial mirror of guix-devel@gnu.org 
 help / color / mirror / code / Atom feed
From: Efraim Flashner <efraim@flashner.co.il>
To: swedebugia@riseup.net
Cc: guix-devel <guix-devel@gnu.org>
Subject: Re: Trying to fix an error in the pypi-importer
Date: Thu, 31 Dec 2015 13:22:25 +0200	[thread overview]
Message-ID: <20151231132225.7737cf68@debian-netbook> (raw)
In-Reply-To: <da249e7466c012a9f8c4bbf3b6bc2a98@riseup.net>

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

On Wed, 30 Dec 2015 20:53:47 +0100
swedebugia@riseup.net wrote:

> Hi :)
> 
> I am trying to fix this error in the pypi-importer:
> 
> ~/src/guix$ ./pre-inst-env guix lint python-twisted
> gnu/packages/python.scm:6628:0: python-twisted-15.5.0: all the source 
> URIs are unreachable:
> gnu/packages/python.scm:6628:0: python-twisted-15.5.0: URI 
> https://pypi.python.org/packages/source/T/Twisted/Twisted-15.5.0.tar.gz 
> not reachable: 404 ("Not Found")
>  [...]  
> guix/build-system/python.scm:
> 
> (define (pypi-uri name version)
>    "Return a URI string for the Python package hosted on the Python 
> Package
> Index (PyPI) corresponding to NAME and VERSION."
>    (string-append "https://pypi.python.org/packages/source/"
>                   (string-take name 1) "/" name "/"
>                   name "-" version ".tar.gz"))
> 
> I read up on if-else with Guile and changed it to:
> (define (pypi-uri name version ending)
>    "Return a URI string for the Python package hosted on the Python 
> Package
> Index (PyPI) corresponding to NAME and VERSION."
>    (if (zero? ending)
>        (string-append "https://pypi.python.org/packages/source/"
>                   (string-take name 1) "/" name "/"
>                   name "-" version ".tar.gz"))
>    (else
>        (string-append "https://pypi.python.org/packages/source/"
>                   (string-take name 1) "/" name "/"
>                   name "-" version "." ending )))
> 
> Will this work?
> I did a make and got:
>    GUILEC guix/build-system/python.go
> guix/build-system/python.scm:51:2: warning: possibly unbound variable 
> `else'
> wrote `guix/build-system/python.go'
> 
> The goal was to change in a way that would not break all other calls to 
> the procedure pypi-uri.
> 
> Any thoughts?
> 
> * see https://pypi.python.org/pypi/Twisted/json
> 


does this also take care of the ones that are stored as name "-" version ".zip"?

-- 
Efraim Flashner   <efraim@flashner.co.il>   אפרים פלשנר
GPG key = A28B F40C 3E55 1372 662D  14F7 41AA E7DC CA3D 8351
Confidentiality cannot be guaranteed on emails sent or received unencrypted

[-- Attachment #2: OpenPGP digital signature --]
[-- Type: application/pgp-signature, Size: 819 bytes --]

  parent reply	other threads:[~2015-12-31 11:22 UTC|newest]

Thread overview: 13+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2015-12-30 19:53 Trying to fix an error in the pypi-importer swedebugia
     [not found] ` <56844BF3.10701@uq.edu.au>
2015-12-30 21:27   ` Ben Woodcroft
2015-12-30 22:00 ` Cyril Roelandt
2016-01-01 18:10   ` swedebugia
2016-01-02 17:10     ` swedebugia
2016-01-02 18:06       ` How to test changes to guix locally? (Was: Re: Trying to fix an error in the pypi-importer) swedebugia
2016-01-02 18:58         ` Ricardo Wurmus
2016-01-02 18:26       ` Trying to fix an error in the pypi-importer Erik Edrosa
2016-01-03 14:09       ` Ludovic Courtès
2016-01-03 16:29         ` swedebugia
2016-01-03 18:47       ` Ricardo Wurmus
2015-12-31 11:22 ` Efraim Flashner [this message]
2016-01-01 18:15   ` swedebugia

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=20151231132225.7737cf68@debian-netbook \
    --to=efraim@flashner.co.il \
    --cc=guix-devel@gnu.org \
    --cc=swedebugia@riseup.net \
    /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).