Skip to content
This repository has been archived by the owner on May 13, 2022. It is now read-only.

Commit

Permalink
tumbler: disallow minmakercount < config.POLICY.minimum_makers
Browse files Browse the repository at this point in the history
  • Loading branch information
AdamISZ committed Oct 27, 2016
1 parent 107b270 commit a579ff4
Showing 1 changed file with 15 additions and 0 deletions.
15 changes: 15 additions & 0 deletions tumbler.py
Original file line number Diff line number Diff line change
Expand Up @@ -562,6 +562,21 @@ def main():
print(destaddrs)

load_program_config()

#The minmakercount setting should not be lower than the
#minimum allowed makers according to the config
if options['minmakercount'] < jm_single().config.getint(
"POLICY", "minimum_makers"):
log.error("You selected a minimum number of counterparties (" + \
str(options['minmakercount']) + \
") less than the "
"minimum requirement (" + \
str(jm_single().config.getint("POLICY","minimum_makers")) + \
"); you can edit the value 'minimum_makers'"
" in the POLICY section in joinmarket.cfg to correct this. "
"Quitting.")
exit(0)

for addr in destaddrs:
addr_valid, errormsg = validate_address(addr)
if not addr_valid:
Expand Down

0 comments on commit a579ff4

Please sign in to comment.