[racket-dev] Planet 2 Beta Release

From: Sam Tobin-Hochstadt (samth at ccs.neu.edu)
Date: Sun Dec 2 10:15:56 EST 2012

On Sat, Dec 1, 2012 at 10:56 AM, Jay McCarthy <jay.mccarthy at gmail.com> wrote:
> On Fri, Nov 30, 2012 at 7:09 PM, Matthew Flatt <mflatt at cs.utah.edu> wrote:
>> Version-specific installation
>> -----------------------------
>> Not to speak too much on Jay's behalf, but I think he isn't convinced
>> that the new default is right. If `--shared' is the default, then a
>> `raco pkg update' could be enough to get all your installed packages
>> working with a new version. If installation is instead
>> version-specific, then you have to reinstall every package that you use
>> whenever you upgrade.
>>
>> I think that if installation is all-version by default, then users who
>> are going to end up with bad configurations that they have trouble
>> repairing. A better way to deal with upgrades would be something like
>> `raco pkg migrate'.
>>
>> If we decide that version-specific is the right default to keep, and if
>> some would still like a more convenient way to manage all-version
>> packages, we could add an environment variable that makes `--shared'
>> the default.
>
> Something that bothers me a lot of P1 is that when I install an
> upgrade, I lose all my packages. This means that the documentation
> search suddenly starts returning different things, so I forget about
> which packages I had installed at all. I only discover this when I go
> to write something and have a long install and download process. Or,
> when I run a script I wrote a long time ago and it doesn't return
> instantly, but spawns an install.
>
> I'm much less worried about Racket versions breaking installed
> packages than Matthew. I don't think it is that common for core
> changes to break things and when it does happen, P2 is designed to
> easily allow you to upgrade all your packages to the latest versions,
> something that was very inconvenient with P1. I.e. you can do "raco
> pkg update --all", which isn't possible with P1.

I strongly agree with Jay here.  A few additional reasons, besides
what he explained:

 - The explanation "that package doesn't work with the latest Racket,
you need to update it" is easier for people to understand than "you
don't have that package installed, unless you do in which case you
should migrate it to your current version".  This is helped by the
fact that most other languages that I know of have all-version
installation.
 - Developer convenience is important, and most of us use git HEAD,
whose versions change quite rapidly.  Now following the version number
is very important, otherwise all your software will break.
 - Once many of the current collects move to packages, there will be
many fewer opportunities to break the behavior of the "core", so the
problems Matthew worries about will be less severe, and the problems
Jay and I worry about may be more severe.
 - Version-specific installation does not work well with
package-specific installation, which is something I hope we can add as
an option in the future.
 - One drawback of version-specific installation in Planet1 that I
experienced was that fixing an installed Planet package by editing the
source broke entirely when switching to a new version.  Relatedly,
version-specific install almost requires putting the installations in
an out-of-the-way directory, making finding and editing source more
difficult.

--
sam th
samth at ccs.neu.edu

Posted on the dev mailing list.