Skip to content

Commit f8391f7

Browse files
committed
Fix the other self.warn calls
1 parent 72caf77 commit f8391f7

File tree

1 file changed

+8
-7
lines changed

1 file changed

+8
-7
lines changed

Doc/tools/extensions/suspicious.py

Lines changed: 8 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -153,14 +153,15 @@ def report_issue(self, text, lineno, issue):
153153
self.any_issue = True
154154
self.write_log_entry(lineno, issue, text)
155155
if py3:
156-
self.logger.warn('[%s:%d] "%s" found in "%-.120s"' %
157-
(self.docname, lineno, issue, text))
156+
self.logger.warning('[%s:%d] "%s" found in "%-.120s"' %
157+
(self.docname, lineno, issue, text))
158158
else:
159-
self.logger.warn('[%s:%d] "%s" found in "%-.120s"' % (
160-
self.docname.encode(sys.getdefaultencoding(),'replace'),
161-
lineno,
162-
issue.encode(sys.getdefaultencoding(),'replace'),
163-
text.strip().encode(sys.getdefaultencoding(),'replace')))
159+
self.logger.warning(
160+
'[%s:%d] "%s" found in "%-.120s"' % (
161+
self.docname.encode(sys.getdefaultencoding(),'replace'),
162+
lineno,
163+
issue.encode(sys.getdefaultencoding(),'replace'),
164+
text.strip().encode(sys.getdefaultencoding(),'replace')))
164165
self.app.statuscode = 1
165166

166167
def write_log_entry(self, lineno, issue, text):

0 commit comments

Comments
 (0)