diff options
author | emkael <emkael@tlen.pl> | 2016-11-16 15:51:05 +0100 |
---|---|---|
committer | emkael <emkael@tlen.pl> | 2016-11-16 15:51:05 +0100 |
commit | cb8f0f1807b126057947031d241d352dddc9bcd1 (patch) | |
tree | 661c8c58ad966a12f5044ce858ccf6c3e13e04f8 /src | |
parent | 6f2dbc842db3613969c8867b2d8b1cac52b3bdbf (diff) |
* altering default behaviour for constructor parameter
Diffstat (limited to 'src')
-rw-r--r-- | src/bidding_data.py | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/src/bidding_data.py b/src/bidding_data.py index 72740e7..3dcae68 100644 --- a/src/bidding_data.py +++ b/src/bidding_data.py @@ -390,11 +390,13 @@ class JFRBidding(object): 'file_hashes': {}, 'force_resend': False} def __init__(self, bws_file, file_prefix, - section_number=0, max_round=sys.maxint): + section_number=0, max_round=0): """Construct parser object.""" log.getLogger('init').debug('reading BWS file: %s', bws_file) with pypyodbc.win_connect_mdb(bws_file) as connection: cursor = connection.cursor() + if max_round == 0: + max_round = sys.maxint criteria_string = ' WHERE ' criteria_string += 'Section = %d' % section_number \ if section_number > 0 else '1 = 1' |