Danny Milosavljevic <dan...@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