[issue23262] webbrowser module broken with Firefox 36+

2016-10-30 Thread Oleg Broytman
Oleg Broytman added the comment: Let's me disagree because Python 2.7 is a very special case. One can easily update a browser — they are perfectly compatible. But one cannot just update Python 2.7 because Python 3 is rather a different language that requires a lot of porting effort. So I can i

[issue28565] datetime.strptime %Z doesn't get included in the result

2016-10-30 Thread Xiang Zhang
Changes by Xiang Zhang : -- nosy: +belopolsky ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.pyth

[issue23262] webbrowser module broken with Firefox 36+

2016-10-30 Thread Serhiy Storchaka
Serhiy Storchaka added the comment: What to do with 2.7? We can just backport the patch from 3.5, but also can use the version check from earlier Oleg's patches. 2.7 was released long time ago and still can be used on systems with old browsers (however it is very unlikely that Python is update

[issue27517] LZMACompressor and LZMADecompressor raise exceptions if given empty strings twice

2016-10-30 Thread Roundup Robot
Roundup Robot added the comment: New changeset b06f15507978 by Serhiy Storchaka in branch '3.5': Issue #27517: LZMA compressor and decompressor no longer raise exceptions if https://hg.python.org/cpython/rev/b06f15507978 New changeset fb64c7a81010 by Serhiy Storchaka in branch '3.6': Issue #2751

[issue27517] LZMACompressor and LZMADecompressor raise exceptions if given empty strings twice

2016-10-30 Thread Serhiy Storchaka
Serhiy Storchaka added the comment: Thank you for you contribution Benjamin. -- resolution: -> fixed stage: patch review -> resolved status: open -> closed ___ Python tracker __

[issue28385] Bytes objects should reject all formatting codes with an error message

2016-10-30 Thread Serhiy Storchaka
Serhiy Storchaka added the comment: Shouldn't the type of error be changed from TypeError to ValueError? -- ___ Python tracker ___ ___

[issue28385] Bytes objects should reject all formatting codes with an error message

2016-10-30 Thread Roundup Robot
Roundup Robot added the comment: New changeset f43078ec598c by Serhiy Storchaka in branch '3.6': Update the f-string test broken in issue #28385. https://hg.python.org/cpython/rev/f43078ec598c New changeset 931410a04240 by Serhiy Storchaka in branch 'default': Update the f-string test broken in

[issue28565] datetime.strptime %Z doesn't get included in the result

2016-10-30 Thread lilydjwg
New submission from lilydjwg: With %z, the result gets a tzinfo, but with %Z, it succeeds but the result is without timezone info: >>> datetime.datetime.strptime('2016-10-31T03:58:24 CST', '%Y-%m-%dT%H:%M:%S >>> %Z') datetime.datetime(2016, 10, 31, 3, 58, 24) >>> datetime.datetime.strptime('20

[issue26163] FAIL: test_hash_effectiveness (test.test_set.TestFrozenSet)

2016-10-30 Thread Raymond Hettinger
Changes by Raymond Hettinger : -- assignee: -> rhettinger ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscribe: http

[issue28513] Document zipfile CLI

2016-10-30 Thread Xiang Zhang
Xiang Zhang added the comment: LGTM. -- nosy: +xiang.zhang ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscribe: http

[issue28128] Improve the warning message for invalid escape sequences

2016-10-30 Thread Emanuel Barry
Emanuel Barry added the comment: Thank you Eric. Have you looked at making a new DeprecatedSyntaxWarning subclass of both DeprecationWarning and SyntaxWarning? Hopefully that's of some help. I don't see a review link, but from a quick glance this looks good. Thanks :) --

[issue27517] LZMACompressor and LZMADecompressor raise exceptions if given empty strings twice

2016-10-30 Thread Benjamin Fogle
Benjamin Fogle added the comment: Ah, thank you. Good catch. I have reworked the patch to handle both cases. -- Added file: http://bugs.python.org/file45286/lzma_2.patch ___ Python tracker _

[issue28128] Improve the warning message for invalid escape sequences

2016-10-30 Thread Eric V. Smith
Eric V. Smith added the comment: Oops, use 28128-3.diff. -- Added file: http://bugs.python.org/file45285/28128-3.diff ___ Python tracker ___ _

[issue28385] Bytes objects should reject all formatting codes with an error message

