DRAW: Voting Result Ends in Tie

Under situation:
 
  • Suffrage group members should vote for INIT stage.
  • But some nodes does offer the different INIT ballot,
  • The number of these nodes is over blocking number.
  • Timed out in a given time, each node fails to get enough ballots for INIT stage.
Expected actions:
 
  • Each node stops the current round and tries to start new round.
 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
# n2 and n3 will make ballot, which has wrong block hash when height, 13 and round, 0; previous round is 0.
nodes:
  n2:
    modules:
      ballot_maker:
        name: ConditionBallotMaker
        conditions:
          - condition: ballot.next_height="13" AND ballot.current_round=0 AND ballot.last_round=0 AND ballot.stage in ("INIT")
            actions:
              - action: random-next_block
  n3:
    modules:
      ballot_maker:
        name: ConditionBallotMaker
        conditions:
          - condition: ballot.next_height="13" AND ballot.current_round=0 AND ballot.last_round=0  AND ballot.stage in ("INIT")
            actions:
              - action: random-next_block
  
conditions:
  all:
    # base state
    - current_state="booting" AND new_state="joining"
    - current_state="joining" AND new_state="consensus"
  
    # got ACCEPT majority of block, 12
    - m="check majority" AND height="12" AND round=0 AND stage="ACCEPT" AND is_finished=true

    # got INIT majority of block, 13 and round, 0, but drew
    - m="check majority" AND height="13" AND round=0 AND stage="INIT" AND agreement="DRAW" AND is_finished=true

    # after failed, start next round of block, 12 with round 1
    - m="check majority" AND height="12" AND round=1 AND stage="INIT" AND agreement="MAJORITY" AND is_finished=true

    # got INIT majority of block, 13 and round, 0
    - m="check majority" AND height="13" AND round=0 AND stage="INIT" AND agreement="MAJORITY" AND is_finished=true
  
    # new block created for height, 13 and next round, 0
    - m="new block created" AND block.height="13" AND block.round=0
1
2
3
4
 $ ./contest run failure-voting-init-draw.yml \
     --log ./contest-failure-voting-init-draw
 $ echo $?
 0

This is the filtered majority checking messages:

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
$ cat ./contest-failure-voting-init-draw/n0.log | \
     grep -i 'check majority' | \
     jq -c '[.height, .round, .stage, .total, .threshold, .is_finished, .m]' | \
     column -s ',' -t
 ["12"  0  "ACCEPT"  4  3  false  "NOTYET"    "check majority"]
 ["12"  0  "ACCEPT"  4  3  false  "NOTYET"    "check majority"]
 ["12"  0  "ACCEPT"  4  3  true   "MAJORITY"  "check majority"]
 ["12"  0  "ACCEPT"  4  3  true   null        "check majority     but closed"]
 ["13"  0  "INIT"    4  3  false  "NOTYET"    "check majority"]
 ["13"  0  "INIT"    4  3  false  "NOTYET"    "check majority"]
 ["13"  0  "INIT"    4  3  true   "DRAW"      "check majority"]
 ["13"  0  "INIT"    4  3  true   null        "check majority     but closed"]
 ["12"  1  "INIT"    4  3  false  "NOTYET"    "check majority"]
 ["12"  1  "INIT"    4  3  false  "NOTYET"    "check majority"]
 ["12"  1  "INIT"    4  3  true   "MAJORITY"  "check majority"]
 ["12"  1  "INIT"    4  3  true   null        "check majority     but closed"]
 ["12"  1  "SIGN"    4  3  false  "NOTYET"    "check majority"]
 ["12"  1  "SIGN"    4  3  false  "NOTYET"    "check majority"]
 ["12"  1  "SIGN"    4  3  true   "MAJORITY"  "check majority"]
 ["12"  1  "SIGN"    4  3  true   null        "check majority     but closed"]
 ["12"  1  "ACCEPT"  4  3  false  "NOTYET"    "check majority"]
 ["12"  1  "ACCEPT"  4  3  false  "NOTYET"    "check majority"]
 ["12"  1  "ACCEPT"  4  3  true   "MAJORITY"  "check majority"]
 ["12"  1  "ACCEPT"  4  3  true   null        "check majority     but closed"]
 ["13"  0  "INIT"    4  3  false  "NOTYET"    "check majority"]
 ["13"  0  "INIT"    4  3  false  "NOTYET"    "check majority"]
 ["13"  0  "INIT"    4  3  true   "MAJORITY"  "check majority"]