-----BEGIN PGP SIGNED MESSAGE----- Hash: SHA1 On 3/23/2011 1:23 PM, Dirkjan Ochtman wrote: > On Wed, Mar 23, 2011 at 12:39, John Arbash Meinel > <j...@arbash-meinel.com> wrote: >> Just as an aside, and I might be wrong. But reading through what strip >> does, (and from my knowledge of the disk layout) it can't actually be >> atomic. So if you kill it at the wrong time, it will have corrupted your >> repository. >> >> At least, that is from what I can tell. Which is that it has to rewrite >> each file history to omit the revisions you are stripping, and then >> rewrite the revision history to do the same. It would be possible to be >> 'stable' if you wrote a write-ahead-log and did all the work on the >> side, and then any client that tries to read or write to the repository >> finishes up the steps. But the individual file histories refer to the >> global revision history (by index), so you don't have a 'top-down' view >> that makes it all atomic by changing the top level object to point to >> the new lower level objects. > > The reason that shouldn't happen is the ordering. If we strip the > changelog first (what you call the global revision history), other > clients won't be able to "find" the any file-level revisions only > referenced by the revision just stripped, so it should be atomic. > > Cheers, > > Dirkjan
http://mercurial.selenic.com/wiki/Strip Thats only true if you are stripping only from the top. According to the strip page, you also might re-order the numbers. Also, even with stripping the changelog first, it still leaves you with data in your repo that is going to suddenly think it is associated with the *next* commit you do. (So I make a change to 'foo.txt' commit it, then strip, the next commit I only change 'bar.txt'. If the strip was canceled 'hg log foo.txt' would include the latest revision as modifying foo.txt) John =:-> -----BEGIN PGP SIGNATURE----- Version: GnuPG v1.4.9 (Cygwin) Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org/ iEYEARECAAYFAk2J6dYACgkQJdeBCYSNAAMQMQCfXvD4dGOVV8LB9LmtMNqXeHys 5xkAoJBWAXXVbZcCKC1GXDPjUMSNbVtn =k1FG -----END PGP SIGNATURE----- _______________________________________________ Python-Dev mailing list Python-Dev@python.org http://mail.python.org/mailman/listinfo/python-dev Unsubscribe: http://mail.python.org/mailman/options/python-dev/archive%40mail-archive.com