2016-10-30 Thread Eric V. Smith
Eric V. Smith added the comment: I would change the f-string tests. I realize it's a fragile test, but it's the only way to test the strings in the exception. -- ___ Python tracker

[issue21423] concurrent.futures.ThreadPoolExecutor/ProcessPoolExecutor should accept an initializer argument

2016-10-30 Thread Pedro Algarvio
Pedro Algarvio added the comment: Would also love to see this in the stdlib soon. My use case is logging setup(forward logs to the main process). -- ___ Python tracker ___ _

[issue28128] Improve the warning message for invalid escape sequences

2016-10-30 Thread Eric V. Smith
Changes by Eric V. Smith : -- stage: needs patch -> patch review ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscribe:

[issue28128] Improve the warning message for invalid escape sequences

2016-10-30 Thread Eric V. Smith
Changes by Eric V. Smith : Added file: http://bugs.python.org/file45284/28128-2.diff ___ Python tracker ___ ___ Python-bugs-list mailing list

[issue28128] Improve the warning message for invalid escape sequences

2016-10-30 Thread Eric V. Smith
Eric V. Smith added the comment: Here's an updated patch, that fixes some problems with the earlier patch, and adds equivalent support for bytes. HOWEVER, I can't get the warnings machinery to raise a DeprecationWarning that would have all of the equivalent information that an actual SyntaxErr

[issue21423] concurrent.futures.ThreadPoolExecutor/ProcessPoolExecutor should accept an initializer argument

2016-10-30 Thread Pedro Algarvio
Changes by Pedro Algarvio : -- nosy: +Pedro.Algarvio ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscribe: https://ma

[issue26163] FAIL: test_hash_effectiveness (test.test_set.TestFrozenSet)

2016-10-30 Thread Eric Appelt
Eric Appelt added the comment: Ugh... so I think I made a mental error (i.e. confused myself) in the last comment. The result looked a bit "to good to be true" and I think that there is at least one error in my thinking about the problem. I tried testing with the width set to 2 and then 1 as a

[issue28542] document cross compilation

2016-10-30 Thread Xavier de Gaye
Xavier de Gaye added the comment: > The ACTION-IF-CROSS-COMPILING parameter of the AC_RUN_IFELSE that checks for > getaddrinfo is $ac_cv_buggy_getaddrinfo="no -- configured with > --(en|dis)able-ipv6". Hum, I should have written: The ACTION-IF-CROSS-COMPILING parameter of the AC_RUN_IFELSE tha

[issue28542] document cross compilation

2016-10-30 Thread Xavier de Gaye
Xavier de Gaye added the comment: One must also add '--(en|dis)able-ipv6' to configure, otherwise configure exits with: Fatal: You must get working getaddrinfo() function. or you can specify "--disable-ipv6". The ACTION-IF-CROSS-COMPILING parameter of the AC_RUN_IFELSE that checks

[issue28541] Improve test coverage for json library - loading bytes

2016-10-30 Thread Serhiy Storchaka
Changes by Serhiy Storchaka : -- assignee: -> serhiy.storchaka resolution: -> fixed stage: patch review -> resolved status: open -> closed ___ Python tracker ___ __

[issue28549] curses: calling addch() with an 1-length str segfaults with ncurses6 compiled with --enable-ext-colors

2016-10-30 Thread Serhiy Storchaka
Serhiy Storchaka added the comment: Thank you for testing this. -- resolution: -> fixed stage: patch review -> resolved status: open -> closed ___ Python tracker ___ ___

[issue28541] Improve test coverage for json library - loading bytes

2016-10-30 Thread Serhiy Storchaka
Serhiy Storchaka added the comment: Thank you for your contribution Eric. -- ___ Python tracker ___ ___ Python-bugs-list mailing list

[issue28541] Improve test coverage for json library - loading bytes

2016-10-30 Thread Roundup Robot
Roundup Robot added the comment: New changeset ea4cc65fc0fc by Serhiy Storchaka in branch '3.6': Issue #28541: Improve test coverage for encoding detection in json library. https://hg.python.org/cpython/rev/ea4cc65fc0fc New changeset e9169a8c0692 by Serhiy Storchaka in branch 'default': Issue #2

[issue28549] curses: calling addch() with an 1-length str segfaults with ncurses6 compiled with --enable-ext-colors

