public inbox for bitcoindev@googlegroups.com
 help / color / mirror / Atom feed
* [Bitcoin-development] Testnet3 difficulty transition problem?
@ 2012-12-22 18:39 Andreas Schildbach
       [not found] ` <CAAS2fgQKidxKmJ47oDi80YZrTW_MrVYf_u_tcZtO+xv2o+8S+w@mail.gmail.com>
  0 siblings, 1 reply; 3+ messages in thread
From: Andreas Schildbach @ 2012-12-22 18:39 UTC (permalink / raw)
  To: bitcoin-development

Both blocks

38304 00000000015bb4069249fa1f41ae61d8a7447aaacc33c50dacd3c3654377fa43

and

40320 000000008011f56b8c92ff27fb502df5723171c5374673670ef0eee3696aee6d

are difficulty transition blocks. However, block 40320 has a difficulty
of 1. I know there is this special testnet rule that allows mining a
block at difficulty 1, but I always thought you can't use this exception
on difficulty transition blocks.

As a result, bitcoinj based clients do not advance their blockchain past
block 40319.




^ permalink raw reply	[flat|nested] 3+ messages in thread

* [Bitcoin-development] Testnet3 difficulty transition problem?
       [not found] ` <CAAS2fgQKidxKmJ47oDi80YZrTW_MrVYf_u_tcZtO+xv2o+8S+w@mail.gmail.com>
@ 2012-12-22 18:45   ` Gregory Maxwell
  2012-12-24 16:21     ` Mike Hearn
  0 siblings, 1 reply; 3+ messages in thread
From: Gregory Maxwell @ 2012-12-22 18:45 UTC (permalink / raw)
  To: Bitcoin Development

On Sat, Dec 22, 2012 at 1:39 PM, Andreas Schildbach
<andreas@schildbach•de> wrote:
> Both blocks
>
> 38304 00000000015bb4069249fa1f41ae61d8a7447aaacc33c50dacd3c3654377fa43
>
> and
>
> 40320 000000008011f56b8c92ff27fb502df5723171c5374673670ef0eee3696aee6d
>
> are difficulty transition blocks. However, block 40320 has a difficulty
> of 1. I know there is this special testnet rule that allows mining a
> block at difficulty 1,

Yes.

> but I always thought you can't use this exception
> on difficulty transition blocks.

Not so— but what you're actually seeing is that difficult change is
relative to the prior block's difficulty. E.g. if the penultimate
block in the difficulty cycle is under the special rule the difficulty
change will be relative to 1.

(I had intentionally avoided triggering that test case when adding the
timewarp attack to the testnet chain in case we had wanted to fix it
prior to testnet3's release— I guess I should have added it sooner in
order to catch the bitcoinj misbehavior!)



^ permalink raw reply	[flat|nested] 3+ messages in thread

* Re: [Bitcoin-development] Testnet3 difficulty transition problem?
  2012-12-22 18:45   ` Gregory Maxwell
@ 2012-12-24 16:21     ` Mike Hearn
  0 siblings, 0 replies; 3+ messages in thread
From: Mike Hearn @ 2012-12-24 16:21 UTC (permalink / raw)
  To: Gregory Maxwell; +Cc: Bitcoin Development

I pushed a fix for this.



^ permalink raw reply	[flat|nested] 3+ messages in thread

end of thread, other threads:[~2012-12-24 16:21 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2012-12-22 18:39 [Bitcoin-development] Testnet3 difficulty transition problem? Andreas Schildbach
     [not found] ` <CAAS2fgQKidxKmJ47oDi80YZrTW_MrVYf_u_tcZtO+xv2o+8S+w@mail.gmail.com>
2012-12-22 18:45   ` Gregory Maxwell
2012-12-24 16:21     ` Mike Hearn

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox