Bug 3977 - Incorrect way to count revisions
Summary: Incorrect way to count revisions
Status: RESOLVED FIXED
Alias: None
Product: Mercurial
Classification: Unclassified
Component: hgweb (show other bugs)
Version: unspecified
Hardware: All All
: normal bug
Assignee: Bugzilla
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2013-07-04 13:33 UTC by Alexander Plavin
Modified: 2013-08-01 23:57 UTC (History)
5 users (show)

See Also:
Python Version: ---


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Alexander Plavin 2013-07-04 13:33 UTC
In hgweb log and graph views have a limit on the amount of revisions displayed at once. But this limit is calculated in an incorrect (at least from a user point of view) way: by the revision numbers instead of their actual amount. This causes displaying only few last revisions, if other (not hidden) ones have numbers which differ a lot: i.e. if you have revisions with numbers 1,2,3,1000,1001, then by default you will see only the last two of them.
Comment 1 Augie Fackler 2013-07-24 20:36 UTC
I can't reproduce this on the log view, but I just mailed a patch for the graph view.
Comment 2 HG Bot 2013-07-25 03:45 UTC
Fixed by http://selenic.com/repo/hg/rev/002b711a3e8a
Alexander Plavin <me@aplavin.ru>
hgweb: fix incorrect way to count revisions in log (issue3977)

Actual amount of revisions is used now instead of their numbers in the repo
before to deal with skipped numbers correctly.
This iterates starting from the newest revision (which is shown on top)
yielding up to the specified count, instead of the reversed order used before.
Effect of this change on efficiency is negligible, when the same changesets are
returned.

(please test the fix)
Comment 3 HG Bot 2013-07-25 03:45 UTC
Fixed by http://selenic.com/repo/hg/rev/8cfa3a3664a5
Alexander Plavin <me@aplavin.ru>
hgweb: fix incorrect revisions count in graph (issue3977)

Actual amount of revisions is used now instead of their numbers in the repo
before to deal with skipped numbers correctly.

(please test the fix)