forked from boyska/sito-hackit-17
FIX explicitly set minimum possible duration
This commit is contained in:
parent
043c9d2499
commit
ee8837fbb1
1 changed files with 4 additions and 0 deletions
|
@ -100,6 +100,10 @@ def get_talk_data(talkname):
|
||||||
.format(talkname))
|
.format(talkname))
|
||||||
data['duration'] = 50
|
data['duration'] = 50
|
||||||
data['duration'] = int(data['duration'])
|
data['duration'] = int(data['duration'])
|
||||||
|
if data['duration'] < GRID_STEP:
|
||||||
|
logging.info("Talk <{}> lasts only {} minutes; changing to {}"
|
||||||
|
.format(talkname, data['duration'], GRID_STEP))
|
||||||
|
data['duration'] = GRID_STEP
|
||||||
if 'room' not in data:
|
if 'room' not in data:
|
||||||
logging.warn("Talk <{}> has no `room` field".format(talkname))
|
logging.warn("Talk <{}> has no `room` field".format(talkname))
|
||||||
if 'time' not in data or 'day' not in data:
|
if 'time' not in data or 'day' not in data:
|
||||||
|
|
Loading…
Reference in a new issue