[issue38218] SyntaxError in Tutorial 8.6 Defining Clean-up Actions

2019-09-18 Thread Stéphane Wirtel
Stéphane Wirtel added the comment: Thank you for your contribution -- resolution: -> fixed stage: patch review -> resolved status: open -> closed ___ Python tracker ___

[issue38218] SyntaxError in Tutorial 8.6 Defining Clean-up Actions

2019-09-18 Thread Stéphane Wirtel
Stéphane Wirtel added the comment: New changeset 6612a4fd36c7f2d71b00da12a3ad4ce619670cd2 by Stéphane Wirtel (Miss Islington (bot)) in branch '3.8': [3.8] bpo-38218: Doc: Corrected syntax for return annotation (GH-16265) (GH-16274)

[issue38218] SyntaxError in Tutorial 8.6 Defining Clean-up Actions

2019-09-18 Thread Stéphane Wirtel
Stéphane Wirtel added the comment: New changeset 20d3bce3effd7cca71a9bf3caa247eef2791517b by Stéphane Wirtel (Miss Islington (bot)) in branch '3.7': [3.7] bpo-38218: Doc: Corrected syntax for return annotation (GH-16265) (GH-16275)

[issue38218] SyntaxError in Tutorial 8.6 Defining Clean-up Actions

2019-09-18 Thread miss-islington
Change by miss-islington : -- pull_requests: +15863 pull_request: https://github.com/python/cpython/pull/16274 ___ Python tracker ___

[issue38218] SyntaxError in Tutorial 8.6 Defining Clean-up Actions

2019-09-18 Thread miss-islington
Change by miss-islington : -- pull_requests: +15864 pull_request: https://github.com/python/cpython/pull/16275 ___ Python tracker ___

[issue38220] Wrong values for %b and %B in ca_ES and ca_AD locales

2019-09-18 Thread Eryk Sun
Eryk Sun added the comment: The result from strftime is platform dependent. In Windows, the result has a trailing "." for the abbreviated names that are less than four characters, but no "de" in either form: >>> months = [(2019, m) + (0,)*7 for m in range(1,13)] >>>

[issue38218] SyntaxError in Tutorial 8.6 Defining Clean-up Actions

2019-09-18 Thread miss-islington
Change by miss-islington : -- pull_requests: +15862 pull_request: https://github.com/python/cpython/pull/16273 ___ Python tracker ___

[issue38218] SyntaxError in Tutorial 8.6 Defining Clean-up Actions

2019-09-18 Thread miss-islington
Change by miss-islington : -- pull_requests: +15861 pull_request: https://github.com/python/cpython/pull/16272 ___ Python tracker ___

[issue38116] Make select module PEP-384 compatible

2019-09-18 Thread Paulo Henrique Silva
Change by Paulo Henrique Silva : -- nosy: +phsilva ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscribe:

[issue38221] Enhancement to pydoc for Python 3.6 to allow full backgrounding as a server

2019-09-18 Thread Lindsay Haisley
New submission from Lindsay Haisley : This patch extends the functionality of pydoc3 to allow it to run purely as a server, as is the case with pydoc for python 2.7. If the -d option is specified, pydoc as a server (-p option) may be backgrounded to a subshell with "&". --

[issue38205] Python no longer compiles without small integer singletons

2019-09-18 Thread Ammar Askar
Ammar Askar added the comment: For the control path warning, that can be fixed by just hinting to the compiler that the function doesn't return like so: # ifdef __GNUC__ __attribute__ ((noreturn)) # elif defined(_MSC_VER) __declspec(noreturn) # endif static inline void

[issue38205] Python no longer compiles without small integer singletons

2019-09-18 Thread Ma Lin
Ma Lin added the comment: PR 16270 use Py_UNREACHABLE() in a single line. It solves this particular issue. -- ___ Python tracker ___

[issue38205] Python no longer compiles without small integer singletons

2019-09-18 Thread Ma Lin
Change by Ma Lin : -- keywords: +patch pull_requests: +15860 stage: -> patch review pull_request: https://github.com/python/cpython/pull/16270 ___ Python tracker ___

[issue38205] Python no longer compiles without small integer singletons

