[issue35564] [DOC] Sphinx 2.0 will require master_doc variable set in conf.py

2019-03-20 Thread Julien Palard
Change by Julien Palard : -- pull_requests: +12413 ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscribe: https://ma

[issue35564] [DOC] Sphinx 2.0 will require master_doc variable set in conf.py

2019-03-20 Thread Julien Palard
Change by Julien Palard : -- pull_requests: +12414 ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscribe: https://ma

[issue35564] [DOC] Sphinx 2.0 will require master_doc variable set in conf.py

2019-03-20 Thread Julien Palard
Change by Julien Palard : -- pull_requests: +12415 ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscribe: https://ma

[issue36374] A possible null pointer dereference in compile.c's merge_consts_recursive()

2019-03-20 Thread SilentGhost
Change by SilentGhost : -- nosy: +inada.naoki ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.py

[issue8677] Modules needing PY_SSIZE_T_CLEAN

2019-03-20 Thread Inada Naoki
Change by Inada Naoki : -- pull_requests: +12416 ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.

[issue36378] Add support to load from paths to json.load

2019-03-20 Thread Dani Fojo
New submission from Dani Fojo : Add support to json.load to read from a string or Path object containing the path to a json file. Many libraries (like Numpy) support this behavior. -- components: Library (Lib) messages: 338442 nosy: Dani Fojo priority: normal severity: normal status: o

[issue36378] Add support to load from paths to json.load

2019-03-20 Thread SilentGhost
Change by SilentGhost : -- nosy: +ezio.melotti, rhettinger ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscribe: ht

[issue36378] Add support to load from paths to json.load

2019-03-20 Thread Roundup Robot
Change by Roundup Robot : -- keywords: +patch pull_requests: +12417 stage: -> patch review ___ Python tracker ___ ___ Python-bugs-l

[issue36378] Add support to load from paths to json.load

2019-03-20 Thread Karthikeyan Singaravelan
Change by Karthikeyan Singaravelan : -- nosy: +xtreak ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscribe: https:/

[issue8677] Modules needing PY_SSIZE_T_CLEAN

2019-03-20 Thread Inada Naoki
Inada Naoki added the comment: > Also PC/winreg.c. In this case winreg.SetValue() needs a length of size DWORD > instead of ssize_t. As MSDN, cbData is ignored. https://docs.microsoft.com/en-us/windows/desktop/api/winreg/nf-winreg-regsetvaluew Can I skip overflow check? If I can not, what i

[issue36374] A possible null pointer dereference in compile.c's merge_consts_recursive()

2019-03-20 Thread miss-islington
miss-islington added the comment: New changeset 9b4a1b1e23d4a7cb18ad26f405bdc741af69f342 by Miss Islington (bot) (Zackery Spytz) in branch 'master': bpo-36374: Fix a possible null pointer dereference (GH-12449) https://github.com/python/cpython/commit/9b4a1b1e23d4a7cb18ad26f405bdc741af69f342

[issue36374] A possible null pointer dereference in compile.c's merge_consts_recursive()

2019-03-20 Thread Inada Naoki
Change by Inada Naoki : -- resolution: -> fixed stage: patch review -> resolved status: open -> closed ___ Python tracker ___ ___ P

[issue8677] Modules needing PY_SSIZE_T_CLEAN

2019-03-20 Thread Inada Naoki
Change by Inada Naoki : -- pull_requests: +12418 ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.

[issue8677] Modules needing PY_SSIZE_T_CLEAN

2019-03-20 Thread Inada Naoki
Change by Inada Naoki : -- pull_requests: +12419 ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.

[issue35564] [DOC] Sphinx 2.0 will require master_doc variable set in conf.py

2019-03-20 Thread Julien Palard
Julien Palard added the comment: New changeset 07b8018d75f3d4495708cf1d4175f33b40e13d30 by Julien Palard in branch '2.7': [2.7] bpo-35564: add master_doc='contents' to conf.py (GH-12462) https://github.com/python/cpython/commit/07b8018d75f3d4495708cf1d4175f33b40e13d30 -- __

[issue35564] [DOC] Sphinx 2.0 will require master_doc variable set in conf.py

