From e9cf97cf20711dcede2e44b58f3ccc7d71280cc8 Mon Sep 17 00:00:00 2001 From: Andrew Svetlov Date: Wed, 17 Oct 2012 16:41:28 +0300 Subject: [PATCH 1/3] Issue #16265: Fix collapsing of code sample in tutorial. Thanks to Yongzhi Pan from docs@ --- Doc/tutorial/inputoutput.rst | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Doc/tutorial/inputoutput.rst b/Doc/tutorial/inputoutput.rst index 45de518de81..73143bee803 100644 --- a/Doc/tutorial/inputoutput.rst +++ b/Doc/tutorial/inputoutput.rst @@ -184,7 +184,7 @@ square brackets ``'[]'`` to access the keys :: >>> table = {'Sjoerd': 4127, 'Jack': 4098, 'Dcab': 8637678} >>> print('Jack: {0[Jack]:d}; Sjoerd: {0[Sjoerd]:d}; ' - 'Dcab: {0[Dcab]:d}'.format(table)) + ... 'Dcab: {0[Dcab]:d}'.format(table)) Jack: 4098; Sjoerd: 4127; Dcab: 8637678 This could also be done by passing the table as keyword arguments with the '**' From 1eff0fc3cd258c12433f28f441028534ff0ee600 Mon Sep 17 00:00:00 2001 From: Antoine Pitrou Date: Wed, 17 Oct 2012 16:12:30 +0200 Subject: [PATCH 2/3] Issue #15378: Fix Tools/unicode/comparecodecs.py. Patch by Serhiy Storchaka. --- Misc/NEWS | 2 ++ Tools/unicode/comparecodecs.py | 2 +- 2 files changed, 3 insertions(+), 1 deletion(-) diff --git a/Misc/NEWS b/Misc/NEWS index e1356add472..0efbefae70a 100644 --- a/Misc/NEWS +++ b/Misc/NEWS @@ -666,6 +666,8 @@ Documentation Tools/Demos ----------- +- Issue #15378: Fix Tools/unicode/comparecodecs.py. Patch by Serhiy Storchaka. + - Issue #14695: Fix missing support for starred assignments in Tools/parser/unparse.py. diff --git a/Tools/unicode/comparecodecs.py b/Tools/unicode/comparecodecs.py index 0f5c1e24a3a..01303dbcb74 100644 --- a/Tools/unicode/comparecodecs.py +++ b/Tools/unicode/comparecodecs.py @@ -30,7 +30,7 @@ def compare_codecs(encoding1, encoding2): mismatch += 1 # Check decoding for i in range(256): - c = chr(i) + c = bytes([i]) try: u1 = c.decode(encoding1) except UnicodeError: From abfc7df14982617f35a245247a935543639746dc Mon Sep 17 00:00:00 2001 From: Andrew Svetlov Date: Wed, 17 Oct 2012 17:15:43 +0300 Subject: [PATCH 3/3] Issue #9583: Document startup option/environment interaction. Patch by Todd Rovito. --- Doc/using/cmdline.rst | 6 ++++-- Misc/ACKS | 1 + 2 files changed, 5 insertions(+), 2 deletions(-) diff --git a/Doc/using/cmdline.rst b/Doc/using/cmdline.rst index 0d12126a4de..cd4d02f9b09 100644 --- a/Doc/using/cmdline.rst +++ b/Doc/using/cmdline.rst @@ -379,7 +379,10 @@ Options you shouldn't use Environment variables --------------------- -These environment variables influence Python's behavior. +These environment variables influence Python's behavior, they are processed +before the command-line switches other than -E. It is customary that +command-line switches override environmental variables where there is a +conflict. .. envvar:: PYTHONHOME @@ -570,4 +573,3 @@ if Python was configured with the ``--with-pydebug`` build option. If set, Python will print memory allocation statistics every time a new object arena is created, and on shutdown. - diff --git a/Misc/ACKS b/Misc/ACKS index 7429f77beb3..ba87ecbb79b 100644 --- a/Misc/ACKS +++ b/Misc/ACKS @@ -901,6 +901,7 @@ Hugo van Rossum Saskia van Rossum Donald Wallace Rouse II Liam Routt +Todd Rovito Craig Rowland Clinton Roy Paul Rubin