[Rd] Suggestion: Make CRAN source URLs immutable

Iñaki Ucar iuc@r @ending from fedor@project@org
Fri Nov 2 17:42:09 CET 2018


On Wed, 24 Oct 2018 at 11:40, Kurt Hornik <Kurt.Hornik using wu.ac.at> wrote:
>
> >>>>> Kurt Wheeler writes:
>
> Try e.g.
>
> https://cran.r-project.org/package=httr&version=1.3.1
> https://cran.r-project.org/package=httr&version=1.3.0

This is a nice feature that I didn't know. I recently proposed
enforcing this scheme in Fedora's packaging guidelines, because in
this way, a SPEC would build correctly even if the package was updated
and the old version was archived (is this guaranteed to continue to
work in future? I assumed so...).

There is an odd thing about this format though, and that is the
absence of a file extension. This is a redirection, yes, but the
spectool can't trust the filename that is sent by the remote server,
and uses only the filename extracted from the URL.

Without extension, RPM doesn't know how to unpack the sources. So we
have to do the following similarly odd trick (note the "#"):

Source0: https://cran.r-project.org/package=%{packname}&version=%{version}#/%{packname}_%{version}.tar.gz

Did you consider this problem? Is there any alternate immutable URL
*with* extension? If not, is there any potential issue with the trick
above?

Regards,
--
Iñaki Ucar



More information about the R-devel mailing list