2016-10-30 Thread Roundup Robot
Roundup Robot added the comment: New changeset d06bf822585c by Serhiy Storchaka in branch '3.5': Issue #28549: Fixed segfault in curses's addch() with ncurses6. https://hg.python.org/cpython/rev/d06bf822585c New changeset 382b3d19e9fc by Serhiy Storchaka in branch '3.6': Issue #28549: Fixed segf

[issue28549] curses: calling addch() with an 1-length str segfaults with ncurses6 compiled with --enable-ext-colors

2016-10-30 Thread Serhiy Storchaka
Changes by Serhiy Storchaka : -- assignee: -> serhiy.storchaka ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscribe:

[issue28564] shutil.rmtree is inefficient due to listdir() instead of scandir()

2016-10-30 Thread Serhiy Storchaka
Changes by Serhiy Storchaka : -- nosy: +serhiy.storchaka type: -> enhancement versions: +Python 3.7 -Python 3.5 ___ Python tracker ___ __

[issue28498] tk busy command

2016-10-30 Thread Serhiy Storchaka
Serhiy Storchaka added the comment: Ah, yes, this feature is not supported on OSX/Aqua. -- ___ Python tracker ___ ___ Python-bugs-list

[issue28564] shutil.rmtree is inefficient due to listdir() instead of scandir()

2016-10-30 Thread Marian Beermann
New submission from Marian Beermann: The use of os.listdir severely limits the speed of this function on anything except solid-state drives. Using the new-in-Python 3.5 os.scandir should eliminate this bottleneck. -- components: Library (Lib) messages: 279745 nosy: enkore priority: norm

[issue26937] the chown() method of the tarfile.TarFile class fails on Android

2016-10-30 Thread Xavier de Gaye
Xavier de Gaye added the comment: The chown() method of the tarfile.TarFile class does not attempt to do a chown when pwd is None, even when numeric_owner is True, and although an attempt is made to fall back to tarinfo.gid when getgrnam() fails, or to tarinfo.uid when getgrnam() fails, nothin

[issue26163] FAIL: test_hash_effectiveness (test.test_set.TestFrozenSet)

2016-10-30 Thread Eric Appelt
Eric Appelt added the comment: I spent some time looking at the Objects/setobject.c code where the hashing scheme for frozensets, which essentially works by XOR-ing together the hashes from all its entries. Significant care is taken to shuffle bits at various stages, and the algorithm seems to

[issue28553] int.to_bytes docs logic error

2016-10-30 Thread Serhiy Storchaka
Changes by Serhiy Storchaka : -- nosy: +mark.dickinson ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscribe: https://

[issue28385] Bytes objects should reject all formatting codes with an error message

2016-10-30 Thread Serhiy Storchaka
Serhiy Storchaka added the comment: What is better? 1. Replace "unsupported format string passed to" back to "non-empty format string passed to " in generated error message? Note that full error message is changed in any case, this is the purpose of this issue. 2. Change the pattern "non-empt

[issue28449] tarfile.open(mode = 'r:*', ignore_zeros = True) has 50% chance failed to open compressed tars?

2016-10-30 Thread Serhiy Storchaka
Changes by Serhiy Storchaka : -- assignee: -> serhiy.storchaka resolution: -> fixed stage: patch review -> resolved status: open -> closed ___ Python tracker ___ __

[issue28553] int.to_bytes docs logic error

2016-10-30 Thread INADA Naoki
INADA Naoki added the comment: Make sense. -- keywords: +easy, patch nosy: +inada.naoki stage: -> commit review versions: -Python 3.3, Python 3.4 Added file: http://bugs.python.org/file45280/28553.patch ___ Python tracker

[issue28449] tarfile.open(mode = 'r:*', ignore_zeros = True) has 50% chance failed to open compressed tars?

2016-10-30 Thread Roundup Robot
Roundup Robot added the comment: New changeset f108e063e299 by Serhiy Storchaka in branch '3.5': Issue #28449: tarfile.open() with mode "r" or "r:" now tries to open a tar https://hg.python.org/cpython/rev/f108e063e299 New changeset e2dd0f48e643 by Serhiy Storchaka in branch '2.7': Issue #28449:

[issue28385] Bytes objects should reject all formatting codes with an error message

2016-10-30 Thread Ned Deily
Ned Deily added the comment: Buildbots are failing: == FAIL: test_errors (test.test_fstring.TestCase) (str="f'{(lambda: 0):x}'") -- TypeError: unsupported forma