2019-09-18 Thread Ma Lin
Ma Lin added the comment: If use static inline function, and Py_UNREACHABLE() inside an if-else branch that should return a value, compiler may emit warning: https://godbolt.org/z/YtcNSf MSVC v19.14: warning C4715: 'test': not all control paths return a value clang 8.0.0:

[issue17822] Save on Close windows (IDLE)

2019-09-18 Thread Terry J. Reedy
Terry J. Reedy added the comment: AttributeErrors on closing were a separate issue. They are now caught on closing. #35379. Save on Close is now modal on Windows also, in that one cannot do anything with the Window being closed. One can try to close a second dirty window. Saying 'no' in

[issue29258] __init__.py required for pkgutil.walk_packages in python3

2019-09-18 Thread Eric Wieser
Change by Eric Wieser : -- nosy: +Eric Wieser ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscribe:

[issue35379] IDLE's close fails io is set to None on Mac

2019-09-18 Thread Terry J. Reedy
Terry J. Reedy added the comment: #17822 is not what I was thinking of, nor are #17614 or #22614, so I considered this issue done for now. -- resolution: -> fixed stage: commit review -> resolved status: open -> closed ___ Python tracker

[issue38216] Fix for issue30458 prevents crafting invalid requests

2019-09-18 Thread Tim Burke
Change by Tim Burke : -- nosy: +tburke ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscribe:

[issue30458] [security][CVE-2019-9740][CVE-2019-9947] HTTP Header Injection (follow-up of CVE-2016-5699)

