Changed check_audio_files() to only consider sessions on the official

schedule.  Fixes some 500 errors.  Commit ready to merge.
 - Legacy-Id: 11697
This commit is contained in:
Ryan Cross 2016-07-17 14:24:01 +00:00
parent 5307dc1cf1
commit 2e02011725

View file

@ -40,11 +40,11 @@ def check_audio_files(group,meeting):
Example: ietf90-salonb-20140721-1710-pm3.mp3
'''
for session in Session.objects.filter(group=group,meeting=meeting,status='sched'):
try:
timeslot = session.official_timeslotassignment().timeslot
except IndexError:
continue
for session in Session.objects.filter(group=group,
meeting=meeting,
status=('sched'),
timeslotassignments__schedule=meeting.agenda):
timeslot = session.official_timeslotassignment().timeslot
if not (timeslot.location and timeslot.time):
continue
room = timeslot.location.name.lower()