[issue28498] tk busy command

2016-10-30 Thread Ned Deily
Ned Deily added the comment: With ActiveState 8.6.4.1 (the most recent version available) on macOS: == ERROR: test_tk_busy (tkinter.test.test_tkinter.test_misc.MiscTest) --

[issue28563] Arbitrary code execution in gettext.c2py

2016-10-30 Thread Serhiy Storchaka
Changes by Serhiy Storchaka : -- nosy: +serhiy.storchaka priority: normal -> high ___ Python tracker ___ ___ Python-bugs-list mailing

[issue27517] LZMACompressor and LZMADecompressor raise exceptions if given empty strings twice

2016-10-30 Thread Serhiy Storchaka
Serhiy Storchaka added the comment: Thank you for your report and patch Benjamin. Seems your patch fixes the problem in default case. But the compressor still fails with the raw format. >>> import lzma >>> FILTERS_RAW_4 = [{"id": lzma.FILTER_DELTA, "dist": 4}, ... {"id": lzma.F

[issue28385] Bytes objects should reject all formatting codes with an error message

2016-10-30 Thread Roundup Robot
Roundup Robot added the comment: New changeset 92cae79fa5d9 by Serhiy Storchaka in branch '3.5': Issue #28385: An error message when non-empty format spec is passed to https://hg.python.org/cpython/rev/92cae79fa5d9 New changeset 0a985f7c6731 by Serhiy Storchaka in branch '3.6': Issue #28385: An

[issue28128] Improve the warning message for invalid escape sequences

2016-10-30 Thread Eric V. Smith
Changes by Eric V. Smith : -- assignee: -> eric.smith ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscribe: https://

[issue28385] Bytes objects should reject all formatting codes with an error message

2016-10-30 Thread Serhiy Storchaka
Changes by Serhiy Storchaka : -- assignee: -> serhiy.storchaka ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscribe:

[issue28563] Arbitrary code execution in gettext.c2py

2016-10-30 Thread SilentGhost
Changes by SilentGhost : -- nosy: +loewis ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.python.o

[issue23262] webbrowser module broken with Firefox 36+

2016-10-30 Thread Roundup Robot
Roundup Robot added the comment: New changeset dacb52577c1c by Serhiy Storchaka in branch '3.5': Issue #23262: The webbrowser module now supports Firefox 36+ and derived https://hg.python.org/cpython/rev/dacb52577c1c New changeset f1abc92a756a by Serhiy Storchaka in branch '3.6': - Issue #23262:

[issue27517] LZMACompressor and LZMADecompressor raise exceptions if given empty strings twice

2016-10-30 Thread Serhiy Storchaka
Changes by Serhiy Storchaka : -- assignee: -> serhiy.storchaka ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscribe:

[issue23262] webbrowser module broken with Firefox 36+

2016-10-30 Thread Serhiy Storchaka
Changes by Serhiy Storchaka : -- assignee: -> serhiy.storchaka ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscribe:

[issue28513] Document zipfile CLI

2016-10-30 Thread Serhiy Storchaka
Changes by Serhiy Storchaka : -- nosy: +martin.panter ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscribe: https://m

[issue28563] Arbitrary code execution in gettext.c2py

2016-10-30 Thread Carl Ekerot
New submission from Carl Ekerot: The c2py-function in the gettext module is seriously flawed in many ways due to its use of eval to create a plural function: return eval('lambda n: int(%s)' % plural) My first discovery was that nothing prevents an input plural string that resembles a functio

[issue26865] Meta-issue: support of the android platform

2016-10-30 Thread Xavier de Gaye
Xavier de Gaye added the comment: issue #28562: test_asyncio fails on Android upon calling getaddrinfo() -- dependencies: +test_asyncio fails on Android upon calling getaddrinfo() ___ Python tracker ___

[issue28293] Don't completely dump the regex cache when full

2016-10-30 Thread Serhiy Storchaka
Changes by Serhiy Storchaka : -- versions: -Python 3.6 ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscribe: https:/

[issue27939] Tkinter mainloop raises when setting the value of ttk.LabeledScale

2016-10-30 Thread Serhiy Storchaka
Changes by Serhiy Storchaka : -- resolution: -> fixed stage: patch review -> resolved status: open -> closed ___ Python tracker ___ _

[issue27939] Tkinter mainloop raises when setting the value of ttk.LabeledScale

2016-10-30 Thread Roundup Robot
Roundup Robot added the comment: New changeset 394b2b4da150 by Serhiy Storchaka in branch '3.5': Issue #27939: Fixed bugs in tkinter.ttk.LabeledScale and tkinter.Scale caused https://hg.python.org/cpython/rev/394b2b4da150 New changeset 91884d043fdc by Serhiy Storchaka in branch '3.6': Issue #279

[issue28562] test_asyncio fails on Android upon calling getaddrinfo()

2016-10-30 Thread Xavier de Gaye
New submission from Xavier de Gaye: The error: == ERROR: test_create_connection_service_name (test.test_asyncio.test_base_events.BaseEventLoopWithSelectorTests) ---

[issue26936] android: test_socket fails

2016-10-30 Thread Xavier de Gaye
Xavier de Gaye added the comment: This patch simply skips the statements that fail on Android. -- assignee: -> xdegaye components: +Tests -Cross-Build, Library (Lib) stage: -> patch review versions: +Python 3.7 Added file: http://bugs.python.org/file45278/test_socket.patch ___

[issue28561] Report surrogate characters range in utf8_encoder

2016-10-30 Thread Serhiy Storchaka
Serhiy Storchaka added the comment: Thanks Xiang. Yes, this all is follow up issue25267. -- resolution: -> fixed stage: patch review -> resolved status: open -> closed ___ Python tracker __

[issue28561] Report surrogate characters range in utf8_encoder

2016-10-30 Thread Roundup Robot
Roundup Robot added the comment: New changeset 542065b03c10 by Serhiy Storchaka in branch '3.6': Issue #28561: Clean up UTF-8 encoder: remove dead code, update comments, etc. https://hg.python.org/cpython/rev/542065b03c10 New changeset ee3670d9bda6 by Serhiy Storchaka in branch 'default': Issue

[issue27275] KeyError thrown by optimised collections.OrderedDict.popitem()

2016-10-30 Thread Roundup Robot
Roundup Robot added the comment: New changeset 3f816eecc53e by Serhiy Storchaka in branch '3.5': Backed out changeset 9f7505019767 (issue #27275). https://hg.python.org/cpython/rev/3f816eecc53e -- ___ Python tracker

[issue28498] tk busy command

2016-10-30 Thread Serhiy Storchaka
Serhiy Storchaka added the comment: Added a number of style comments on Rietveld. I believe klappnase could address them, but since there are too little time to beta3 and I have a weak hope to push this in 3.6, I addressed them myself. Rewritten docstrings and test. Ned, is it good to add this

[issue28524] Set default argument of logging.disable() to logging.CRITICAL

2016-10-30 Thread Vinay Sajip
Vinay Sajip added the comment: > The use case I've found is that I often have logging enabled while writing > code, and then want to shut it off once I've finished. You could do this by having a configuration which is quite verbose while doing development and then less verbose when in producti

[issue28128] Improve the warning message for invalid escape sequences

2016-10-30 Thread Eric V. Smith
Eric V. Smith added the comment: I'll work on this later today. -- ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscrib

[issue28499] Logging module documentation needs a rework.

2016-10-30 Thread Vinay Sajip
Vinay Sajip added the comment: s/leaving the details/leaving the more narrative aspects/ -- ___ Python tracker ___ ___ Python-bugs-lis

[issue28499] Logging module documentation needs a rework.

2016-10-30 Thread Vinay Sajip
Vinay Sajip added the comment: The current documentation makes it very simple for naive users, with the main section being a reference and leaving the details to the basic and advanced tutorials and the cookbook. This was deliberately done in response to earlier feedback that the documentation

[issue28560] Implement `PurePath.startswith` and `PurePath.endswith`

2016-10-30 Thread SilentGhost
Changes by SilentGhost : -- resolution: wont fix -> rejected stage: -> resolved ___ Python tracker ___ ___ Python-bugs-list mailing l

[issue28560] Implement `PurePath.startswith` and `PurePath.endswith`

2016-10-30 Thread Ram Rachum
Ram Rachum added the comment: Thanks. -- resolution: -> wont fix status: open -> closed ___ Python tracker ___ ___ Python-bugs-list m

[issue28532] Show sys.version when -V option is supplied twice.

2016-10-30 Thread INADA Naoki
INADA Naoki added the comment: Oh, it seems I hurried too much. Thanks to pointing it out. -- Added file: http://bugs.python.org/file45276/verbose-version3.patch ___ Python tracker _

[issue28560] Implement `PurePath.startswith` and `PurePath.endswith`

2016-10-30 Thread Serhiy Storchaka
Serhiy Storchaka added the comment: >>> from pathlib import Path >>> p = Path('/foo/bar') >>> Path('/foo') in p.parents True >>> Path('/spam') in p.parents False >>> p.parts[:2] == ('/', 'foo') True >>> p.parts[:2] == ('/', 'spam') False >>> p.relative_to('/foo') PosixPath('bar') >>> p.relative_t

[issue28426] PyUnicode_AsDecodedObject can only return unicode now

2016-10-30 Thread Arfrever Frehtes Taifersar Arahesis
Arfrever Frehtes Taifersar Arahesis added the comment: > New changeset 15a494886c5a by Serhiy Storchaka in branch '3.6': > Issue #28426: Deprecated undocumented functions PyUnicode_AsEncodedObject(), > https://hg.python.org/cpython/rev/15a494886c5a s/that encode form str/that encode from str/ in

[issue28387] double free in io.TextIOWrapper

2016-10-30 Thread Serhiy Storchaka
Changes by Serhiy Storchaka : Added file: http://bugs.python.org/file45275/textiowrapper_clear-2.7.patch ___ Python tracker ___ ___ Python-bug

[issue28387] double free in io.TextIOWrapper

2016-10-30 Thread Serhiy Storchaka
Serhiy Storchaka added the comment: Thank you for your report and patch Sebastian. In Python 3 the solution can be simpler, just move the line "_PyObject_GC_UNTRACK(self);" above the line "textiowrapper_clear(self);". But calling PyObject_ClearWeakRefs() also should be moved up. Otherwise hal

[issue28560] Implement `PurePath.startswith` and `PurePath.endswith`

2016-10-30 Thread Ram Rachum
Ram Rachum added the comment: I mean that `/foo` is one of the parent directories. "there are plenty of options ..." Can you please spell them out precisely? The full line of code. -- ___ Python tracker _

[issue28259] Ctypes bug windows

2016-10-30 Thread Aristotel
Aristotel added the comment: Any update on this? It blocks development of my project. -- ___ Python tracker ___ ___ Python-bugs-list m

[issue28561] Report surrogate characters range in utf8_encoder

2016-10-30 Thread Xiang Zhang
Changes by Xiang Zhang : Added file: http://bugs.python.org/file45273/utf8_encoder_v2.patch ___ Python tracker ___ ___ Python-bugs-list mailin

[issue28532] Show sys.version when -V option is supplied twice.

2016-10-30 Thread Martin Panter
Martin Panter added the comment: Sorry, I should have said: the other two files (Misc/python.man and Modules/main.c) also need an extra “the”, like you changed in Doc/using/cmdline.rst. Other than that, it looks okay to me. But I guess you could add a quick test case in Lib/test/test_cmd_line

[issue28561] Report surrogate characters range in utf8_encoder

2016-10-30 Thread Serhiy Storchaka
Changes by Serhiy Storchaka : -- assignee: -> serhiy.storchaka components: +Interpreter Core versions: +Python 3.6, Python 3.7 ___ Python tracker ___ ___

[issue28560] Implement `PurePath.startswith` and `PurePath.endswith`

2016-10-30 Thread SilentGhost
SilentGhost added the comment: Do you mean that /foo was just an arbitrary string, rather than one of the parent directories? Because in that case it seems a perfectly correct way to go about comparison. If /foo was one of the parents, there are plenty of options: .parts, .parents, .relative_t

[issue28532] Show sys.version when -V option is supplied twice.

2016-10-30 Thread INADA Naoki
Changes by INADA Naoki : Added file: http://bugs.python.org/file45272/verbose-version2.patch ___ Python tracker ___ ___ Python-bugs-list maili

[issue28561] Report surrogate characters range in utf8_encoder

2016-10-30 Thread Xiang Zhang
New submission from Xiang Zhang: In utf8_encoder, when a codecs returns a string with non-ascii characters, it raises encodeerror but the start and end position are not perfect. This seems like an oversight during evolution. Before, utf8_encoder only recognize one surrogate character a time. A