Re: [Haskell-cafe] Make your Darcs repositories hashed?

2010-10-12 Thread Eric Kow
Hey Haskellers (and darcs-users CC'ed)

On Sat, Oct 09, 2010 at 23:08:12 +, Jason Dagit wrote:
 I answered you immediate question in a different email.  Now I'll do a bit
 of explanation on why people want hashed.

Thanks to Jason for the explanation.

I've linked to it from http://wiki.darcs.net/RepositoryFormats so that
we'll have an easier time in the future encouraging people to move to
the hashed format.

Also: If you don't have darcs 2.4.4, you can upgrade to the hashed
format by doing:

  cd /srv/code/myrepo 
  darcs get . ~/myrepo-hashed 

  rm -rf ~/myrepo-hashed/_darcs/prefs 
  cp -R _darcs/prefs ~/myrepo-hashed/_darcs/prefs 

  mv ~/myrepo-hashed/_darcs _darcs.new 
  mv _darcs _darcs.old
  mv _darcs.new _darcs 

  rm -rf ~/myrepo-hashed 
  rm -rf _darcs.old

I may put this on the wiki. We had pruned this sort of thing away in
favour of the optimize --upgrade command, in the interest of tidiness,
but getting recent Darcs into people's hands takes a while.

Also, the maintainers behind code.haskell.org are aware about the need
for a Darcs 2.4.4 upgrade (I filed a request on 15 Sep).  We're looking
into an easy way to do this on Debian Etch.

See also

* http://wiki.darcs.net/RepositoryFormats
  The three formats in a nutshell

* http://wiki.darcs.net/DarcsTwo#hashed-repository-format
  More about hashed repositories (covers a lot of the same stuff Jason did)

* http://lists.osuosl.org/pipermail/darcs-users/2010-August/024941.html
  Discussion on eventually retiring support for old-fashioned repositories

  I can guarantee that at least Darcs 2.5 (the upcoming release) will
  continue to provide full support for old-fashioned repositories. But
  they are going away eventually so that we can focus on making Darcs
  better.

Thanks!

-- 
Eric Kow http://www.nltg.brighton.ac.uk/home/Eric.Kow
For a faster response, try +44 (0)1273 64 2905 or
xmpp:ko...@jabber.fr (Jabber or Google Talk only)


signature.asc
Description: Digital signature
___
Haskell-Cafe mailing list
Haskell-Cafe@haskell.org
http://www.haskell.org/mailman/listinfo/haskell-cafe


[Haskell-cafe] Make your Darcs repositories hashed?

2010-10-09 Thread Christopher Done
Every Darcs repository I've pulled this year has always showed me this message:

***
Fetching a hashed repository would be faster.  Perhaps you could persuade
the maintainer to run darcs optimize --upgrade with darcs 2.4.0 or higher?
***

Maintainers! Please run darcs optimize --upgrade
___
Haskell-Cafe mailing list
Haskell-Cafe@haskell.org
http://www.haskell.org/mailman/listinfo/haskell-cafe


Re: [Haskell-cafe] Make your Darcs repositories hashed?

2010-10-09 Thread Roel van Dijk
The darcs installed on code.haskell.org is still version 2.02. It
doesn't know about 'optimize --upgrade'. How do I upgrade those
repositories?

On Sat, Oct 9, 2010 at 2:30 PM, Christopher Done
chrisd...@googlemail.com wrote:
 Every Darcs repository I've pulled this year has always showed me this 
 message:

 ***
 Fetching a hashed repository would be faster.  Perhaps you could persuade
 the maintainer to run darcs optimize --upgrade with darcs 2.4.0 or higher?
 ***

 Maintainers! Please run darcs optimize --upgrade
___
Haskell-Cafe mailing list
Haskell-Cafe@haskell.org
http://www.haskell.org/mailman/listinfo/haskell-cafe


Re: [Haskell-cafe] Make your Darcs repositories hashed?

2010-10-09 Thread Brandon S Allbery KF8NH
-BEGIN PGP SIGNED MESSAGE-
Hash: SHA1

On 10/9/10 08:30 , Christopher Done wrote:
 Every Darcs repository I've pulled this year has always showed me this 
 message:
 
 ***
 Fetching a hashed repository would be faster.  Perhaps you could persuade
 the maintainer to run darcs optimize --upgrade with darcs 2.4.0 or higher?
 ***

The problem with this message is that it knows that *you* have a darcs that
can take advantage of it, but no way to know if other users of the
repository can (or, for that matter, if the repository is managed by a
capable version of darcs).

- -- 
brandon s. allbery [linux,solaris,freebsd,perl]  allb...@kf8nh.com
system administrator  [openafs,heimdal,too many hats]  allb...@ece.cmu.edu
electrical and computer engineering, carnegie mellon university  KF8NH
-BEGIN PGP SIGNATURE-
Version: GnuPG v2.0.10 (Darwin)
Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org/

iEYEARECAAYFAkyw52oACgkQIn7hlCsL25XbLACg0SE1NAbQKkKYY5pCQWQxRJLy
noQAoNRlwRCDC78R2Sroo5rq1GkX59+L
=FcxO
-END PGP SIGNATURE-
___
Haskell-Cafe mailing list
Haskell-Cafe@haskell.org
http://www.haskell.org/mailman/listinfo/haskell-cafe


Re: [Haskell-cafe] Make your Darcs repositories hashed?

2010-10-09 Thread Jason Dagit
On Sat, Oct 9, 2010 at 3:06 PM, Brandon S Allbery KF8NH allb...@ece.cmu.edu
 wrote:

 -BEGIN PGP SIGNED MESSAGE-
 Hash: SHA1

 On 10/9/10 08:30 , Christopher Done wrote:
  Every Darcs repository I've pulled this year has always showed me this
 message:
 
 
 ***
  Fetching a hashed repository would be faster.  Perhaps you could persuade
  the maintainer to run darcs optimize --upgrade with darcs 2.4.0 or
 higher?
 
 ***

 The problem with this message is that it knows that *you* have a darcs that
 can take advantage of it, but no way to know if other users of the
 repository can (or, for that matter, if the repository is managed by a
 capable version of darcs).


Welcome to the world of distributed computing :)  In general, you can't
really tell what others are doing with their copies of the repository.  It's
both good and bad.