2019-03-20 Thread Julien Palard
Julien Palard added the comment: New changeset 756cfd88920c2349d4546024856c406409b0ab7b by Julien Palard in branch '3.7': [3.7] bpo-35564: add master_doc='contents' to conf.py (GH-12460) https://github.com/python/cpython/commit/756cfd88920c2349d4546024856c406409b0ab7b -- __

[issue8677] Modules needing PY_SSIZE_T_CLEAN

2019-03-20 Thread Inada Naoki
Inada Naoki added the comment: New changeset c5a216e0b97712bf19b4a6b7655c6bf22a367edd by Inada Naoki in branch 'master': bpo-8677: use PY_SSIZE_T_CLEAN in Modules/_gdbmodule.c (GH-12464) https://github.com/python/cpython/commit/c5a216e0b97712bf19b4a6b7655c6bf22a367edd -- __

[issue36378] Add support to load from paths to json.load

2019-03-20 Thread Karthikeyan Singaravelan
Karthikeyan Singaravelan added the comment: This expands the API where json.load now only accepts open file objects to support str and pathlike objects. This was discussed in https://mail.python.org/pipermail/python-ideas/2017-March/045303.html where there were alternatives proposed as below

[issue8677] Modules needing PY_SSIZE_T_CLEAN

2019-03-20 Thread Inada Naoki
Inada Naoki added the comment: New changeset e9a1dcb4237cb2be71ab05883d472038ea9caf62 by Inada Naoki in branch 'master': bpo-8677: use PY_SSIZE_T_CLEAN in socketmodule.c (GH-12467) https://github.com/python/cpython/commit/e9a1dcb4237cb2be71ab05883d472038ea9caf62 --

[issue36324] Inverse cumulative normal distribution function

2019-03-20 Thread Steven D'Aprano
Steven D'Aprano added the comment: On Tue, Mar 19, 2019 at 01:06:45AM +, Steven D'Aprano wrote: > Later I will do some spot checks against the results returned by the Nspire > calculator Looks good to me, they agree to 6 decimal places in my tests. Following Mark's earlier investigation,

[issue8677] Modules needing PY_SSIZE_T_CLEAN

2019-03-20 Thread Inada Naoki
Inada Naoki added the comment: New changeset d5f18a63cc2dfe8d0adec8bce384a8c569b0f3dc by Inada Naoki in branch 'master': bpo-8677: use PY_SSIZE_T_CLEAN in PC/winreg.c (GH-12466) https://github.com/python/cpython/commit/d5f18a63cc2dfe8d0adec8bce384a8c569b0f3dc -- ___

[issue36373] asyncio.gather: no docs for deprecated loop parameter

2019-03-20 Thread Emmanuel Arias
Emmanuel Arias added the comment: Hi, Reading the asyncio.gather code not seem to be deprecrated. loop is used on a lot of line of code. Maybe, the deprecate idea is on other place where I don't know. -- nosy: +eamanu ___ Python tracker

[issue36347] Renaming the constants for the .flags of PyMemberDef

2019-03-20 Thread Stéphane Wirtel
Stéphane Wirtel added the comment: Hi @Josh, In the PR, I don't remove READONLY. READONLY becomes an alias of PY_READONLY. I think I should split my PR in two PRs 1. Improve the current documentation and the code 2. Change the code in the Modules/ with the new macros. @Serhyi what is your su

[issue30668] DOC: missing word in license.rst

2019-03-20 Thread Cheryl Sabella
Cheryl Sabella added the comment: The first note was fixed, but the second still remains. Assigning to @Mariatta for the sprints. -- assignee: docs@python -> Mariatta nosy: +Mariatta -christian.heimes, docs@python stage: -> needs patch versions: +Python 3.8 -Python 3.7

[issue36377] Python 'datastructures.html' docs page needs improvement because of ambiguity

2019-03-20 Thread Emmanuel Arias
Change by Emmanuel Arias : -- keywords: +patch pull_requests: +12420 stage: -> patch review ___ Python tracker ___ ___ Python-bugs-

[issue33406] [ctypes] increase the refcount of a callback function

2019-03-20 Thread Cheryl Sabella
Change by Cheryl Sabella : -- nosy: +pablogsal ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.p

