[Python-checkins] cpython: Issue #18922: Now The Lib/smtpd.py and Tools/i18n/msgfmt.py scripts write

serhiy.storchaka python-checkins at python.org
Thu Sep 5 16:45:24 CEST 2013


http://hg.python.org/cpython/rev/e81699a6390c
changeset:   85547:e81699a6390c
user:        Serhiy Storchaka <storchaka at gmail.com>
date:        Thu Sep 05 17:44:53 2013 +0300
summary:
  Issue #18922: Now The Lib/smtpd.py and Tools/i18n/msgfmt.py scripts write
their version strings to stdout, and not to sderr.

files:
  Lib/smtpd.py         |  2 +-
  Misc/NEWS            |  6 ++++++
  Tools/i18n/msgfmt.py |  2 +-
  3 files changed, 8 insertions(+), 2 deletions(-)


diff --git a/Lib/smtpd.py b/Lib/smtpd.py
--- a/Lib/smtpd.py
+++ b/Lib/smtpd.py
@@ -780,7 +780,7 @@
         if opt in ('-h', '--help'):
             usage(0)
         elif opt in ('-V', '--version'):
-            print(__version__, file=sys.stderr)
+            print(__version__)
             sys.exit(0)
         elif opt in ('-n', '--nosetuid'):
             options.setuid = 0
diff --git a/Misc/NEWS b/Misc/NEWS
--- a/Misc/NEWS
+++ b/Misc/NEWS
@@ -214,6 +214,12 @@
 - Issue #18783: Removed existing mentions of Python long type in docstrings,
   error messages and comments.
 
+Tools/Demos
+-----------
+
+- Issue #18922: Now The Lib/smtpd.py and Tools/i18n/msgfmt.py scripts write
+  their version strings to stdout, and not to sderr.
+
 
 What's New in Python 3.4.0 Alpha 1?
 ===================================
diff --git a/Tools/i18n/msgfmt.py b/Tools/i18n/msgfmt.py
--- a/Tools/i18n/msgfmt.py
+++ b/Tools/i18n/msgfmt.py
@@ -218,7 +218,7 @@
         if opt in ('-h', '--help'):
             usage(0)
         elif opt in ('-V', '--version'):
-            print("msgfmt.py", __version__, file=sys.stderr)
+            print("msgfmt.py", __version__)
             sys.exit(0)
         elif opt in ('-o', '--output-file'):
             outfile = arg

-- 
Repository URL: http://hg.python.org/cpython


More information about the Python-checkins mailing list