Newer darcs clients are compatible with repos created with older darcs
clients and using the newer client will not interfere with using the older
clients on that repo.  In other words: It's safe to use the newer clients.
 So you can think of your repo as being managed by the latest stable release
if you like.

The Haskell.org server doesn't have to be upgraded. Maintainers can install
a newer darcs locally (cabal install darcs), do the upgrade locally and then
copy the repository back to the haskell.org server.  Or, if
haskell.orgservers upgrade their copy of darcs, or you install newer
darcs in your home
dir, you can do the upgrade in-pace.

Some things to keep in mind:
  * Darcs 2.4.4 is perfectly backwards compatible with older darcs and older
repos.
  * cabal install makes upgrading/installing darcs painfree.
  * Newer darcs has fewer bugs and the performance continues to improve as
well[1].

The over arching theme is:  It is safe to upgrade your darcs client and you
shoud upgrade your darcs client.

If you have specific questions or concerns, I'd recommend asking on the
darcs-users mailing list[2].

Thanks,
Jason

[1] If you poke around on this page following links you can get a feeling
for how performance changes between releases:
http://wiki.darcs.net/Benchmarks  2.4.4 is a solid release.
[2] http://lists.osuosl.org/mailman/listinfo/darcs-users
___
Haskell-Cafe mailing list
Haskell-Cafe@haskell.org
http://www.haskell.org/mailman/listinfo/haskell-cafe


Re: [Haskell-cafe] Make your Darcs repositories hashed?

2010-10-09 Thread Brent Yorgey
On Sat, Oct 09, 2010 at 03:43:42PM -0700, Jason Dagit wrote:
 
 The Haskell.org server doesn't have to be upgraded. Maintainers can install
 a newer darcs locally (cabal install darcs), do the upgrade locally and then
 copy the repository back to the haskell.org server.  

