Skip to content

Commit d98d27d

Browse files
committed
Return an early error if we can't extract enough information from the draft to fill in the metainformation that lets the user return to this submission later. Tweak an error message.
- Legacy-Id: 3171
1 parent 010e924 commit d98d27d

1 file changed

Lines changed: 3 additions & 1 deletion

File tree

ietf/submit/parsers/plain_parser.py

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -59,10 +59,12 @@ def parse_filename(self):
5959
match_revision = revisionre.match(filename)
6060
if match_revision:
6161
self.parsed_info.metadraft.revision = match_revision.group(1)
62+
else:
63+
self.parsed_info.add_error(u'The filename found on the first page of the document does not contain a revision: "%s"' % (filename,))
6264
filename = re.sub('-\d+$', '', filename)
6365
self.parsed_info.metadraft.filename = filename
6466
return
65-
self.parsed_info.add_error('The document does not contain a legitimate filename that start with draft-*')
67+
self.parsed_info.add_error('The first page of the document does not contain a legitimate filename that start with draft-*')
6668

6769
def parse_wg(self):
6870
filename = self.parsed_info.metadraft.filename

0 commit comments

Comments
 (0)