bug-guix
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

bug#42504: guix refresh --update fails for Rust packages


From: Alexandru-Sergiu Marton
Subject: bug#42504: guix refresh --update fails for Rust packages
Date: Fri, 24 Jul 2020 14:08:45 +0300
User-agent: Gnus/5.13 (Gnus v5.13) Emacs/26.3 (gnu/linux)

Danny Milosavljevic <dannym@scratchpost.org> writes:
> And guix repl says:
>
> scheme@(guix-user)> ,use (guix utils)
> scheme@(guix-user)> (file-extension 
> "https://crates.io/api/v1/crates/instant/0.1.2/download";)
> $1 = #f
>
> But the case #f is not handled in the code above--which is why it doesn't 
> work.
>
> Could you test the following fix?
>
> diff --git a/guix/upstream.scm b/guix/upstream.scm
> index 70cbfb45e8..31bd6faea4 100644
> --- a/guix/upstream.scm
> +++ b/guix/upstream.scm
> @@ -369,7 +369,7 @@ SOURCE, an <upstream-source>."
>       (let*-values (((archive-type)
>                      (match (and=> (package-source package) origin-uri)
>                        ((? string? uri)
> -                       (let ((type (file-extension (basename uri))))
> +                       (let ((type (or (file-extension (basename uri)) "")))
>                           ;; Sometimes we have URLs such as
>                           ;; "https://github.com/…/tarball/v0.1";, in which 
> case
>                           ;; we must not consider "1" as the extension.

This fixes the issue, thanks!

--
Sergiu





reply via email to

[Prev in Thread] Current Thread [Next in Thread]