Bug 2971 - Node discovery enters infinite loop on pulling
Summary: Node discovery enters infinite loop on pulling
Status: RESOLVED FIXED
Alias: None
Product: Mercurial
Classification: Unclassified
Component: Mercurial (show other bugs)
Version: unspecified
Hardware: All All
: urgent bug
Assignee: Peter Arrenbrecht
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2011-08-25 09:41 UTC by Benjamin Pollack
Modified: 2011-09-08 14:00 UTC (History)
5 users (show)

See Also:
Python Version: ---


Attachments
(34 bytes, text/plain)
2011-08-25 09:41 UTC, Benjamin Pollack
Details
(34 bytes, text/plain)
2011-08-25 09:41 UTC, Benjamin Pollack
Details

Note You need to log in before you can comment on or make changes to this bug.
Description Benjamin Pollack 2011-08-25 09:41 UTC
Mercurial 1.9 appears to have entered an infinite loop on pulling, failing
to actually resolve what must be pulled.  The repository has 581 non-closed
heads, or 3138 counting closed ones.  I'm attaching both output from the
looping discovery sequence, and the output form the debugdag command.
Comment 1 Benjamin Pollack 2011-08-25 09:49 UTC
That should read 261 heads; my apologies.  The debugdag is correct.
Comment 2 Peter Arrenbrecht 2011-08-25 12:46 UTC
I can repro if I clone once all but the last head, then only the last head, 
then run discovery between the two. The problem is we always send the overall 
heads, instead of the heads of the remaining undecided region. Then this 
overall set fills up the sample of 200, since there are more than 200 in this 
repo, so we never proceed.

Incidentally, even with a fix for setdiscovery, treediscovery is more 
efficient here (1 vs. 6 roundtrips).
Comment 3 Peter Arrenbrecht 2011-08-25 13:37 UTC
Posted fix + test.
Comment 4 HG Bot 2011-09-08 14:00 UTC
Fixed by http://selenic.com/repo/hg/rev/c20688b7c061
Peter Arrenbrecht <peter.arrenbrecht@gmail.com>
setdiscovery: fix hang when #heads>200 (issue2971)

(please test the fix)
Comment 5 Bugzilla 2012-05-12 09:22 UTC

--- Bug imported by bugzilla@serpentine.com 2012-05-12 09:22 EDT  ---

This bug was previously known as _bug_ 2971 at http://mercurial.selenic.com/bts/issue2971
Imported an attachment (id=1577)
Imported an attachment (id=1578)