From: Victor Stinner Date: Mon, 23 May 2011 22:16:16 +0000 (+0200) Subject: Issue #11377: platform.popen() emits a DeprecationWarning X-Git-Tag: v3.3.0a1~2183^2~137 X-Git-Url: http://git.ipfire.org/gitweb.cgi?a=commitdiff_plain;h=25000d4d31dfa5842776aa92f234ea6672489c67;p=thirdparty%2FPython%2Fcpython.git Issue #11377: platform.popen() emits a DeprecationWarning --- diff --git a/Lib/platform.py b/Lib/platform.py index 1e4abe64a1c6..e2a74fe13ca9 100755 --- a/Lib/platform.py +++ b/Lib/platform.py @@ -361,6 +361,8 @@ def popen(cmd, mode='r', bufsize=-1): """ Portable popen() interface. """ + import warnings + warnings.warn('use os.popen instead', DeprecationWarning, stacklevel=2) return os.popen(cmd, mode, bufsize) def _norm_version(version, build=''):