##// END OF EJS Templates
notify: adapt to new location of email module's errors...
Augie Fackler -
r40320:46b55f27 default
parent child Browse files
Show More
@@ -153,6 +153,7 b' from mercurial import ('
153 153 logcmdutil,
154 154 mail,
155 155 patch,
156 pycompat,
156 157 registrar,
157 158 util,
158 159 )
@@ -161,6 +162,11 b' from mercurial.utils import ('
161 162 stringutil,
162 163 )
163 164
165 if pycompat.ispy3:
166 import email.errors as emailerrors
167 else:
168 emailerrors = email.Errors
169
164 170 # Note for extension authors: ONLY specify testedwith = 'ships-with-hg-core' for
165 171 # extensions which SHIP WITH MERCURIAL. Non-mainline extensions should
166 172 # be specifying the version(s) of Mercurial they are tested with, or
@@ -362,7 +368,7 b' class notifier(object):'
362 368 p = emailparser.Parser()
363 369 try:
364 370 msg = p.parsestr(data)
365 except email.Errors.MessageParseError as inst:
371 except emailerrors.MessageParseError as inst:
366 372 raise error.Abort(inst)
367 373
368 374 # store sender and subject
General Comments 0
You need to be logged in to leave comments. Login now