Rietveld Code Review Tool
Help | Bug tracker | Discussion group | Source code | Sign in
(10)

Unified Diff: Lib/cgi.py

Issue 3255: Issue #3602 (Closed) SVN Base: http://svn.python.org/view/*checkout*/python/trunk/
Patch Set: Created 1 year, 3 months ago
Use n/p to move between diff chunks; N/P to move between comments. Please Sign in to add in-line comments.
Jump to:
View side by-side-diff with in-line comments
Download patch
Index: Lib/cgi.py
===================================================================
--- Lib/cgi.py (revision 65979)
+++ Lib/cgi.py (working copy)
@@ -39,13 +39,14 @@
import os
import urllib
import UserDict
-from test.test_support import catch_warning
-from warnings import filterwarnings
-with catch_warning(record=False):
- filterwarnings("ignore", ".*mimetools has been removed",
- DeprecationWarning)
+from warnings import filterwarnings, catch_warnings
+with catch_warnings():
+ if sys.py3kwarning:
+ filterwarnings("ignore", ".*mimetools has been removed",
+ DeprecationWarning)
import mimetools
- filterwarnings("ignore", ".*rfc822 has been removed", DeprecationWarning)
+ if sys.py3kwarning:
+ filterwarnings("ignore", ".*rfc822 has been removed", DeprecationWarning)
import rfc822
try:

Powered by Google App Engine
RSS Feeds Recent Issues | This issue
This is Rietveld r497