Transcript for #bitcoin-dev 2017/07/16

15:17 molz mmgen, how do you set the block version to signal for bit 1?
15:28 mmgen molz: with the -blockversion switch
15:28 mmgen molz: you have to use an integer, not hex
15:29 mmgen molz: works only in regtest mode of course
15:30 molz mmgen, so you run the client with -blockversion=1 ?
15:30 molz sorry i have no clue, but i'm curious
15:33 mmgen molz: no, versionbits is a bit map. 0x20000002 is signaling on bit 1. Use the integer value of that
15:35 mmgen molz: versionbits is described in BIP9
15:35 molz right, what i'm trying to understand is how do you set the bit in regtest
15:37 molz mmgen, how did you do this: "<mmgen> I first set the block version to signal for bit 1"
15:37 mmgen I just told you how
15:38 mmgen convert that hex value to an int and use that as your argument
15:38 molz ok thanks, i'll have to ask someone else, sorry i'm such a noob
16:11 mmgen molz: since no one's stepped up to the plate, looks like I'll have to spell it out for you:
16:11 molz mmgen, i got it, thanks :)
16:11 molz i'm doing it now
16:12 mmgen Figured it out?
16:12 mmgen Run the client with -blockversion=<integer value of the hex I gave you>
16:13 mmgen You can convert the hex using Python
16:17 molz so at the beginning i got "defined", and after mining 144 blocks i got "started"
16:18 molz how many blocks does it take to get "lock-in"?
16:19 arubi I /think/ that by block 421 it should activate
16:19 arubi unless this signal from block 1 makes a difference, not sure
16:19 arubi I didn't think bip9 was active on regtest right from the beginning
16:22 molz arubi it doesn't
16:23 molz im thinking 2016 blocks
16:25 molz oh hm just mined 144 blocks again and segwit got 'lock-in'
16:25 arubi molz, 432
16:25 arubi bip9_softforks": {
16:25 arubi "csv": {
16:25 arubi "status": "active",
16:25 arubi "startTime": 0,
16:25 arubi "timeout": 999999999999,
16:25 arubi "since": 432
16:25 arubi },
16:25 arubi "segwit": {
16:25 arubi "status": "active",
16:26 arubi "startTime": 0,
16:26 arubi "timeout": 999999999999,
16:26 arubi "since": 432
16:36 mmgen You're right, it becomes active automatically around block 500
16:36 mmgen No signaling is required
16:38 mmgen s/500/432/
16:39 mmgen That's too easy, in my opinion
16:42 arubi you can set it with -bip9params=deployment:start:end
16:42 mmgen arubi: ok
16:43 mmgen Yes, the client is signaling on its own:
16:43 mmgen UpdateTip: new best=5b29f39f47b89315f00b51f729c732a51c0d45409875b9bfbbc27eef5f24c570 height=300 version=0x30000003
16:43 mmgen for csv and segwit
16:44 mmgen but why 0x30?
16:44 arubi it should, like it does on mainnet
16:45 arubi not sure really. pretty weird
16:49 mmgen s/432/431/
16:49 arubi mine say UpdateTip: new best=377c7964bc3c939e7e39ea6a2082917651b3bfd5cfb32ccdfa3ac7bb507a4591 height=438 version=0x20000000 log2_work=9.7780771 tx=439 date='16 20' progress=1.000000 cache=0.1MiB(438tx)
16:49 arubi and version=0x20000004 when the MAST client generates
16:50 mmgen UpdateTip: new best=001f59da4e7f2ece7301cec69cd8d443c7b4de803f6435448e7a0582d31d4061 height=431 version=0x30000003
16:50 mmgen UpdateTip: new best=2af894f9a2d7bb7072bbb5ccbf239f7bbcefc66c0666453df4f7e31c780d6d11 height=432 version=0x20000000
16:51 mmgen It stops signaling right after activation
16:51 arubi which version is that?
16:51 mmgen 0.14.1
16:51 arubi ohh I think it signals for both csv and segwit at the same time
16:52 mmgen Yes, hence the version=0x30000003
16:53 mmgen that's bits 1 and 2
16:53 mmgen counting from zero
16:53 arubi right, I forgot csv is activated at the same time and only expected to see segwit's signal at bit 1
16:53 arubi yes
16:53 arubi hence I now realize csv is probably on bit 2 :)
16:55 mmgen s/is/was/
16:55 arubi now what's bip 9's 011 on MSB means
16:56 mmgen good question. we don't see that on mainnet
16:59 arubi so I guess bit 27 is what we see on mainnet and bit 28 is the testdummy bit
17:00 arubi oof: consensus.BIP65Height = 1351; // BIP65 activated on regtest (Used in rpc activation tests)
17:00 arubi consensus.BIP66Height = 1251; // BIP66 activated on regtest (Used in rpc activation tests)
17:00 arubi I did not know these were so far off bip9 activations
17:02 arubi yep, it actually takes so many :)