Patchwork Fix typo in repoview.changelog

login
register
mail settings
Submitter Mike Hommey
Date Aug. 31, 2014, 10:57 a.m.
Message ID <1751a7952a4c4b8bd5eb.1409482643@build.glandium.org>
Download mbox | patch
Permalink /patch/5674/
State Accepted
Headers show

Comments

Mike Hommey - Aug. 31, 2014, 10:57 a.m.
# HG changeset patch
# User Mike Hommey <mh@glandium.org>
# Date 1409481783 -32400
# Node ID 1751a7952a4c4b8bd5eb11ef6ac9966d33cb1f8c
# Parent  188b8aa2120b03eead618ba150319074f4e3b42b
Fix typo in repoview.changelog

Incidentally, this avoids the changelog cache to be invalidated each time
it's accessed on a repoview.

On a filtering experiment on a repository the size of mozilla-central,
this makes a significant difference:

Before, running hg log -l 10 --time with about 8k changesets filtered out:
time: real 1.490 secs (user 1.450+0.000 sys 0.040+0.000)

After:
time: real 0.540 secs (user 0.530+0.000 sys 0.010+0.000)
Matt Mackall - Sept. 1, 2014, 9:10 p.m.
On Sun, 2014-08-31 at 19:57 +0900, Mike Hommey wrote:
> # HG changeset patch
> # User Mike Hommey <mh@glandium.org>
> # Date 1409481783 -32400
> # Node ID 1751a7952a4c4b8bd5eb11ef6ac9966d33cb1f8c
> # Parent  188b8aa2120b03eead618ba150319074f4e3b42b
> Fix typo in repoview.changelog

I've queued this for stable as it seems to be a worthwhile bugfix.
Congratulations on your first Mercurial patch.

(contrib/check-commit has some advice for you on our standard summary
line format, but I'm in a hurry to cut a release.)
Matt Mackall - Sept. 1, 2014, 9:11 p.m.
On Sun, 2014-08-31 at 19:57 +0900, Mike Hommey wrote:
> # HG changeset patch
> # User Mike Hommey <mh@glandium.org>
> # Date 1409481783 -32400
> # Node ID 1751a7952a4c4b8bd5eb11ef6ac9966d33cb1f8c
> # Parent  188b8aa2120b03eead618ba150319074f4e3b42b
> Fix typo in repoview.changelog

I've queued this for stable as it seems to be a worthwhile bugfix.
Congratulations on your first Mercurial patch.

(contrib/check-commit has some advice for you on our standard summary
line format, but I'm in a hurry to cut a release.)

Patch

diff -r 188b8aa2120b -r 1751a7952a4c mercurial/repoview.py
--- a/mercurial/repoview.py	Sat Aug 30 18:44:59 2014 +0200
+++ b/mercurial/repoview.py	Sun Aug 31 19:43:03 2014 +0900
@@ -287,7 +287,7 @@ 
             # without change in the cachekey.
             oldfilter = cl.filteredrevs
             try:
-                cl.filterrevs = ()  # disable filtering for tip
+                cl.filteredrevs = ()  # disable filtering for tip
                 curkey = (len(cl), cl.tip(), hash(oldfilter))
             finally:
                 cl.filteredrevs = oldfilter