[RFC] Change to use 'merge_sort' for per-file-log
Vincent Ladeuil
v.ladeuil+lp at free.fr
Mon Sep 22 15:30:51 BST 2008
>>>>> "robert" == Robert Collins <robertc at robertcollins.net> writes:
robert> On Mon, 2008-09-22 at 12:07 +0200, Vincent Ladeuil wrote:
robert> vila *must* have modified 'bzr' in his feature branch
robert> for this to happen.
>>
>> === modified file bzr
>> --- bzr 2008-08-29 19:32:00 +0000
>> +++ bzr 2008-09-10 04:54:57 +0000
>> @@ -22,7 +22,7 @@
>> import sys
>>
>> # update this on each release
>> -_script_version = (1, 7, 0)
>> +_script_version = (1, 8, 0)
>>
>> if __doc__ is None:
>> print "bzr does not support python -OO."
>>
>>
>> This modification is a direct consequence of the merge, so not
>> strictly added by vila (and I don't thank John for associating me
>> with noise-only revisions :).
robert> Check the per-file graph; if your merge commits are
robert> recording changes to it, there must be (arbitrarily
robert> far back) a change that *you made* and which hasn't
robert> been merged to bzr.dev. (see the commit_builder
robert> per-repository tests to understand this).
Thanks, wonderful pointer. I tried it and find the results below
(correction welcome if I'm wrong again :).
robert> (the per-file graph has nodes that are a subset of
robert> the revision graph nodes, but its _not_ a
robert> subgraph. It can have arcs that the revision graph
robert> doesn't, and can skip arcs the revision graph has.)
robert> So I think we must really show it
>>
>> Hmmm. That's really noise. In fact redoing 'bzr log bzr' today
>> will show you several such revisions introducing that same change
>> (7 -> 8) because they are all merges from bzr.dev.
robert> If its noise, there is a bug I think.
I think John fixed it:
bzr branch lp:bzr -r 3677.1.6 ploum-ploum
cd ploum-ploum
old log:
=======
vila:~/src/bzr/experimental/ploum-ploum :) $ bzr log bzr --limit 5
------------------------------------------------------------
revno: 3683
committer: Vincent Ladeuil <v.ladeuil+lp at free.fr>
branch nick: 233817-missing
timestamp: Thu 2008-09-11 21:36:38 +0200
message:
merge bzr.dev
------------------------------------------------------------
revno: 3677.19.8
committer: John Arbash Meinel <john at arbash-meinel.com>
branch nick: sftp_chunked
timestamp: Wed 2008-09-10 12:33:01 -0500
message:
Merge in bzr.dev 3698
------------------------------------------------------------
revno: 3677.18.5
committer: John Arbash Meinel <john at arbash-meinel.com>
branch nick: per_tests_239343
timestamp: Wed 2008-09-10 14:13:43 -0500
message:
Merge bzr.dev, resolve NEWS
------------------------------------------------------------
revno: 3677.1.21
committer: Canonical.com Patch Queue Manager <pqm at pqm.ubuntu.com>
branch nick: +trunk
timestamp: Wed 2008-09-10 06:33:34 +0100
message:
(jam) Merge in bzr-1.7rc1, open bzr-1.8 for development.
------------------------------------------------------------
revno: 3677.16.1
committer: John Arbash Meinel <john at arbash-meinel.com>
branch nick: jam-integration
timestamp: Tue 2008-09-09 23:54:57 -0500
message:
Merge in bzr 1.7rc1, open 1.8 for development
new log:
========
../../reviews/lighter_file_log3/bzr log bzr --limit 5
------------------------------------------------------------
revno: 3683
committer: Vincent Ladeuil <v.ladeuil+lp at free.fr>
branch nick: 233817-missing
timestamp: Thu 2008-09-11 21:36:38 +0200
message:
merge bzr.dev
------------------------------------------------------------
revno: 3677.1.21
committer: Canonical.com Patch Queue Manager <pqm at pqm.ubuntu.com>
branch nick: +trunk
timestamp: Wed 2008-09-10 06:33:34 +0100
message:
(jam) Merge in bzr-1.7rc1, open bzr-1.8 for development.
------------------------------------------------------------
revno: 3677.16.1
committer: John Arbash Meinel <john at arbash-meinel.com>
branch nick: jam-integration
timestamp: Tue 2008-09-09 23:54:57 -0500
message:
Merge in bzr 1.7rc1, open 1.8 for development
------------------------------------------------------------
revno: 3667
committer: Canonical.com Patch Queue Manager <pqm at pqm.ubuntu.com>
branch nick: +trunk
timestamp: Fri 2008-08-29 22:40:33 +0100
message:
(jam) Merge bzr-1.6.1rc1
------------------------------------------------------------
revno: 3665.2.1
committer: John Arbash Meinel <john at arbash-meinel.com>
branch nick: jam-integration
timestamp: Fri 2008-08-29 14:32:00 -0500
message:
Merge in 1.6.1rc1
In the old log, revnos 3677.19.8 and 3677.18.5 tried to show the
same modification than 3677.16.1 introduced.
The revids involved are:
- 3683 v.ladeuil+lp at free.fr-20080911193638-wtjyc1kcmacc6t1f
- 3677.19.8 john at arbash-meinel.com-20080910173301-niz0pw3mcat430o1
- 3677.18.5 john at arbash-meinel.com-20080910191343-1wbziepei5ufnk9z
- 3677.1.21 pqm at pqm.ubuntu.com-20080910053334-fy7gihd6da2nyhy2
- 3677.16.1 john at arbash-meinel.com-20080910045457-abzebw04q75dtprs
vila:~/src/bzr/experimental/ploum-ploum :) $ python
Python 2.5.2 (r252:60911, Jul 31 2008, 17:28:52)
[GCC 4.2.3 (Ubuntu 4.2.3-2ubuntu7)] on linux2
Type "help", "copyright", "credits" or "license" for more information.
>>> import bzrlib
>>> from bzrlib import workingtree
>>> from bzrlib import graph
>>> tr, rp = workingtree.WorkingTree.open_containing(u'.')
>>> tr.lock_read()
>>> list(graph.Graph(tr.branch.repository.texts).iter_ancestry([(tr.path2id('bzr'), 'v.ladeuil+lp at free.fr-20080911193638-wtjyc1kcmacc6t1f')]))
[(('bzr.py-20050313053754-5485f144c7006fa6', 'v.ladeuil+lp at free.fr-20080911193638-wtjyc1kcmacc6t1f'), None)]
>>> list(graph.Graph(tr.branch.repository.texts).iter_ancestry([(tr.path2id('bzr'), 'john at arbash-meinel.com-20080910173301-niz0pw3mcat430o1')]))
[(('bzr.py-20050313053754-5485f144c7006fa6', 'john at arbash-meinel.com-20080910173301-niz0pw3mcat430o1'), None)]
>>> list(graph.Graph(tr.branch.repository.texts).iter_ancestry([(tr.path2id('bzr'), 'john at arbash-meinel.com-20080910191343-1wbziepei5ufnk9z')]))
[(('bzr.py-20050313053754-5485f144c7006fa6', 'john at arbash-meinel.com-20080910191343-1wbziepei5ufnk9z'), None)]
>>> list(graph.Graph(tr.branch.repository.texts).iter_ancestry([(tr.path2id('bzr'), 'pqm at pqm.ubuntu.com-20080910053334-fy7gihd6da2nyhy2')]))
[(('bzr.py-20050313053754-5485f144c7006fa6', 'pqm at pqm.ubuntu.com-20080910053334-fy7gihd6da2nyhy2'), None)]
>>> list(graph.Graph(tr.branch.repository.texts).iter_ancestry([(tr.path2id('bzr'), 'john at arbash-meinel.com-20080910045457-abzebw04q75dtprs')]))[0:2]
[(('bzr.py-20050313053754-5485f144c7006fa6', 'john at arbash-meinel.com-20080910045457-abzebw04q75dtprs'), (('bzr.py-20050313053754-5485f144c7006fa6', 'john at arbash-meinel.com-20080829193200-wdvz1vr3sgga1tp9'),)), (('bzr.py-20050313053754-5485f144c7006fa6', 'john at arbash-meinel.com-20080829193200-wdvz1vr3sgga1tp9'), (('bzr.py-20050313053754-5485f144c7006fa6', 'john at arbash-meinel.com-20080813225155-t914z2fqyi072dd4'), ('bzr.py-20050313053754-5485f144c7006fa6', 'john at arbash-meinel.com-20080829163911-ckm9kugdug9dcmct')))]
>>>
AIUI, that means that the per-file graph is correct but John's
proposal associates it with less revisions, keeping the one that
really introduces the change and the ones present on the "first"
path to the trunk via the merges, whereas, previously, we were
showing it for all merges on all paths to the trunk.
At that point I wonder if the per log file shouldn't go one step
further and shows only 3677.16.1 which is what annotate does.
Vincent
More information about the bazaar
mailing list