[PATCH] progress: don't compute estimate without a total

Adrian Buehlmann adrian at cadifra.com
Thu Dec 16 08:07:21 CST 2010


On 2010-12-16 14:44, Augie Fackler wrote:
> On Dec 16, 2010, at 1:54 AM, Adrian Buehlmann wrote:
>>
>> On 2010-12-16 05:05, Augie Fackler wrote:
>>> # HG changeset patch
>>> # User Augie Fackler <durin42 at gmail.com>
>>> # Date 1292472327 21600
>>> # Node ID 3b79ee2fca7d1f00d4fef7164e8d6e88f42c0dfe
>>> # Parent  94507fd06ebc1516d4141a411cb27ec7534fa3a9
>>> progress: don't compute estimate without a total
>>>
>>> Without this, computing an estimate explodes gloriously. Test
>>> included.
>>
>> A word like 'explode' might be funny for some people in a mailing list
>> post or in IRC chat, but IMHO it shouldn't be used in change message
>> text, tests or code.
>>
>> I assume you mean: 'fails with a traceback'?
> 
> I don't understand why you think it so inappropriate, I've seen it used not infrequently in this context. That said, I don't feel strongly so I'll resend.

Thanks.

Well, it left me slightly puzzled for a second how a progress bar might
possibly explode. Until I read the code change.

But I see now that we already have one precedent:

$ hg log -r "keyword('explode')"
changeset:   2569:52ce0d6bc375
parent:      2567:2748253b49c2
user:        Alexis S. L. Carvalho <...>
date:        Thu Jul 06 03:14:55 2006 -0300
summary:     HTTPS: fix python2.3, persistent connections, don't explode
if SSL is not available

But crash is definitely more frequent in mercurial's history

$ hg log -qr "keyword('crash')"
1877:d314a89fa4f1
4638:3c7fc13c4bfa
5611:60bd4e707a7d
7692:a55de9e2726f
7950:9bbcfa898cd3
8057:2a4cb1d509ec
8171:4e5bd9b97bb3
8249:2c7c973c2abd
8255:ea82a23cf887
8788:5d8021ac0e19
9366:9ff178e7b627
9417:4c3fb45123e5
9428:5d6659cfaa06
9469:7f0f882af23d
9993:8bce1e0d2801
10475:2253715fde97
10530:ed87b6c60e0b
11346:e740f36cfb4b
11448:25430ff23cfa
11451:51021f4c80b5
11638:79231258503b
11778:7e5f5e5858f9
11835:14db59e3b248
12028:21984c1c83d4
12068:2e7647d25458
12069:7c3c44413bc1
12748:d10369fefd01
13038:670f4e98276d
13039:dd24f3e7ca9e


More information about the Mercurial-devel mailing list