[issue35395] Typo in asyncio eventloop documentation

2018-12-03 Thread miss-islington
miss-islington added the comment: New changeset 6627d3ae1e151095fda4ec2592c7cfb759f23669 by Miss Islington (bot) in branch '3.7': bpo-35395: fix typos in asyncio eventloop documentation (GH-10880) https://github.com/python/cpython/commit/6627d3ae1e151095fda4ec2592c7cfb759f23669 --

[issue35395] Typo in asyncio eventloop documentation

2018-12-03 Thread miss-islington
Change by miss-islington : -- pull_requests: +10123 ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscribe:

[issue35395] Typo in asyncio eventloop documentation

2018-12-03 Thread miss-islington
miss-islington added the comment: New changeset 17473347942353946fe455f797a2197cb89c1090 by Miss Islington (bot) (Naglis) in branch 'master': bpo-35395: fix typos in asyncio eventloop documentation (GH-10880) https://github.com/python/cpython/commit/17473347942353946fe455f797a2197cb89c1090

[issue35402] Upgrade macOS (and Windows?) installer to Tcl/Tk 8.6.9.1

2018-12-03 Thread Ned Deily
New submission from Ned Deily : Tcl/Tk 8.6.9 (followed by Tk 8.6.9.1) was released recently. Among other things, they contain fixes for various issues on macOS, some of which have been seen by macOS users of IDLE and other tkinter apps, so the macOS installer should definitely be updated

[issue35401] Upgrade Windows and macOS installers to use OpenSSL 1.1.0j / 1.0.2q

2018-12-03 Thread Ned Deily
New submission from Ned Deily : New versions of OpenSSL were released on 2018-11-20. We should update for 3.7.2, 3.6.8, and 2.7.16. -- assignee: christian.heimes components: SSL, Windows, macOS messages: 331010 nosy: benjamin.peterson, christian.heimes, ned.deily, paul.moore,

[issue34172] multiprocessing.Pool and ThreadPool leak resources after being deleted

