[racket-dev] info.rkt `deps` and new #:version keyword: Backward compatibility?

From: Matthew Flatt (mflatt at cs.utah.edu)
Date: Thu Oct 3 09:48:15 EDT 2013

Yes, the `#:version` keyword is optional. The old format, as in

 (define deps '(("markdown" "0.5")
                "rackjure"))

is still supported.

The old format is described as "deprecated" in the documentation, but
it's fine to use it to support both v5.3.x and v.5.90.x.

At Thu, 3 Oct 2013 09:40:56 -0400, Greg Hendershott wrote:
> After I gave my Frog talk at RacketCon, in which I said a goal of Frog
> was to make it easy to install, J. Ian Johnson tried to install it...
> but couldn't.
> 
> As best I understand, it's because he was using Racket from HEAD, and
> at some point recently the `deps` expression for info.rkt changed for
> the case where you specify a version. A case which I've been using
> (recent versions of Frog need a >= version of Markdown).
> 
> For 5.3.6 and (until fairly recently in HEAD) it was:
> 
> # frog/info.rkt
> #lang setup/infotab
> (define version "0.7")
> (define collection 'multi)
> (define deps '(("markdown" "0.5")
>                "rackjure"))
> 
> But it recently changed to require a #:version keyword, therefore it
> would have to be IIUC this for 5.3.900.???+:
> 
> # frog/info.rkt
> #lang setup/infotab
> (define version "0.7")
> (define collection 'multi)
> (define deps '(("markdown" #:version "0.5")
>                "rackjure"))
> 
> But that wouldn't be compatible with 5.3.6 IIUC.
> 
> As a result I would have to maintain two different packages, one for
> 5.3.5 and 5.3.6, and another for 5.3.900.???+ and greater (yuck).
> 
> Until now, even the major change to single-collection defaults was
> done in a way that preserved backward compatibility (well, after
> taking action to add `(define collection 'multi)`, but after taking
> such action the same info.rkt works for old and new).
> 
> 1. Am I understanding it correctly?  (Not a rhetorical question; I
> have a lot of "IIUC"s above.)
> 
> 2. If so, is it really the intent to break backward compatibility?
> 
> 3. Instead couldn't the #version keyword simply be optional?
> _________________________
>   Racket Developers list:
>   http://lists.racket-lang.org/dev

Posted on the dev mailing list.