Really?  But then the version of darcs on code.haskell.org wouldn't be
able to read those repositories, which would cause darcs over ssh to
fail -- wouldn't it?  Or am I missing something?

-Brent
___
Haskell-Cafe mailing list
Haskell-Cafe@haskell.org
http://www.haskell.org/mailman/listinfo/haskell-cafe


Re: [Haskell-cafe] Make your Darcs repositories hashed?

2010-10-09 Thread Jason Dagit
On Sat, Oct 9, 2010 at 8:52 PM, Brent Yorgey byor...@seas.upenn.edu wrote:

 On Sat, Oct 09, 2010 at 03:43:42PM -0700, Jason Dagit wrote:
 
  The Haskell.org server doesn't have to be upgraded. Maintainers can
 install
  a newer darcs locally (cabal install darcs), do the upgrade locally and
 then
  copy the repository back to the haskell.org server.

 Really?  But then the version of darcs on code.haskell.org wouldn't be
 able to read those repositories, which would cause darcs over ssh to
 fail -- wouldn't it?  Or am I missing something?


You'd be fine.  I tried to make this clear by saying:
Some things to keep in mind:
  * Darcs 2.4.4 is perfectly backwards compatible with older darcs and older
repos.

In particular, the manual[1] says:
The --upgrade option for darcs optimize performs an inplace upgrade of your
repository to the latest compatible format. Right now means that darcs 1
old-fashioned repositories will be upgraded to darcs-1 hashed repositories
(and notably, not to darcs 2 repositories as that would not be compatible;
see darcs convert).

Jason

[1] http://darcs.net/manual/node7.html#SECTION00784000
___
Haskell-Cafe mailing list
Haskell-Cafe@haskell.org
http://www.haskell.org/mailman/listinfo/haskell-cafe


Re: [Haskell-cafe] Make your Darcs repositories hashed?

2010-10-09 Thread Jason Dagit
On Sat, Oct 9, 2010 at 8:52 PM, Brent Yorgey byor...@seas.upenn.edu wrote:

 On Sat, Oct 09, 2010 at 03:43:42PM -0700, Jason Dagit wrote:
 
  The Haskell.org server doesn't have to be upgraded. Maintainers can
 install
  a newer darcs locally (cabal install darcs), do the upgrade locally and
 then
  copy the repository back to the haskell.org server.

 Really?  But then the version of darcs on code.haskell.org wouldn't be
 able to read those repositories, which would cause darcs over ssh to
 fail -- wouldn't it?  Or am I missing something?


I answered you immediate question in a different email.  Now I'll do a bit
of explanation on why people want hashed.

I should also mention that darcs 2.0.2 (which is the version on c.h.o) does
read darcs 2 repositories as support for that feature exists in all darcs
2.x clients.

And I personally think that c.h.o should be upgraded to darcs 2.4.4, but
that issue is orthogonal to the issue of getting maintainers to upgrade to
hashed format repos.

Darcs currently has 3 options for repo formats:
  * old fashioned
  * darcs 1 hashed
  * darcs 2 hashed

The old fashioned format will eventually be removed as it's not as robust or
safe as the hashed variants.  The big difference between darcs 1 hashed and
darcs 2 hashed is how patches behave when commuted.  The darcs 2 hashed
variant is a refinement that better handles some corner cases that result
from conflicts.  Something like 90% of the code in darcs is shared between
darcs 1 hashed and darcs 2 hashed.

The hashed formats are more robust because:
  * the hashes guard against accidental modification of patches that are
stored on disk
  * the hashes guard against a buggy darcs client that misapplies patches
(the hashes would be off, git has similar safe guards)
  * the hashed formats have better atomicity and hence better transactional
properties

If you try the hashed format and find it unpleasant for any reason it's
something to report as a bug.  We really want (and need) people to switch to
hashed, so if it's not good enough we need to know why so we can fix it.

Jason
___
Haskell-Cafe mailing list
Haskell-Cafe@haskell.org
http://www.haskell.org/mailman/listinfo/haskell-cafe