2019-09-18 Thread Ned Deily
Ned Deily added the comment: With the breaking out of the portential and/or actual regression (e.g. invalid requests can no longer be crafted) into Issue38216, itself a potential release blocker, we are still left here with the as-yet unresolved issue identified above in msg34728 (e.g. not

[issue38216] Fix for issue30458 prevents crafting invalid requests

2019-09-18 Thread Ned Deily
Ned Deily added the comment: Thanks for identifying this issue and breaking it out into a separate bpo, Jason. If I understand correctly, the problematic fix for Issue30458 has already been released in maintenance release 3.7.4 and security release 3.6.9, is in the current security release

[issue38205] Python no longer compiles without small integer singletons

2019-09-18 Thread Zachary Ware
Zachary Ware added the comment: I have poked at this a bit and have an implementation that defines a `static inline void _Py_Unreachable()` in pymacro.h, see https://github.com/zware/cpython/commit/d07b4255dc1170155e18db0fea99ec1cb29c2f0a This works on at least macOS and Windows, and we

[issue38205] Python no longer compiles without small integer singletons

2019-09-18 Thread Gregory P. Smith
Gregory P. Smith added the comment: While I don't like how that get_small_int macro is defined... and I don't like that Py_UNREACHABLE() was usable as an expression in the past... it is probably best to just revert 3ab61473ba7f3dca32d779ec2766a4faa0657923. The choice to use a macro for this

[issue34820] binascii.c:1578:1: error: the control flow of function ‘binascii_crc32’ does not match its profile data (counter ‘arcs’)

2019-09-18 Thread Ned Deily
Change by Ned Deily : -- stage: resolved -> needs patch status: closed -> open ___ Python tracker ___ ___ Python-bugs-list mailing

[issue38220] Wrong values for %b and %B in ca_ES and ca_AD locales

2019-09-18 Thread Joan
Joan added the comment: Issue can be reproduced with this snippet: --- import locale from datetime import datetime locale.setlocale(locale.LC_ALL, 'ca_AD.utf8') locale.setlocale(locale.LC_ALL, 'ca_ES.utf8') #locale.setlocale(locale.LC_ALL, 'es_ES.utf8') now = datetime.now() # current date and

[issue38220] Wrong values for %b and %B in ca_ES and ca_AD locales

2019-09-18 Thread Joan
New submission from Joan : There's an incorrect behaviour in the output for the strftime values when in catalan. On the documentation at https://docs.python.org/3.7/library/datetime.html#strftime-strptime-behavior: - %b Month as locale’s abbreviated name. Jan, Feb, …, Dec (en_US) - %B Month

[issue34820] binascii.c:1578:1: error: the control flow of function ‘binascii_crc32’ does not match its profile data (counter ‘arcs’)

2019-09-18 Thread David Cuthbert
Change by David Cuthbert : -- versions: +Python 3.8 ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscribe:

[issue34820] binascii.c:1578:1: error: the control flow of function ‘binascii_crc32’ does not match its profile data (counter ‘arcs’)

2019-09-18 Thread David Cuthbert
David Cuthbert added the comment: I'm seeing this on a rebuild now of Python 3.7.4 on Ubuntu 18.04 (in my case against _ssl.c). What's happening is there's coverage/profiling data being generated in the build chain (somewhere), which spits out files named *.gcda. Interestingly, make clean

[issue38219] Optimize dict.__init__ and dict.update for dict argument

2019-09-18 Thread Serhiy Storchaka
Change by Serhiy Storchaka : -- keywords: +patch pull_requests: +15859 stage: -> patch review pull_request: https://github.com/python/cpython/pull/16268 ___ Python tracker

[issue38219] Optimize dict.__init__ and dict.update for dict argument

2019-09-18 Thread Serhiy Storchaka
New submission from Serhiy Storchaka : dict.__init__() and dict.update() with a positional argument look up the "keys" attribute of the argument to distinguish a mapping from a sequence of item-value pairs. It has a non-trivial cost. Merging dicts is optimized for exact dicts in

[issue38200] Adding itertools.pairwise to the standard library?

2019-09-18 Thread Tim Peters
Tim Peters added the comment: There's an eternal culture clash here: functional languages have a long history of building in just about everything of plausible use, regardless of how trivial to build on other stuff. This started when LISP was barely released before (cadr x) was introduced

[issue30458] [security][CVE-2019-9740][CVE-2019-9947] HTTP Header Injection (follow-up of CVE-2016-5699)

2019-09-18 Thread Jason R. Coombs
Jason R. Coombs added the comment: I've created issue38216 to address the (perceived) regression. -- ___ Python tracker ___ ___

[issue38216] Fix for issue30458 prevents crafting invalid requests

2019-09-18 Thread Jason R. Coombs
Change by Jason R. Coombs : -- keywords: +3.6regression, 3.7regression ___ Python tracker ___ ___ Python-bugs-list mailing list

[issue36274] http.client cannot send non-ASCII request lines

2019-09-18 Thread Jason R. Coombs
Jason R. Coombs added the comment: That's right - no longer a 3.7 regression here. -- keywords: -3.7regression ___ Python tracker ___

[issue38200] Adding itertools.pairwise to the standard library?

2019-09-18 Thread Vedran Čačić
Vedran Čačić added the comment: I also use it all the time. Most recently in some numerical calculation for successive differences. My main problem is that I'm too often tempted to just zip l with l[1:], thereby restricting the code to sequences, when it would work perfectly well for any

[issue38215] Do not import modules in star-import when __all__ is not defined.

2019-09-18 Thread Ethan Furman
Ethan Furman added the comment: It's the casual users' code that will break. -- ___ Python tracker ___ ___ Python-bugs-list

[issue38215] Do not import modules in star-import when __all__ is not defined.

2019-09-18 Thread Serhiy Storchaka
Serhiy Storchaka added the comment: I believe that significant part or even most of code is writing without using linters and type checkers. Python is too convenient for non-professional programmers. You do not need to declare all variables with their types to use Python and do not need to

[issue38218] SyntaxError in Tutorial 8.6 Defining Clean-up Actions

2019-09-18 Thread Roundup Robot
Change by Roundup Robot : -- keywords: +patch pull_requests: +15858 stage: -> patch review pull_request: https://github.com/python/cpython/pull/16265 ___ Python tracker ___

[issue38215] Do not import modules in star-import when __all__ is not defined.

2019-09-18 Thread Karthikeyan Singaravelan
Change by Karthikeyan Singaravelan : -- nosy: +xtreak ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscribe:

[issue38218] SyntaxError in Tutorial 8.6 Defining Clean-up Actions

2019-09-18 Thread Jason Plurad
New submission from Jason Plurad : The second code example in Tutorial section 8.6 defines the function: def bool_return(): -> bool: which throws a SyntaxError: invalid syntax If the function wants to use a return annotation, there should not be a colon after the function name. I have a

[issue38215] Do not import modules in star-import when __all__ is not defined.

2019-09-18 Thread Brett Cannon
Change by Brett Cannon : -- nosy: +brett.cannon ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscribe:

[issue38215] Do not import modules in star-import when __all__ is not defined.

2019-09-18 Thread Ethan Furman
Ethan Furman added the comment: I don't think this is worth the code breakage. The advice already given is not to use `import *` unless: - the module was designed for that usage; or - you know what you are doing. -- nosy: +ethan.furman ___ Python

[issue38217] argparse should support multiple types when nargs > 1

2019-09-18 Thread paul j3
paul j3 added the comment: Which is more valuable to you, the string conversion, or the checking? What's wrong with doing the 'type check' in post parsing code? (MarSoft's answer in the SO link). To make a better case for this, I'd suggest writing your own fix. It doesn't need to be a

