Skip to content

Commit 6ef24e9

Browse files
committed
Changed agenda file reading to read files as binary when looking for draft names listed in the agenda.
- Legacy-Id: 16505
1 parent 8d2d732 commit 6ef24e9

2 files changed

Lines changed: 2 additions & 2 deletions

File tree

ietf/meeting/helpers.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -216,7 +216,7 @@ def read_session_file(type, num, doc):
216216
# FIXME: uploaded_filename should be replaced with a function call that computes names that are fixed
217217
path = os.path.join(settings.AGENDA_PATH, "%s/%s/%s" % (num, type, doc.uploaded_filename))
218218
if os.path.exists(path):
219-
with io.open(path) as f:
219+
with io.open(path, 'rb') as f:
220220
return f.read(), path
221221
else:
222222
return None, path

ietf/meeting/views.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -656,7 +656,7 @@ def session_draft_list(num, acronym):
656656
for agenda in agendas:
657657
content, _ = read_agenda_file(num, agenda)
658658
if content:
659-
drafts.update(re.findall('(draft-[-a-z0-9]*)', content))
659+
drafts.update(re.findall(b'(draft-[-a-z0-9]*)', content))
660660

661661
result = []
662662
for draft in drafts:

0 commit comments

Comments
 (0)