[issue36355] Remove documentation and internal use of the *RESTRICTED constants for PyMemberDef's flags field

2019-03-20 Thread Stéphane Wirtel
Stéphane Wirtel added the comment: Josh, I don't know for the uselessness or not of these macros, but these macros are used. RESTRICTED is used in Objects/classobject.c and Objects/funcobject.c PY_WRITE_RESTRICTED is used in Objects/funcobject.c and Objects/methodobject.c -- nosy: +m

[issue8677] Modules needing PY_SSIZE_T_CLEAN

2019-03-20 Thread STINNER Victor
STINNER Victor added the comment: PC/winreg.c: if (value_length >= INT_MAX) { PyErr_SetString(PyExc_OverflowError, "the value is too long"); return NULL; } PY_DWORD_MAX should be used here. It's twice larger than INT_MAX ;-) -- ___

[issue8677] Modules needing PY_SSIZE_T_CLEAN

2019-03-20 Thread Inada Naoki
Change by Inada Naoki : -- pull_requests: +12421 ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.

[issue36367] tokenizer.c memory leak in case of realloc failure

2019-03-20 Thread STINNER Victor
Change by STINNER Victor : -- pull_requests: +12422 ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscribe: https://m

[issue36367] tokenizer.c memory leak in case of realloc failure

2019-03-20 Thread STINNER Victor
Change by STINNER Victor : -- pull_requests: +12423 ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscribe: https://m

[issue8677] Modules needing PY_SSIZE_T_CLEAN

2019-03-20 Thread Inada Naoki
Inada Naoki added the comment: New changeset cc60cdd9c44dd15e441603ee5f78e09ea3e76929 by Inada Naoki in branch 'master': bpo-8677: use PY_DWORD_MAX instead of INT_MAX (GH-12469) https://github.com/python/cpython/commit/cc60cdd9c44dd15e441603ee5f78e09ea3e76929 -- ___

[issue36367] tokenizer.c memory leak in case of realloc failure

2019-03-20 Thread STINNER Victor
STINNER Victor added the comment: New changeset 65b9849f0f07a000d751c96d9d711aeb24c95224 by Victor Stinner in branch '3.7': bpo-36367: Free buffer if realloc fails in tokenize.c (GH-12442) (GH-12471) https://github.com/python/cpython/commit/65b9849f0f07a000d751c96d9d711aeb24c95224 -

[issue36367] tokenizer.c memory leak in case of realloc failure

2019-03-20 Thread STINNER Victor
STINNER Victor added the comment: New changeset 469b0a50d990bcb441910b23194c131e403c2833 by Victor Stinner in branch '2.7': bpo-36367: Free buffer if realloc fails in tokenize.c (GH-12442) (GH-12470) https://github.com/python/cpython/commit/469b0a50d990bcb441910b23194c131e403c2833 -

[issue36379] nb_inplace_pow is always called with an invalid argument

2019-03-20 Thread Zuzu_Typ
New submission from Zuzu_Typ : Using the C-API, the inplace_pow numbermethod is always called with the third argument pointing to an invalid address. The reason is likely that self.__ipow__ only takes one argument, resulting in a binaryfunc (self, arg), though inplace_pow is a ternaryfunc. Wh

[issue36367] tokenizer.c memory leak in case of realloc failure

2019-03-20 Thread STINNER Victor
Change by STINNER Victor : -- versions: +Python 2.7, Python 3.7, Python 3.8 ___ Python tracker ___ ___ Python-bugs-list mailing list

[issue36380] collections.Counter in-place operators are unexpectedly slow

2019-03-20 Thread Никита Сметанин
New submission from Никита Сметанин : All of collections.Counter in-place operators: +=, -=, |= and &= are obviously expected to have time complexity O(b) as in the following example: a = Counter(...) # e.g 1M elements b = Counter(...) # e.g. 10 elements a += b But in fact, all of them are h

[issue29301] decimal: Use FASTCALL and/or Argument Clinic

2019-03-20 Thread Stefan Krah
Stefan Krah added the comment: Thanks, but it is still not going to happen. Look at the increased code size in e.g. blake2s_impl.c.h. I want to know what is going on in the code. Also, the performance improvements are in argument parsing, but not when you have numerical code like a * b, wher