[issue38217] argparse should support multiple types when nargs > 1

2019-09-18 Thread Karthikeyan Singaravelan
Change by Karthikeyan Singaravelan : -- nosy: +paul.j3, rhettinger versions: -Python 2.7, Python 3.5, Python 3.6, Python 3.7, Python 3.8 ___ Python tracker ___

[issue36274] http.client cannot send non-ASCII request lines

2019-09-18 Thread Karthikeyan Singaravelan
Karthikeyan Singaravelan added the comment: > @xtreak the encoded null-byte test would be an extra test case to consider. > It is reasonable to test as many known invalid sequences as possible. > Changing that byte to encoded notation would just replace one test with > another effectively

[issue38204] Cannot compile on RPi with optimizations

2019-09-18 Thread Thomas Knox
Thomas Knox added the comment: I updated binutils: pi@pi4b:~/Downloads/Python-3.8.0b4 $ ld --version GNU ld (GNU Binutils) 2.32 Same problem. -- ___ Python tracker ___

[issue38215] Do not import modules in star-import when __all__ is not defined.

2019-09-18 Thread Guido van Rossum
Guido van Rossum added the comment: I feel that this is a relatively minor issue, and not worth breaking "working" code over. Some more pedantic tool like a linter or type checker would be a better place to start diagnosing this. -- ___ Python

[issue38217] argparse should support multiple types when nargs > 1

2019-09-18 Thread Ryan Govostes
New submission from Ryan Govostes : argparse supports consuming multiple command-line arguments with nargs=2, etc. It converts them to the type given in the argument's type parameter. argparse does not provide a good solution when the input arguments should be different data types. For an

[issue38216] Fix for issue30458 prevents crafting invalid requests

2019-09-18 Thread Sviatoslav Sydorenko
Change by Sviatoslav Sydorenko : -- nosy: +webknjaz ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscribe:

[issue38216] Fix for issue30458 prevents crafting invalid requests

2019-09-18 Thread Karthikeyan Singaravelan
Change by Karthikeyan Singaravelan : -- nosy: +xtreak ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscribe:

[issue17258] multiprocessing.connection challenge implicitly uses MD5

2019-09-18 Thread Charalampos Stratakis
Change by Charalampos Stratakis : -- pull_requests: +15857 pull_request: https://github.com/python/cpython/pull/16264 ___ Python tracker ___

[issue36274] http.client cannot send non-ASCII request lines

2019-09-18 Thread Jason R. Coombs
Jason R. Coombs added the comment: I've created issue38216 to address the issue of sending invalid bytes in the request line, separate from the original intention and title issue about sending non-ASCII. -- ___ Python tracker

[issue38216] Fix for issue30458 prevents crafting invalid requests

2019-09-18 Thread Jason R. Coombs
New submission from Jason R. Coombs : The fix for issue30458 prevents any request line from transmitting non-ascii characters. In some cases, it's useful to transmit these illegal bytes in order to simulate a maliciously-crafted request (such as to ensure a web server responds correctly to

[issue38204] Cannot compile on RPi with optimizations

2019-09-18 Thread Ammar Askar
Ammar Askar added the comment: Hmm, I think this might be the following gcc/binutils bug: https://gcc.gnu.org/bugzilla/show_bug.cgi?id=84847 https://sourceware.org/bugzilla/show_bug.cgi?id=20882 This might be a bit of a pain but could you try updating binutils and see if the problem

[issue38215] Do not import modules in star-import when __all__ is not defined.

