-
Notifications
You must be signed in to change notification settings - Fork 63
Open
Description
From @sbellem on August 26, 2017 0:57
@amiller I assume you are well aware of this as there's already a TODO
note in the code about implementing the random selection.
Nevertheless, regardless of the size, only one element (tx_to_send[0]
) is currently passed to _run_round()
:
class HoneyBadgerBFT():
# ...
def run(self):
# ...
while True:
# ...
# Select all the transactions (TODO: actual random selection)
tx_to_send = self.transaction_buffer[:self.B]
# Run the round
send_r = _make_send(r)
recv_r = self._per_round_recv[r].get
new_tx = self._run_round(r, tx_to_send[0], send_r, recv_r)
So _run_round()
and tpke.encrypt()
should be capable to take a list
or a similar data structure.
tpke.encrypt()
would need to be modified so that a string (e.g.: cPickle.dumps(raw)
) is passed to the padding operation.
So this issue could be done in two (or three) parts:
- Pass a list to
_run_round()
, e.g.:tx_to_send[:1]
- Pass
floor(B/N)
transactions to_run_round()
, e.g.:tx_to_send[:int(B/N)]
- Implement the random selection
Copied from original issue: amiller/HoneyBadgerBFT#36
Metadata
Metadata
Assignees
Labels
enhancementNew feature or requestNew feature or request