[issue36366] Patcher stop method should be idempotent

2019-03-20 Thread Karthikeyan Singaravelan
Change by Karthikeyan Singaravelan : -- keywords: +patch pull_requests: +12424 stage: -> patch review ___ Python tracker ___ ___ Py

[issue36380] collections.Counter in-place operators are unexpectedly slow

2019-03-20 Thread Karthikeyan Singaravelan
Change by Karthikeyan Singaravelan : -- nosy: +rhettinger ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscribe: htt

[issue36380] collections.Counter in-place operators are unexpectedly slow

2019-03-20 Thread SilentGhost
Change by SilentGhost : -- versions: -Python 3.5, Python 3.6 ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscribe:

[issue36380] collections.Counter in-place operators are unexpectedly slow

2019-03-20 Thread Karthikeyan Singaravelan
Karthikeyan Singaravelan added the comment: > It also unclear if there's even a need to check for non-positives with > _keep_positive in ops like __iadd__, __iand__ and __ior__ (except __isub__) > as it expects Counters which are always positive. Counter accepts dictionaries and keyword argu

[issue8677] Modules needing PY_SSIZE_T_CLEAN

2019-03-20 Thread Inada Naoki
Change by Inada Naoki : -- pull_requests: +12425 ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.

[issue36342] test_venv failure when the platform lacks a functional sem_open()

2019-03-20 Thread Xavier de Gaye
Xavier de Gaye added the comment: It is a test_venv issue related to bpo-32126 and also related to the other issues listed in bpo-32126. Changing the title as it is ambiguous indeed. check_output() in test_venv.py does not print the full stack trace as it is done by test_asyncio in bpo-3212

[issue36381] Preapre for mandatory PY_SSIZE_T_CLEAN

2019-03-20 Thread Inada Naoki
New submission from Inada Naoki : Raise warning for # use without PY_SSIZE_T_CLEAN. * 3.8: PendingDeprecationWarning * 3.9: DeprecationWarning * 3.10 (or 4.0): Remove PY_SSIZE_T_CLEAN and use Py_ssize_t always -- components: Extension Modules messages: 338466 nosy: inada.naoki, serhiy.

[issue36380] collections.Counter in-place operators are unexpectedly slow

2019-03-20 Thread Rémi Lapeyre
Rémi Lapeyre added the comment: @xtreak __init__ delegates work to update() which has the same behavior: Python 3.7.2 (default, Feb 12 2019, 08:15:36) [Clang 10.0.0 (clang-1000.11.45.5)] on darwin Type "help", "copyright", "credits" or "license" for more information. >>> from collections import

[issue8677] Modules needing PY_SSIZE_T_CLEAN

2019-03-20 Thread Inada Naoki
Inada Naoki added the comment: > Would it be possible to emit a deprecation warning, maybe at runtime, when > PY_SSIZE_T_CLEAN is not defined? I created bpo-36381 for it. Let's close this long living issue. -- resolution: -> fixed stage: patch review -> resolved status: open -> clo

[issue36381] Preapre for mandatory PY_SSIZE_T_CLEAN

2019-03-20 Thread Inada Naoki
Change by Inada Naoki : -- keywords: +patch pull_requests: +12426 stage: -> patch review ___ Python tracker ___ ___ Python-bugs-lis

[issue21960] Better path handling in Idle find in files

2019-03-20 Thread Cheryl Sabella
Change by Cheryl Sabella : -- resolution: -> duplicate stage: test needed -> resolved status: open -> closed superseder: -> IDLE: always display full grep path ___ Python tracker ___

[issue36323] IDLE: always display full grep path

2019-03-20 Thread Cheryl Sabella
Cheryl Sabella added the comment: See also #21960. I'm going to close that one in favor of this issue. -- ___ Python tracker ___ _

[issue36370] "Fatal Python error: Cannot recover from stack overflow" from SymPy tests

2019-03-20 Thread Rémi Lapeyre
Rémi Lapeyre added the comment: FWIW I just tried both f8e46e9e741f253803e9b8be03287e5dd16abd4d and f8e46e9e741f253803e9b8be03287e5dd16abd4d with the reproducer given and none of them segfault. I don't think there is a bug in the Python interpreter, there is some ways to trigger this error w