2018-12-03 Thread tzickel
tzickel added the comment: Reverting the code will cause another class of problems, like the reason I fixed it. Programs written such as the example that Pablo gave (and what I've seen) will quietly leak child processes, file descriptors (for the pipes) and memory to a variety degree might

[issue35399] Sysconfig bug

2018-12-03 Thread Jorge Ramos
Change by Jorge Ramos : -- components: +Build ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscribe:

[issue35400] PGOMGR : warning PG0188:

2018-12-03 Thread Jorge Ramos
New submission from Jorge Ramos : The following command: Tools\msi\buildrelease.bat -x64 is used to build a 64 bit version (on win_10_64) of python (using visual studio 2017). The following modules did not build correctly because, presumably, the corresponding .PGC files could not be

[issue35399] Sysconfig bug

2018-12-03 Thread Jorge Ramos
New submission from Jorge Ramos : As can be seen in the file, the sysconfig test fails when profiling (PGO) this utility. This is the very same bug as described in issue#35299 https://bugs.python.org/issue35299 but in distutils. The problem is that when the test for sysconfig runs, it does

[issue35398] SQLite incorrect row count for UPDATE

2018-12-03 Thread mike bayer
Change by mike bayer : -- nosy: +zzzeek ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscribe:

[issue11107] Cache constant "slice" instances

2018-12-03 Thread Josh Rosenberg
Change by Josh Rosenberg : -- versions: +Python 3.8 -Python 3.5 ___ Python tracker ___ ___ Python-bugs-list mailing list

[issue35398] SQLite incorrect row count for UPDATE

2018-12-03 Thread Montana Low
New submission from Montana Low : SQLite driver returns an incorrect row count (-1) for UPDATE statements that begin with a comment. Downstream Reference: https://github.com/sqlalchemy/sqlalchemy/issues/4396 Test Case: ``` import sqlite3 conn = sqlite3.connect(":memory:") cursor =

[issue35390] ctypes not possible to pass NULL c_void_p in structure by reference

2018-12-03 Thread Eryk Sun
Eryk Sun added the comment: Your example uses POINTER(c_double), not c_void_p. There's no problem with an actual pointer object (i.e. subclass of ctypes._Pointer). The problem is with simple types (i.e. immediate subclasses of ctypes._SimpleCData), including simple pointer types (i.e.

[issue35305] subprocess.Popen(['/sbin/ldconfig', '-p'], stdin=PIPE) itself hangs/deadlocks (Linux)

2018-12-03 Thread HenrikB
HenrikB added the comment: Thank you both for the comments and suggests. Before I'm getting to the "interesting" part, first to the "easy" one: >> What is also useful to know, is that I'm observing this on a legacy RHEL 6 >> system *with a customized kernel* part of the Scyld ClusterWare

[issue9338] argparse optionals with nargs='?', '*' or '+' can't be followed by positionals

2018-12-03 Thread kernc
Change by kernc : -- nosy: +kernc ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscribe:

[issue35373] PyInit_timezone() must return a value

2018-12-03 Thread STINNER Victor
Change by STINNER Victor : -- resolution: -> fixed stage: patch review -> resolved status: open -> closed ___ Python tracker ___

[issue35397] Undeprecate and document urllib.parse.unwrap

2018-12-03 Thread Steven D'Aprano
New submission from Steven D'Aprano : The urllib.parse module contains an undocumented function unwrap: unwrap('') --> 'type://host/path' This is useful. I've been re-inventing this function in many of my scripts, because I didn't know it existed (not documented!) and only stumbled

[issue35390] ctypes not possible to pass NULL c_void_p in structure by reference

2018-12-03 Thread Martin Panter
Martin Panter added the comment: This problem is common to structure fields in general, not just "c_void_p". I recently encountered it with a different type (don't remember the type now, but I notice plain types like c_int share the problem). I found

[issue35373] PyInit_timezone() must return a value

2018-12-03 Thread miss-islington
miss-islington added the comment: New changeset f455353bc0d195e092f09fec92ed16e9be02b7b1 by Miss Islington (bot) in branch '3.6': [3.7] bpo-35373: Fix PyInit_timezone() error handling (GH-10864) https://github.com/python/cpython/commit/f455353bc0d195e092f09fec92ed16e9be02b7b1 --

[issue35373] PyInit_timezone() must return a value

2018-12-03 Thread STINNER Victor
STINNER Victor added the comment: In Python 2.7, inittimezone() is simpler and so less likely to fail. I propose to leave Python 2.7 unchanged. -- versions: +Python 3.6, Python 3.7, Python 3.8 ___ Python tracker

[issue34172] multiprocessing.Pool and ThreadPool leak resources after being deleted

2018-12-03 Thread Pablo Galindo Salgado
Pablo Galindo Salgado added the comment: > I disagree that a child should keep its parent alive. But this is normal across the standard library. For example, here is how a deque iterator keeps the deque alive: >>> x = deque([1,2,3]) >>> deque_iter = iter(x) >>> deque_weakref =

[issue35373] PyInit_timezone() must return a value

2018-12-03 Thread miss-islington
Change by miss-islington : -- pull_requests: +10122 ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscribe:

[issue35373] PyInit_timezone() must return a value

2018-12-03 Thread STINNER Victor
STINNER Victor added the comment: New changeset 5eb78c75128187a36d8e983027632fa51cc2ff4d by Victor Stinner in branch '3.7': [3.7] bpo-35373: Fix PyInit_timezone() error handling (GH-10864) https://github.com/python/cpython/commit/5eb78c75128187a36d8e983027632fa51cc2ff4d --

[issue34172] multiprocessing.Pool and ThreadPool leak resources after being deleted

2018-12-03 Thread STINNER Victor
STINNER Victor added the comment: > I found the weird code in the example in several projects. I have corrected > it to use the pool as a context manager or to call close(), but this means > that users are doing this and it used to work and not it does not: > technically is a regression.

[issue34172] multiprocessing.Pool and ThreadPool leak resources after being deleted

2018-12-03 Thread Pablo Galindo Salgado
Pablo Galindo Salgado added the comment: > I'm not comfortable with the fix. I cannot explain why but I feel like adding > a strong dependency from a child to its parent is going to lead to more bugs, > not less. It sounds like a recipe for reference cycles. Maybe I'm just plain > wrong.

[issue34172] multiprocessing.Pool and ThreadPool leak resources after being deleted

2018-12-03 Thread Pablo Galindo Salgado
Change by Pablo Galindo Salgado : -- Removed message: https://bugs.python.org/msg330995 ___ Python tracker ___ ___ Python-bugs-list

[issue34172] multiprocessing.Pool and ThreadPool leak resources after being deleted

2018-12-03 Thread Pablo Galindo Salgado
Pablo Galindo Salgado added the comment: > I'm not comfortable with the fix. I cannot explain why but I feel like adding > a strong dependency from a child to its parent is going to lead to more bugs, > not less. It sounds like a recipe for reference cycles. Maybe I'm just plain > wrong.

[issue34172] multiprocessing.Pool and ThreadPool leak resources after being deleted

2018-12-03 Thread Pablo Galindo Salgado
Change by Pablo Galindo Salgado : -- Removed message: https://bugs.python.org/msg330994 ___ Python tracker ___ ___ Python-bugs-list

[issue34172] multiprocessing.Pool and ThreadPool leak resources after being deleted

2018-12-03 Thread Pablo Galindo Salgado
Pablo Galindo Salgado added the comment: > I'm not comfortable with the fix. I cannot explain why but I feel like adding > a strong dependency from a child to its parent is going to lead to more bugs, > not less. It sounds like a recipe for reference cycles. Maybe I'm just plain > wrong.

[issue35377] urlparse doesn't validate the scheme

2018-12-03 Thread Steven D'Aprano
Steven D'Aprano added the comment: I'm changing the name to better describe the problem, and suggest a better solution. The urlparse.urlsplit and .urlunsplit functions currently don't validate the scheme argument, if given. According to the RFC: Scheme names consist of a sequence of

[issue35396] Add support for __fspath__ to fnmatch.fnmatchase and filter

2018-12-03 Thread Andrés Delfino
Change by Andrés Delfino : -- keywords: +patch pull_requests: +10121 stage: -> patch review ___ Python tracker ___ ___

[issue35396] Add support for __fspath__ to fnmatch.fnmatchase and filter

2018-12-03 Thread Andrés Delfino
New submission from Andrés Delfino : Both fnmatch.fnmatchase and fnmatch.filter (in Unix) do not support path-like objects. This is inconvenient, for example, when taking advantage of os.scandir and working with os.DirEntry objets. Also, fnmatch.filter in Windows does support path-like

[issue35395] Typo in asyncio eventloop documentation

2018-12-03 Thread Andrew Svetlov
Andrew Svetlov added the comment: Would you create a PR with a fix? -- nosy: +asvetlov ___ Python tracker ___ ___ Python-bugs-list

[issue35395] Typo in asyncio eventloop documentation

2018-12-03 Thread Andrew Svetlov
Andrew Svetlov added the comment: Sorry, you did already -- ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscribe:

[issue35395] Typo in asyncio eventloop documentation

2018-12-03 Thread Naglis
Change by Naglis : -- keywords: +patch pull_requests: +10119 stage: -> patch review ___ Python tracker ___ ___ Python-bugs-list

[issue35395] Typo in asyncio eventloop documentation

2018-12-03 Thread Naglis
New submission from Naglis : loop.add_writer and loop.add_signal_handler have *callback* in their signatures, but in their documentation regarding functools.partial usage the function is referred to as *func*. -- assignee: docs@python components: Documentation messages: 330989 nosy:

[issue34172] multiprocessing.Pool and ThreadPool leak resources after being deleted

2018-12-03 Thread STINNER Victor
STINNER Victor added the comment: tzickel: > A. The documentation explicitly says: "When the pool object is garbage > collected terminate() will be called immediately." (Happened till a code > refactor 9 years ago introduced this bug). It is a *very bad* practice to rely on __del__. Don't do

[issue17185] unittest mock create_autospec doesn't correctly replace mocksignature

2018-12-03 Thread Chris Withers
Chris Withers added the comment: xtreak - great to see action on this! First step would be to add a unit test for the failure case I reported. I like the tests you have too, but would be good to see the specific failure case covered too. Beyond that, if we can get all the the new tests

[issue35226] mock.call equality surprisingly broken

2018-12-03 Thread Chris Withers
Change by Chris Withers : -- stage: patch review -> resolved status: open -> closed ___ Python tracker ___ ___ Python-bugs-list

[issue35394] Add __slots__ = () to asyncio protocols

2018-12-03 Thread Andrew Svetlov
New submission from Andrew Svetlov : Protocols have no members. Adding empty slots doesn't harm any existing code but it allows to write proper protocol implementation with slot-based class. -- components: asyncio messages: 330986 nosy: asvetlov, yselivanov priority: normal severity:

[issue35226] mock.call equality surprisingly broken

2018-12-03 Thread Chris Withers
Chris Withers added the comment: New changeset e8f9e4785caeef8a68bb7859280e91a4cb424b79 by Chris Withers (Miss Islington (bot)) in branch '3.7': bpo-35226: Fix equality for nested unittest.mock.call objects. (GH-10555)

[issue35226] mock.call equality surprisingly broken

2018-12-03 Thread Chris Withers
Chris Withers added the comment: New changeset 67e6136a6d5c07141d4dba820c450a70db7aedd5 by Chris Withers (Miss Islington (bot)) in branch '3.6': bpo-35226: Fix equality for nested unittest.mock.call objects. (GH-10555)

[issue35226] mock.call equality surprisingly broken

2018-12-03 Thread miss-islington
Change by miss-islington : -- pull_requests: +10118 ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscribe:

[issue35226] mock.call equality surprisingly broken

2018-12-03 Thread Chris Withers
Chris Withers added the comment: New changeset 8ca0fa9d2f4de6e69f0902790432e0ab2f37ba68 by Chris Withers in branch 'master': bpo-35226: Fix equality for nested unittest.mock.call objects. (#10555) https://github.com/python/cpython/commit/8ca0fa9d2f4de6e69f0902790432e0ab2f37ba68 --

[issue35226] mock.call equality surprisingly broken

2018-12-03 Thread miss-islington
Change by miss-islington : -- pull_requests: +10117 ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscribe:

[issue35380] Enable TCP_NODELAY for proactor event loop

2018-12-03 Thread Andrew Svetlov
Andrew Svetlov added the comment: New changeset fe91e9ba08a8854e2149398386702828fe3c0038 by Andrew Svetlov (Miss Islington (bot)) in branch '3.7': [3.7] bpo-35380: Enable TCP_NODELAY for proactor event loop (GH-10867) (GH-10872)

[issue35310] select which was interrupted by EINTR isn't re-run if the timeout has passed

2018-12-03 Thread Oran Avraham
Change by Oran Avraham : -- pull_requests: +10116 ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscribe:

[issue35387] Dialogs on IDLE are accompanied by a small black window

2018-12-03 Thread Terry J. Reedy
Terry J. Reedy added the comment: I just updated my Macbook to Mohave. As implied, I do not see this on installed 3.7.1 with 8.6.8. But this is a heads-up for future releases. Someone with both a Mac Python development environment + tip 8.6 would have to look at this now. When the

[issue35393] Typo in documentation

2018-12-03 Thread Filip Bengtsson
Filip Bengtsson added the comment: https://github.com/python/cpython/pull/10876/commits/00f39c15a13377f3920c72267b2b78a043d9b8ab -- ___ Python tracker ___

[issue35335] msgfmt should be able to merge more than one po file

2018-12-03 Thread s-ball
s-ball added the comment: Currently my main use case is to be able to compile one or more po file(s) from a Python script, so I just need to be able to repeatedly call make from that script - which was broken per issue 9741 To be honest, I must acknowledge that I initially thought that

[issue35393] Typo in documentation

2018-12-03 Thread Eric V. Smith
Eric V. Smith added the comment: Can you be more specific? There's not enough information here to take any action. -- nosy: +eric.smith ___ Python tracker ___

[issue35335] msgfmt should be able to merge more than one po file

2018-12-03 Thread Éric Araujo
Éric Araujo added the comment: I am curious about the use cases for this feature! -- ___ Python tracker ___ ___ Python-bugs-list

[issue35335] msgfmt should be able to merge more than one po file

2018-12-03 Thread SilentGhost
Change by SilentGhost : -- nosy: +eric.araujo, ezio.melotti ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscribe:

[issue35377] urlsplit scheme argument broken

2018-12-03 Thread devkral
devkral added the comment: ah, I get the idea behind urlunsplit. But still: for e.g. http, http:/// is invalid. These urls are invalid for e.g. requests. May I ask: urllib.parse is for web protocol urls? If yes, then there should be an option which defaults to my version. --

[issue35393] Typo in documentation

2018-12-03 Thread Filip Bengtsson
New submission from Filip Bengtsson : There are 256 characters in the range 0–255. -- assignee: docs@python components: Documentation messages: 330975 nosy: autom, docs@python priority: normal pull_requests: 10114 severity: normal status: open title: Typo in documentation

[issue9741] msgfmt.py generates invalid mo because msgfmt.make() does not clear dictionary

2018-12-03 Thread s-ball
Change by s-ball : -- pull_requests: +10113 stage: test needed -> patch review ___ Python tracker ___ ___ Python-bugs-list mailing

[issue35335] msgfmt should be able to merge more than one po file

2018-12-03 Thread s-ball
Change by s-ball : -- keywords: +patch pull_requests: +10112 stage: -> patch review ___ Python tracker ___ ___ Python-bugs-list

[issue35380] Enable TCP_NODELAY for proactor event loop

2018-12-03 Thread Andrew Svetlov
Change by Andrew Svetlov : -- pull_requests: +10111 ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscribe:

[issue35357] unittest.mock.call can't represent calls to a method called 'parent'

2018-12-03 Thread Andrew Dunai
Change by Andrew Dunai : -- keywords: +patch pull_requests: +10110 stage: -> patch review ___ Python tracker ___ ___

[issue35380] Enable TCP_NODELAY for proactor event loop

2018-12-03 Thread Andrew Svetlov
Andrew Svetlov added the comment: New changeset 3bc0ebab17bf5a2c29d2214743c82034f82e6573 by Andrew Svetlov in branch 'master': bpo-35380: Enable TCP_NODELAY for proactor event loop (#10867) https://github.com/python/cpython/commit/3bc0ebab17bf5a2c29d2214743c82034f82e6573 --

[issue35380] Enable TCP_NODELAY for proactor event loop

2018-12-03 Thread miss-islington
Change by miss-islington : -- pull_requests: +10109 ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscribe:

[issue35392] Create asyncio/sockutils.py

2018-12-03 Thread Andrew Svetlov
New submission from Andrew Svetlov : As discussed with Yuri on https://github.com/python/cpython/pull/10867#discussion_r238395192 Candidate functions to move into the helper modules: * _set_nodelay() * _ipaddr_info() * _set_reuseport() -- components: asyncio messages: 330973 nosy:

[issue35391] threading.RLock exception handling while waiting

2018-12-03 Thread Omer Bartal
New submission from Omer Bartal : (tested on python 2.7) Created a threading.Condition(threading.RLock()) A piece of code acquires the lock using a with block and waits (for a notify) While wait() is running a KeyboardInterrupt is raised An exception is raised while exiting the lock's with

[issue35357] unittest.mock.call can't represent calls to a method called 'parent'

2018-12-03 Thread Andrew Dunai
Andrew Dunai added the comment: I was considering wrapping a `unittest.mock._Call` class definition within a function that would contain name & parent as local variables (arguments). Thus they would be accessible within the `_Call` class, but wouldn't be accessible from the outside. However

[issue25567] shlex.quote doesn't work on bytestrings

2018-12-03 Thread Roundup Robot
Change by Roundup Robot : -- pull_requests: +10106 ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscribe:

[issue9004] datetime.utctimetuple() should not set tm_isdst flag to 0

2018-12-03 Thread Alexander Belopolsky
Alexander Belopolsky added the comment: I submitted Gaurav's patch as PR 10870. Please review. -- ___ Python tracker ___ ___

[issue9004] datetime.utctimetuple() should not set tm_isdst flag to 0

2018-12-03 Thread Alexander Belopolsky
Change by Alexander Belopolsky : -- pull_requests: +10105 stage: needs patch -> patch review ___ Python tracker ___ ___

[issue35267] reproducible deadlock with multiprocessing.Pool

2018-12-03 Thread dzhu
dzhu added the comment: Given the hairiness of the deadlock, I think I would rather let someone who has more experience with the codebase in general handle it, but I can come back to it if it doesn't get addressed. -- ___ Python tracker

[issue35357] unittest.mock.call can't represent calls to a method called 'parent'

2018-12-03 Thread Andrew Dunai
Andrew Dunai added the comment: I see 2 most applicable ways to do it: - Hide .parent and .name by mangling - Define them within the mock class definition scope, but not within the class itself. As long as those are accessed only from within the mock class, I think second method would be

[issue35357] unittest.mock.call can't represent calls to a method called 'parent'

2018-12-03 Thread Chris Withers
Chris Withers added the comment: Not sure I follow the second option, I was thinking of just _mock_parent and _mock_name when I logged this. Happy to see a PR for either though! -- ___ Python tracker

[issue35357] unittest.mock.call can't represent calls to a method called 'parent'

2018-12-03 Thread Chris Withers
Chris Withers added the comment: Go for it! :-) -- ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscribe:

[issue35357] unittest.mock.call can't represent calls to a method called 'parent'

2018-12-03 Thread Andrew Dunai
Andrew Dunai added the comment: I've just stumbled upon this issue while looking for a good first issue to contribute on. If the community agrees this is something that needs to be done, I'll gladly work on this. -- nosy: +and3rson ___ Python

[issue9004] datetime.utctimetuple() should not set tm_isdst flag to 0

2018-12-03 Thread Natal Ngétal
Natal Ngétal added the comment: Please can you convert your patch to a pull request on github. -- nosy: +hobbestigrou ___ Python tracker ___

[issue34172] multiprocessing.Pool and ThreadPool leak resources after being deleted

2018-12-03 Thread tzickel
tzickel added the comment: The previous posts here touch all this subjects: A. The documentation explicitly says: "When the pool object is garbage collected terminate() will be called immediately." (Happened till a code refactor 9 years ago introduced this bug). B. Large amount of code was

[issue35390] ctypes not possible to pass NULL c_void_p in structure by reference

2018-12-03 Thread Dan
New submission from Dan : I have a C struct typedef struct Effect { void* ptr; } Effect; where when I allocate the memory, the void* gets initialized to NULL, and pass back a pointer: Effect* get_effect(){ Effect* pEffect = malloc(sizeof(*pEffect)); pEffect->ptr = NULL;

[issue34172] multiprocessing.Pool and ThreadPool leak resources after being deleted

2018-12-03 Thread Pablo Galindo Salgado
Pablo Galindo Salgado added the comment: Víctor, I have a PR fixing this in: issue35378 Even if is not correct to not call close or join on the Pool, this behaviour was working before while now it hangs. The fix is really simple, si I think we should fix it and not revert the change on this

[issue35368] [2.7] Make PyMem_Malloc() thread-safe in debug mode

2018-12-03 Thread STINNER Victor
STINNER Victor added the comment: According to bpo-31473, the debug hook on PyMem_Malloc() is not thread-safe: 'serialno' variable is not protected by any lock and it's not atomic. -- ___ Python tracker

[issue35385] time module: why not using tzname from the glibc?

2018-12-03 Thread Paul Ganssle
Change by Paul Ganssle : -- nosy: +p-ganssle ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscribe:

[issue31473] Debug hooks on memory allocators are not thread safe (serialno variable)

2018-12-03 Thread STINNER Victor
STINNER Victor added the comment: See also bpo-35368: [2.7] Make PyMem_Malloc() thread-safe in debug mode. -- ___ Python tracker ___

[issue31473] Debug hooks on memory allocators are not thread safe (serialno variable)

2018-12-03 Thread STINNER Victor
Change by STINNER Victor : -- title: PyMem_Raw* API in debug mode are not thread safe -> Debug hooks on memory allocators are not thread safe (serialno variable) versions: +Python 2.7, Python 3.8 ___ Python tracker

[issue31473] PyMem_Raw* API in debug mode are not thread safe

2018-12-03 Thread STINNER Victor
STINNER Victor added the comment: Note: PTHREAD_MUTEX_INITIALIZER can be used to statically initialize a mutex. -- ___ Python tracker ___

[issue35389] Use gnu_get_libc_version() in platform.libc_ver()?

2018-12-03 Thread STINNER Victor
STINNER Victor added the comment: > >>> os.confstr('CS_GNU_LIBC_VERSION') > 'glibc 2.28' That's cool because it doesn't require to write new C code ;-) -- ___ Python tracker

[issue34172] multiprocessing.Pool and ThreadPool leak resources after being deleted

2018-12-03 Thread STINNER Victor
STINNER Victor added the comment: """ def the_test(): print("Begin") for x in multiprocessing.Pool().imap(int, ["4", "3"]): print(x) print("End") """ Side-note: Is it correct to use a pool without calling terminate() nor close()? Should we start to emit a

[issue10320] printf %qd is nonstandard

2018-12-03 Thread Mark Lawrence
Change by Mark Lawrence : -- nosy: -BreamoreBoy ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscribe:

[issue34172] multiprocessing.Pool and ThreadPool leak resources after being deleted

2018-12-03 Thread STINNER Victor
STINNER Victor added the comment: I suggest to revert this change, since it caused a regression: "multiprocessing.Pool.imap hangs in MacOs after applying this commit: (...)" -- nosy: +benjamin.peterson, ned.deily, vstinner priority: normal -> release blocker resolution: fixed ->

[issue35389] Use gnu_get_libc_version() in platform.libc_ver()?

2018-12-03 Thread Jakub Wilk
Jakub Wilk added the comment: You can use confstr to get (running) glibc version: >>> os.confstr('CS_GNU_LIBC_VERSION') 'glibc 2.28' -- nosy: +jwilk ___ Python tracker ___

[issue35389] Use gnu_get_libc_version() in platform.libc_ver()?

2018-12-03 Thread STINNER Victor
New submission from STINNER Victor : Currently, platform.libc_ver() opens Python binary file (ex: /usr/bin/python3) and looks for a string like "GLIBC-2.28". Maybe gnu_get_libc_version() should be exposed in Python to get the version of the running glibc version? And use it if available, or

[issue9338] argparse optionals with nargs='?', '*' or '+' can't be followed by positionals

2018-12-03 Thread Lars Beckers
Change by Lars Beckers : -- nosy: +extmind ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscribe:

[issue26544] platform.libc_ver() returns incorrect version number

2018-12-03 Thread STINNER Victor
STINNER Victor added the comment: New changeset 8687bd86e6f138ef0699a1e9f3f9555765949b51 by Victor Stinner in branch '2.7': bpo-26544: Make platform.libc_ver() less slow (GH-10868) https://github.com/python/cpython/commit/8687bd86e6f138ef0699a1e9f3f9555765949b51 --

[issue35386] ftp://www.pythontest.net/ returns error 500

2018-12-03 Thread STINNER Victor
STINNER Victor added the comment: Ernest w. Durbin iii (EWDurbin) fixed the bug in less than one hour, cool! I contacted him on IRC (#python-infra). The disk was full (/dev/vda1 25G 25G 0 100% /) and cron was stopped. -- resolution: -> fixed stage: -> resolved status: open ->

[issue31473] PyMem_Raw* API in debug mode are not thread safe

2018-12-03 Thread STINNER Victor
STINNER Victor added the comment: By the way, the previous attempt to add _PyRuntime.mem had to be reverted. See bpo-32096, bpo-30860 and the commit: commit 9e87e7776f7ace66baaf7247233afdabd00c2b44 Author: Victor Stinner Date: Fri Nov 24 12:09:24 2017 +0100 bpo-32096: Remove obj and

[issue31473] PyMem_Raw* API in debug mode are not thread safe

2018-12-03 Thread STINNER Victor
STINNER Victor added the comment: See also bpo-35265: "Internal C API: pass the memory allocator in a context". The most complex part is the Python initialization which changes the memory allocator *and* allocate memory. We have to remain which allocator has been used to allocate data, to

[issue31473] PyMem_Raw* API in debug mode are not thread safe

2018-12-03 Thread STINNER Victor
STINNER Victor added the comment: I looked at _Py_atomic_address to avoid atomic "serialno++", but we don't have atomic_fetch_add(). We could implement it using a loop and atomic_compare_exchange_strong()... but we don't have atomic_compare_exchange_strong() neither. I tried to add a

[issue35388] _PyRuntime_Initialize() called after Py_Finalize() does nothing

2018-12-03 Thread STINNER Victor
New submission from STINNER Victor : When Python is embedded, it should be possible to call the following Python function multiple times: void func(void) { Py_Initialize(); /* do something in Python */ Py_Finalize(); } Py_Finalize() ends by calling _PyRuntime_Finalize(). Problem: when

[issue35351] LTOFLAGS are passed to BASECFLAGS when using LTO

2018-12-03 Thread STINNER Victor
Change by STINNER Victor : -- nosy: +vstinner ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscribe:

[issue35387] Dialogs on IDLE are accompanied by a small black window

2018-12-03 Thread Kevin Walzer
New submission from Kevin Walzer : The "About IDLE" and "Preferences" dialogs on IDLE are accompanied by a small black window titled "idle" when IDLE is run agains the tip of Tk 8.6 on macOS 10.14. This is likely owing to the multiple changes in Tk to accommodate the Mac's API changes on

[issue35385] time module: why not using tzname from the glibc?

2018-12-03 Thread Alexey Izbyshev
Alexey Izbyshev added the comment: See #28108 and https://sourceware.org/bugzilla/show_bug.cgi?id=23859 (for msg276123). -- nosy: +izbyshev ___ Python tracker ___

[issue35346] Modernize Lib/platform.py code

2018-12-03 Thread STINNER Victor
STINNER Victor added the comment: Another issue with Python 2 compatibility (I addition to platform.dist() removal) of Lib/platform.py from master: it uses re.ASCII which doesn't exist in Python 2.7. -- ___ Python tracker

[issue26544] platform.libc_ver() returns incorrect version number

2018-12-03 Thread STINNER Victor
Change by STINNER Victor : -- pull_requests: +10104 ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscribe:

[issue35373] PyInit_timezone() must return a value

2018-12-03 Thread STINNER Victor
STINNER Victor added the comment: New changeset 3bb150d8148e3cc08418077a58f43e064b9fde61 by Victor Stinner in branch 'master': bpo-35373: Fix PyInit_time() error handling (GH-10865) https://github.com/python/cpython/commit/3bb150d8148e3cc08418077a58f43e064b9fde61 --

  1   2   >