2019-09-18 Thread Serhiy Storchaka
Change by Serhiy Storchaka : -- keywords: +patch pull_requests: +15856 stage: -> patch review pull_request: https://github.com/python/cpython/pull/16263 ___ Python tracker

[issue38215] Do not import modules in star-import when __all__ is not defined.

2019-09-18 Thread Serhiy Storchaka
New submission from Serhiy Storchaka : If __all__ is not defined in a module "from module import *" will import all keys from module.__dict__ which does not start with underscore. It can add undesired names to the current namespace. The common case is related to importing modules. 1.

[issue38205] Python no longer compiles without small integer singletons

2019-09-18 Thread Zachary Ware
Zachary Ware added the comment: Whoops :(. Fixing this is beyond my C skill. I'd rather not lose the easter egg, but if it can't be fixed properly then 3ab61473ba7f3dca32d779ec2766a4faa0657923 should just be reverted. -- nosy: +gregory.p.smith

[issue38204] Cannot compile on RPi with optimizations

2019-09-18 Thread Thomas Knox
Thomas Knox added the comment: I'll be more than happy to buy you an RPi to do testing on. -- ___ Python tracker ___ ___

[issue38204] Cannot compile on RPi with optimizations

2019-09-18 Thread Thomas Knox
Thomas Knox added the comment: pi@pi4b:~ $ gcc --version gcc (Raspbian 8.3.0-6+rpi1) 8.3.0 pi@pi4b:~ $ ld --version GNU ld (GNU Binutils for Raspbian) 2.31.1 -- ___ Python tracker

[issue35696] remove unnecessary operation in long_compare()

2019-09-18 Thread Inada Naoki
Change by Inada Naoki : -- resolution: -> fixed stage: patch review -> resolved status: open -> closed versions: +Python 3.9 -Python 3.8 ___ Python tracker ___

[issue35696] remove unnecessary operation in long_compare()

2019-09-18 Thread Inada Naoki
Inada Naoki added the comment: New changeset 42acb7b8d29d078bc97b0cfd7c4911b2266b26b9 by Inada Naoki (HongWeipeng) in branch 'master': bpo-35696: Simplify long_compare() (GH-16146) https://github.com/python/cpython/commit/42acb7b8d29d078bc97b0cfd7c4911b2266b26b9 -- nosy:

[issue30458] [security][CVE-2019-9740][CVE-2019-9947] HTTP Header Injection (follow-up of CVE-2016-5699)

2019-09-18 Thread Jason R. Coombs
Jason R. Coombs added the comment: > Should we open a separate issue to track (fixing) the regression? Yes, I think so. The ticket I referenced mainly addresses an incompatibility that was introduced with Python 3.0, so is much less urgent than the one introduced more recently, so I believe

[issue37531] Fix regrtest timeout for subprocesses: regrtest -jN --timeout=SECONDS

2019-09-18 Thread STINNER Victor
STINNER Victor added the comment: It seems like the new regrtest design doesn't work as I expected. Calling popen.kill() + popen.stdout.close() + popen.stderr.close() from a thread B does not always interrupt popen.communicate() in thread A. See https://bugs.python.org/issue38207#msg352729

[issue38207] subprocess: On Windows, Popen.kill() + Popen.communicate() is blocking until all processes using the pipe close the pipe

2019-09-18 Thread STINNER Victor
STINNER Victor added the comment: Hum, I see a similar behavior on Linux. Try attached communicate_close.py (I added newlines for readability): --- vstinner@apu$ python3 communicate_close.py process 1: pid 13089 process 1: process 2 spawned (pid 13090) process 1: stdout pipe

[issue38214] __reduce__ API specs for objects with __slots__

2019-09-18 Thread Guido Imperiale
New submission from Guido Imperiale : The documentation for the pickle module states, about the 3rd element of the tuple returned by __reduce__: Optionally, the object’s state, which will be passed to the object’s __setstate__() method as previously described. If the object has no such

[issue30458] [security][CVE-2019-9740][CVE-2019-9947] HTTP Header Injection (follow-up of CVE-2016-5699)

2019-09-18 Thread Larry Hastings
Larry Hastings added the comment: Should we open a separate issue to track fixing the regression? -- ___ Python tracker ___ ___

[issue37531] Fix regrtest timeout for subprocesses: regrtest -jN --timeout=SECONDS

2019-09-18 Thread STINNER Victor
STINNER Victor added the comment: Oh wait, test_regrtest.test_multiprocessing_timeout() now also hangs on FreeBSD? :-( AMD64 FreeBSD CURRENT Shared 3.8: https://buildbot.python.org/all/#/builders/212/builds/226 running: test_regrtest (24 min 52 sec) 0:32:54 load avg: 0.26 [423/423/1]

[issue36274] http.client cannot send non-ASCII request lines

2019-09-18 Thread Sviatoslav Sydorenko
Sviatoslav Sydorenko added the comment: @xtreak the encoded null-byte test would be an extra test case to consider. It is reasonable to test as many known invalid sequences as possible. Changing that byte to encoded notation would just replace one test with another effectively changing the

[issue38203] regrtest fails to stop test_multiprocessing_spawn worker process

2019-09-18 Thread miss-islington
miss-islington added the comment: New changeset 1a3a48ddaf41dff3c0fcedcfe7ec0940158c568d by Miss Islington (bot) in branch '3.7': bpo-38203: faulthandler.dump_traceback_later() is always available (GH-16260) https://github.com/python/cpython/commit/1a3a48ddaf41dff3c0fcedcfe7ec0940158c568d

[issue38203] regrtest fails to stop test_multiprocessing_spawn worker process

2019-09-18 Thread STINNER Victor
STINNER Victor added the comment: New changeset 064e1e384120635330493abf300b1113eadd904c by Victor Stinner in branch '3.8': bpo-38203: faulthandler.dump_traceback_later() is always available (GH-16260) https://github.com/python/cpython/commit/064e1e384120635330493abf300b1113eadd904c

[issue38203] regrtest fails to stop test_multiprocessing_spawn worker process

2019-09-18 Thread miss-islington
Change by miss-islington : -- pull_requests: +15855 pull_request: https://github.com/python/cpython/pull/16261 ___ Python tracker ___

[issue38203] regrtest fails to stop test_multiprocessing_spawn worker process

2019-09-18 Thread STINNER Victor
Change by STINNER Victor : -- pull_requests: +15854 pull_request: https://github.com/python/cpython/pull/16260 ___ Python tracker ___

[issue38203] regrtest fails to stop test_multiprocessing_spawn worker process

2019-09-18 Thread STINNER Victor
STINNER Victor added the comment: New changeset 0a963fbc9c4cf4569f1eadaa2aa1229bb0081256 by Victor Stinner in branch 'master': bpo-38203: faulthandler.dump_traceback_later() is always available (GH-16249) https://github.com/python/cpython/commit/0a963fbc9c4cf4569f1eadaa2aa1229bb0081256

[issue38070] visit_decref(): add an assertion to check that the object is not freed

2019-09-18 Thread STINNER Victor
STINNER Victor added the comment: Ok, I pushed the most important changes that I wanted to push. I close the issue. -- resolution: -> fixed stage: patch review -> resolved status: open -> closed versions: +Python 3.8 ___ Python tracker

[issue38070] visit_decref(): add an assertion to check that the object is not freed

2019-09-18 Thread STINNER Victor
STINNER Victor added the comment: New changeset 47bbab9f76735acc1991e541d12fd18be6b13b16 by Victor Stinner in branch '3.8': [3.8] bpo-38070: Py_FatalError() logs runtime state (GH-16258) https://github.com/python/cpython/commit/47bbab9f76735acc1991e541d12fd18be6b13b16 --

[issue38213] sys.maxsize returns incorrect docstring.

2019-09-18 Thread Steven D'Aprano
Steven D'Aprano added the comment: This is not a bug. ``sys.maxsize`` is just an int instance, and it has no docstring itself. When you look up ``sys.maxsize.__doc__``, or call ``help(sys.maxsize)``, the ordinary inheritance rules apply and you get the class docstring. There is nothing

[issue38213] sys.maxsize returns incorrect docstring.

2019-09-18 Thread Akash Shende
Akash Shende added the comment: Yes. I checked that. Same for sys.maxunicode -- ___ Python tracker ___ ___ Python-bugs-list

[issue38213] sys.maxsize returns incorrect docstring.

2019-09-18 Thread Karthikeyan Singaravelan
Karthikeyan Singaravelan added the comment: sys.maxsize returns an integer so essentially sys.maxsize.__doc__ is giving docs for int.__doc__. help(sys) to get to maxsize would help. maxsize -- the largest supported length of containers. python3 Python 3.8.0b4 (v3.8.0b4:d93605de72, Aug 29

[issue38213] sys.maxsize returns incorrect docstring.

2019-09-18 Thread Akash Shende
New submission from Akash Shende : >>> import sys >>> print(sys.maxsize.__doc__) int([x]) -> integer int(x, base=10) -> integer Convert a number or string to an integer, or return 0 if no arguments are given. If x is a number, return x.__int__(). For floating point numbers, this truncates

[issue37904] Suggested edit to Python Tutorial - Section 4

2019-09-18 Thread Eric V. Smith
Change by Eric V. Smith : -- resolution: -> fixed stage: patch review -> resolved status: open -> closed ___ Python tracker ___

[issue37904] Suggested edit to Python Tutorial - Section 4

2019-09-18 Thread Eric V. Smith
Eric V. Smith added the comment: New changeset c47c8ba2969c9faf1c036b3dc4b0a5cf0d3aa0cc by Eric V. Smith (Miss Islington (bot)) in branch '2.7': bpo-37904: Edition on python tutorial - section 4 (GH-16169) (GH-16236)

[issue37904] Suggested edit to Python Tutorial - Section 4

2019-09-18 Thread Eric V. Smith
Eric V. Smith added the comment: New changeset 8b907a8875d1b22d8f060dee9430cc82d471e86b by Eric V. Smith (Miss Islington (bot)) in branch '3.7': bpo-37904: Edition on python tutorial - section 4 (GH-16169) (GH-16235)

[issue37904] Suggested edit to Python Tutorial - Section 4

2019-09-18 Thread Eric V. Smith
Eric V. Smith added the comment: New changeset 7a2f68776a77c782c0abf40dc9e3fb687787e730 by Eric V. Smith (Miss Islington (bot)) in branch '3.8': bpo-37904: Edition on python tutorial - section 4 (GH-16169) (GH-16234)

[issue38070] visit_decref(): add an assertion to check that the object is not freed

2019-09-18 Thread STINNER Victor
Change by STINNER Victor : -- pull_requests: +15853 pull_request: https://github.com/python/cpython/pull/16258 ___ Python tracker ___

[issue38212] test_multiprocessing_spawn: test_queue_feeder_donot_stop_onexc() failed on x86 Windows7 3.x

2019-09-18 Thread STINNER Victor
New submission from STINNER Victor : x86 Windows7 3.x: https://buildbot.python.org/all/#/builders/58/builds/3015 If I recall correctly, this buildbot is known to be slow. It sounds like a race condition. ERROR: test_queue_feeder_donot_stop_onexc

[issue36274] http.client cannot send non-ASCII request lines

2019-09-18 Thread Karthikeyan Singaravelan
Karthikeyan Singaravelan added the comment: Is there a reason why cherrypy doesn't URL encode the null byte in this test as per comment : https://github.com/cherrypy/cherrypy/issues/1781#issuecomment-504476658 ? The original fix was adopted from golang

[issue38211] clean up type_init()

2019-09-18 Thread Sergey Fedoseev
Change by Sergey Fedoseev : -- keywords: +patch pull_requests: +15852 stage: -> patch review pull_request: https://github.com/python/cpython/pull/16257 ___ Python tracker ___

[issue38211] clean up type_init()

2019-09-18 Thread Sergey Fedoseev
New submission from Sergey Fedoseev : I wrote patch that cleans up type_init(): 1. Removes conditions already checked by assert() 2. Removes object_init() call that effectively creates an empty tuple and checks that this tuple is empty -- messages: 352710 nosy: sir-sigurd priority:

[issue37812] Make implicit returns explicit in longobject.c (in CHECK_SMALL_INT)

2019-09-18 Thread STINNER Victor
STINNER Victor added the comment: Raymond: > We're wasted a lot of dev time on something that never promised much value in > the first place. I'm one of the first to advocate to replace ugly macros with clean static inline functions. Macros are evil and can be too easily misused. On PR

[issue38205] Python no longer compiles without small integer singletons

2019-09-18 Thread STINNER Victor
STINNER Victor added the comment: > Before the mentioned commit Py_UNREACHABLE() was an expression, now it's a > block. Right, it was changed by: commit 3ab61473ba7f3dca32d779ec2766a4faa0657923 Author: Zachary Ware Date: Thu Sep 12 13:35:48 2019 +0100 Enhance Py_UNREACHABLE macro

[issue35866] concurrent.futures deadlock

2019-09-18 Thread bentoi
bentoi added the comment: FYI, I'm getting a similar deadlock in a child Python process which is stuck on locking a mutex from the dl library. See attached stack. I'm not using concurrent.futures however, the parent Python process is a test driver that uses threading.Thread and

[issue27575] dict viewkeys intersection slow for large dicts

2019-09-18 Thread Serhiy Storchaka
Serhiy Storchaka added the comment: This changed behavior. See issue38210. See also issue38202 for other regression. -- status: closed -> open ___ Python tracker ___

[issue27575] dict viewkeys intersection slow for large dicts

2019-09-18 Thread Serhiy Storchaka
Change by Serhiy Storchaka : -- status: open -> closed ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscribe:

[issue27575] dict viewkeys intersection slow for large dicts

2019-09-18 Thread Serhiy Storchaka
Change by Serhiy Storchaka : -- versions: +Python 3.9 -Python 3.6 ___ Python tracker ___ ___ Python-bugs-list mailing list

[issue38210] Intersection of dict view with iterator returns empty set

2019-09-18 Thread Serhiy Storchaka
New submission from Serhiy Storchaka : In 3.8: >>> {1: 2, 3: 4}.keys() & {1, 2} {1} In master: >>> {1: 2, 3: 4}.keys() & iter([1, 2]) set() The behavior was changed in issue27575. -- components: Interpreter Core messages: 352705 nosy: rhettinger, serhiy.storchaka priority: normal

[issue27575] dict viewkeys intersection slow for large dicts

2019-09-18 Thread Serhiy Storchaka
Serhiy Storchaka added the comment: I am puzzled why we still call set.intersection_update with empty set? -- nosy: +serhiy.storchaka ___ Python tracker ___

[issue38205] Python no longer compiles without small integer singletons

2019-09-18 Thread Sergey Fedoseev
Sergey Fedoseev added the comment: Also quote from Py_UNREACHABLE() doc: > Use this in places where you might be tempted to put an assert(0) or abort() > call. https://github.com/python/cpython/commit/6b519985d23bd0f0bd072b5d5d5f2c60a81a19f2 does exactly that, it replaces assert(0) with

[issue38208] Simplify string.Template by using __init_subclass__()

2019-09-18 Thread Serhiy Storchaka
Change by Serhiy Storchaka : -- keywords: +patch pull_requests: +15851 stage: -> patch review pull_request: https://github.com/python/cpython/pull/16256 ___ Python tracker

[issue38209] Simplify dataclasses.InitVar by using __class_getitem__()

2019-09-18 Thread Serhiy Storchaka
Change by Serhiy Storchaka : -- keywords: +patch pull_requests: +15850 stage: -> patch review pull_request: https://github.com/python/cpython/pull/16255 ___ Python tracker

[issue38209] Simplify dataclasses.InitVar by using __class_getitem__()

2019-09-18 Thread Serhiy Storchaka
New submission from Serhiy Storchaka : Currently dataclasses.InitVar uses a metaclass. It is possible to get rid of it and use __class_getitem__() instead. -- components: Library (Lib) messages: 352702 nosy: eric.smith, serhiy.storchaka priority: normal severity: normal status: open

[issue38203] regrtest fails to stop test_multiprocessing_spawn worker process

2019-09-18 Thread STINNER Victor
STINNER Victor added the comment: New changeset da57599af51c602b015b6880123fef6eccdabcf5 by Victor Stinner in branch 'master': bpo-38203: regrtest: put a 2 min timeout on Python exit (GH-16250) https://github.com/python/cpython/commit/da57599af51c602b015b6880123fef6eccdabcf5 --

  1   2   >