[issue36380] collections.Counter in-place operators are unexpectedly slow

2019-03-20 Thread Nikita Smetanin
Nikita Smetanin added the comment: @xtreak I agree, also, this behavior is stated in documentation, but it's quite inconsistent in many ways, like in the following examples: Counter(a=-1) + Counter(a=-2) produces empty Counter() instead of Counter(a=-2) which is unexpected, but Counter(a=-1)

[issue36380] collections.Counter in-place operators are unexpectedly slow

2019-03-20 Thread Karthikeyan Singaravelan
Karthikeyan Singaravelan added the comment: I would defer to Raymond at this point and would prefer keeping current __iadd__ behavior and . See also issue23509 that discussed about C implementation of _keep_positive and some other optimizations. > Counter(a=-1) + Counter(a=-2) produces empt

[issue36382] socket.getfqdn() returns domain "mshome.net"

2019-03-20 Thread Markus
New submission from Markus : In a corporate network, `wmic computersystem get domain` returns the correct domain. On some clients, the Python query "socket.getfqdn()" returns the wrong domain, namely "mshome.net" >>> import socket >>> socket.getfqdn() '*.mshome.net' I have only found on

[issue20309] Not all method descriptors are callable

2019-03-20 Thread Jeroen Demeyer
Jeroen Demeyer added the comment: See also PEP 579 (issue 11) and the thread https://mail.python.org/pipermail/python-ideas/2018-June/051572.html -- nosy: +jdemeyer ___ Python tracker __

[issue36381] Preapre for mandatory PY_SSIZE_T_CLEAN

2019-03-20 Thread STINNER Victor
STINNER Victor added the comment: > * 3.8: PendingDeprecationWarning ... Or maybe use directly DeprecationWarning? :-) https://discuss.python.org/t/pendingdeprecationwarning-is-really-useful/1038 -- ___ Python tracker

[issue36370] "Fatal Python error: Cannot recover from stack overflow" from SymPy tests

2019-03-20 Thread Stefan Krah
Stefan Krah added the comment: This occurs when handling a recursion error uses more than 50 extra nested function calls: if (tstate->overflowed) { if (tstate->recursion_depth > recursion_limit + 50) { /* Overflowing while handling an overflow. Give up. */ Py_F

[issue36370] "Fatal Python error: Cannot recover from stack overflow" from SymPy tests

2019-03-20 Thread Stefan Krah
Stefan Krah added the comment: It can still be an issue in CPython, like in #14537. -- ___ Python tracker ___ ___ Python-bugs-list

[issue36380] collections.Counter in-place operators are unexpectedly slow

2019-03-20 Thread Josh Rosenberg
Josh Rosenberg added the comment: @Nikita: Your examples aren't unexpected at all, per the documented behavior: >Several mathematical operations are provided for combining Counter objects to >produce multisets (counters that have counts greater than zero). Addition and >subtraction combine c

[issue36382] socket.getfqdn() returns domain "mshome.net"

2019-03-20 Thread Steve Dower
Steve Dower added the comment: We just return the result of GetComputerNameEx [1] here - we don't use WMI at all (and given the complexities, we are not going to start). Are you able to provide any more information? In particular, if the documentation for GetComputerNameEx (below) helps you

[issue36370] "Fatal Python error: Cannot recover from stack overflow" from SymPy tests

2019-03-20 Thread Stefan Krah
Stefan Krah added the comment: The tests pass here on Linux with 3.8 (cc60cdd9c4) and a very low sys.setrecursionlimit(150). The fail properly with RecursionError at sys.setrecursionlimit(125). So I guess we'd need a gdb stack trace from OS X in case there's a CPython issue that is OS X sp

[issue36381] Deprecate "#" argument format without PY_SSIZE_T_CLEAN

2019-03-20 Thread STINNER Victor
Change by STINNER Victor : -- title: Preapre for mandatory PY_SSIZE_T_CLEAN -> Deprecate "#" argument format without PY_SSIZE_T_CLEAN ___ Python tracker ___ __

[issue8677] Modules needing PY_SSIZE_T_CLEAN

2019-03-20 Thread STINNER Victor
STINNER Victor added the comment: > Let's close this long living issue. Thanks INADA-san for fixing last issues and for creating the deprecation issue! -- ___ Python tracker _

[issue36379] nb_inplace_pow is always called with an invalid argument

2019-03-20 Thread Josh Rosenberg
Josh Rosenberg added the comment: object.__ipow__ is documented to take an optional third argument (though there is no way to pass it aside from explicitly calling __ipow__ directly since there is no syntax support for three-arg pow, in place or otherwise), so it's not some incompatibility w

[issue36382] socket.getfqdn() returns domain "mshome.net"

2019-03-20 Thread Markus
Markus added the comment: Dear Steve, in fact not a Python bug at all. I used 2 commands: ipconfig /release ipconfig /renew and rebootet. This fixed the issue, for now. Also, I found this domain in c:\Windows\System32\drivers\etc\hosts.ics Unclear who created that entry. Documenting

[issue36370] "Fatal Python error: Cannot recover from stack overflow" from SymPy tests

2019-03-20 Thread Stefan Krah
Stefan Krah added the comment: Whoops, I tested the wrong branch, getting a proper abort() now. :) -- ___ Python tracker ___ ___ Py

[issue36301] Add _Py_PreInitialize() function

2019-03-20 Thread STINNER Victor
STINNER Victor added the comment: In term of API, we get something like: _PyInitError err; _PyPreConfig preconfig = _PyPreConfig_INIT; preconfig.utf8_mode = 1; preconfig.allocator = "malloc"; _PyInitError err = _Py_PreInitializeFromPreConfig(&preconfig); if (_Py_INIT_

[issue35564] [DOC] Sphinx 2.0 will require master_doc variable set in conf.py

2019-03-20 Thread Ned Deily
Ned Deily added the comment: New changeset 4508bc37dd80c71adfaa0925a67c438389817076 by Ned Deily (Julien Palard) in branch '3.6': [3.6] bpo-35564: add master_doc='contents' to conf.py (GH-11290). (GH-12461) https://github.com/python/cpython/commit/4508bc37dd80c71adfaa0925a67c438389817076 --

[issue36380] collections.Counter in-place operators are unexpectedly slow

2019-03-20 Thread Raymond Hettinger
Change by Raymond Hettinger : -- assignee: -> rhettinger ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscribe: htt

[issue36380] collections.Counter in-place operators are unexpectedly slow

2019-03-20 Thread Raymond Hettinger
Raymond Hettinger added the comment: As Josh pointed out, this is how counters are documented and tested to work, so it is an unchangeable decision (i.e. it would break code that relying on the saturating arithmetic feature). Accordingly, I'm marking this as closed, not a bug. On the plus

[issue21960] Better path handling in Idle find in files

2019-03-20 Thread Terry J. Reedy
Change by Terry J. Reedy : -- assignee: -> terry.reedy components: +IDLE ___ Python tracker ___ ___ Python-bugs-list mailing list U

[issue36382] socket.getfqdn() returns domain "mshome.net"

2019-03-20 Thread Markus
Markus added the comment: I found the IP of mshome.net in an Ethernet adapter "vEthernet" It seems that this adapter stems from Hyper-V. It therefore seems that socket.getfqdn() reported the wrong network adapter once. Because I cannot reproduce this, I leave this issue closed. --

[issue36368] server process of shared_memory shuts down if KeyboardInterrupt

2019-03-20 Thread Antoine Pitrou
Antoine Pitrou added the comment: Your patch sounds good on the principle, but can you make a patch out of it? -- ___ Python tracker ___ __

[issue36368] server process of shared_memory shuts down if KeyboardInterrupt

2019-03-20 Thread Antoine Pitrou
Antoine Pitrou added the comment: Sorry - I meant make a *PR* out of it :-) -- ___ Python tracker ___ ___ Python-bugs-list mailing

[issue36370] Check for PyErr_Occurred() after PyImport_GetModule().

2019-03-20 Thread Stefan Krah
Stefan Krah added the comment: The issue is that PyImport_GetModule() can legitimately NULL (not found) but also NULL after an error occurred in PyDict_GetItemWithError(). So one (quick and dirty) approach that fixes this abort() is: diff --git a/Python/import.c b/Python/import.c index bf3a99

[issue36370] Check for PyErr_Occurred() after PyImport_GetModule().

2019-03-20 Thread Stefan Krah
Change by Stefan Krah : -- stage: -> needs patch ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscribe: https://mai

[issue36380] collections.Counter in-place operators are unexpectedly slow

2019-03-20 Thread Rémi Lapeyre
Rémi Lapeyre added the comment: Hi what do you think of a patch to this effect that would speed up operations without changing the current semantics? diff --git a/Lib/collections/__init__.py b/Lib/collections/__init__.py index cff75a48d6..fe5d5b2dca 100644 --- a/Lib/collections/__init__.py ++

[issue36380] collections.Counter in-place operators are unexpectedly slow

2019-03-20 Thread Raymond Hettinger
Raymond Hettinger added the comment: I don't want to complexify the normal case. Please don't go down the path of turning something simple into a mess. Because counters are just a dict subclass, users are free to make updates in any way they want. -- __

[issue21625] Make help() beginner helpful when no PAGER or LESS variable

2019-03-20 Thread Terry J. Reedy
Terry J. Reedy added the comment: I recently opened Python in a Mac Terminal (bash) window, tried help(ob), and being a beginner in this situation, had the same terrible frustrating experience. I am leaving this open to implement David Murray's suggestion and changed the title accordingly.

[issue35771] IDLE: Fix tooltip Hovertiptest failure

2019-03-20 Thread Terry J. Reedy
Change by Terry J. Reedy : -- assignee: -> terry.reedy components: +IDLE ___ Python tracker ___ ___ Python-bugs-list mailing list U

[issue35675] IDLE: Refactor config_key module.

2019-03-20 Thread Terry J. Reedy
Change by Terry J. Reedy : -- assignee: -> terry.reedy components: +IDLE ___ Python tracker ___ ___ Python-bugs-list mailing list U

[issue35467] IDLE: unrequested pasting into Shell after restart

2019-03-20 Thread Terry J. Reedy
Change by Terry J. Reedy : -- assignee: -> terry.reedy components: +IDLE ___ Python tracker ___ ___ Python-bugs-list mailing list U

[issue33964] IDLE maxosc.overrideRootMenu: remove unused menudict

2019-03-20 Thread Terry J. Reedy
Change by Terry J. Reedy : -- assignee: -> terry.reedy components: +IDLE versions: -Python 3.6 ___ Python tracker ___ ___ Python-b

[issue21696] Idle: test configuration files

2019-03-20 Thread Terry J. Reedy
Change by Terry J. Reedy : -- components: +IDLE versions: +Python 3.7, Python 3.8 -Python 2.7, Python 3.4, Python 3.5 ___ Python tracker ___ ___

[issue31329] Add idlelib module entry to doc

2019-03-20 Thread Terry J. Reedy
Change by Terry J. Reedy : -- assignee: -> terry.reedy components: +IDLE versions: +Python 3.8 -Python 3.6 ___ Python tracker ___ _

[issue21588] Idle: make editor title bar user configurable

2019-03-20 Thread Terry J. Reedy
Change by Terry J. Reedy : -- components: +IDLE versions: +Python 3.7, Python 3.8 -Python 2.7, Python 3.4, Python 3.5 ___ Python tracker ___ ___

[issue21647] Idle unittests: make gui, mock switching easier.

2019-03-20 Thread Terry J. Reedy
Change by Terry J. Reedy : -- assignee: -> terry.reedy components: +IDLE versions: +Python 3.7, Python 3.8 -Python 2.7, Python 3.4, Python 3.5 ___ Python tracker ___ _

[issue36383] In Windows 10 virtual environments distutils.sysconfig.get_python_inc() reports base Python include directory

2019-03-20 Thread Mark Campanelli
New submission from Mark Campanelli : On Windows 10 64bit, using virtualenv in Python 2.7.15 or venv in Python 3.7.2, calling distutils.sysconfig.get_python_inc() returns the path to the include directory for the (respective) Python base installation instead of the include directory installed

[issue36342] test_venv failure when executed by test_multiprocessing and the platform lacks a functional sem_open()

2019-03-20 Thread Brett Cannon
Brett Cannon added the comment: I guess my confusion comes from the fact that test_venv in isolation is a totally fine test suite, it just fails when test_multiprocessing runs it due to something multiprocessing-related. I've tried tweaking the title to reflect the fact that it's a test_venv

[issue36370] Check for PyErr_Occurred() after PyImport_GetModule().

2019-03-20 Thread Brett Cannon
Brett Cannon added the comment: Pulling in Eric and Nick as they have played w/ the C API more recently. -- nosy: +eric.snow, ncoghlan ___ Python tracker ___ _

[issue31329] Add idlelib module entry to doc

2019-03-20 Thread Terry J. Reedy
Terry J. Reedy added the comment: See also #14944, about the Using doc. -- ___ Python tracker ___ ___ Python-bugs-list mailing list

[issue36370] Check for PyErr_Occurred() after PyImport_GetModule().

2019-03-20 Thread Stefan Krah
Stefan Krah added the comment: Actually I just see that this behavior of PyImport_GetModule() is documented: "Return the already imported module with the given name. If the module has not been imported yet then returns NULL but does not set an error. Returns NULL and sets an error if the loo

[issue14944] Setup & Usage documentation for pydoc, IDLE, & 2to3

2019-03-20 Thread Terry J. Reedy
Terry J. Reedy added the comment: idle.html, derived from idle.rst, is now the IDLE help file. pip also has pip3 command; perhaps ensurepip should be mentioned. -- versions: +Python 3.8 -Python 3.6 ___ Python tracker

[issue36379] nb_inplace_pow is always called with an invalid argument

2019-03-20 Thread Zuzu_Typ
Zuzu_Typ added the comment: Even though __ipow__ might be documented to take a third argument, if you build an inplace_pow function using the C-API, you can only pass one argument to it. You can see that in the attached screenshot. The example class shown in the screenshot can be found here:

[issue35866] concurrent.futures deadlock

2019-03-20 Thread Hugh Redelmeier
Hugh Redelmeier added the comment: @jwilk: thanks for creating cf-deadlock.py I can replicate the test program hang on Fedora 29 with python3-3.7.2-4.fc29.x86_64 The test program hasn't yet hung on Fedora 29 with older packages, in particular python3-3.7.1-4.fc29.x86_64 My interest is due

[issue36379] nb_inplace_pow is always called with an invalid argument

2019-03-20 Thread Stefan Krah
Stefan Krah added the comment: Like Josh I don't quite understand the problem description. This for example works: >>> class C(int): ... def __ipow__(self, other, mod=None): ... return pow(self, other, mod) ... >>> >>> x = C(10) >>> x 10 >>> x **= 3 >>> x 1000 -- nosy: +

[issue36379] nb_inplace_pow is always called with an invalid argument

2019-03-20 Thread Zuzu_Typ
Zuzu_Typ added the comment: This isn't about the CPython Interpreter, it's about the C-API, the APIT for writing c-extensions for Python. I know it works in CPython. -- ___ Python tracker _

[issue36379] nb_inplace_pow is always called with an invalid argument

2019-03-20 Thread Stefan Krah
Stefan Krah added the comment: Ok, got it. I think __ipow__ should be a ternaryfunc, like so: diff --git a/Objects/typeobject.c b/Objects/typeobject.c index 403f3caaee..914d076b5c 100644 --- a/Objects/typeobject.c +++ b/Objects/typeobject.c @@ -7032,7 +7032,7 @@ static slotdef slotdefs[] = {

[issue36379] nb_inplace_pow is always called with an invalid argument

2019-03-20 Thread Stefan Krah
Change by Stefan Krah : -- stage: -> needs patch ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscribe: https://mai

[issue36380] collections.Counter in-place operators are unexpectedly slow

2019-03-20 Thread Raymond Hettinger
Raymond Hettinger added the comment: FWIW, the promised semantics of saturating arithmetic require that _keep_positive be run on entire the entire counter: >>> c1 = Counter(a=-3, b=4) >>> +c1 Counter({'b': 4}) >>> from collections import Counter >>> c1 = Counter(a=-3, b=4

  1   2   >