[issue39772] Python 2 FAQ shown in h...@python.org auto reply

2020-02-26 Thread wyz23x2
New submission from wyz23x2 : The auto-reply from help@python contains this: The Python FAQ is available at http://docs.python.org/2/faq/index.html Why is it .org/2/faq, not .org/3/faq? -- components: email files: email.png messages: 362784 nosy: barry, r.david.murray,

[issue38112] Compileall improvements

2020-02-26 Thread Gregory P. Smith
Gregory P. Smith added the comment: https://bugs.python.org/issue39769 may be of interest. compileall's ddir= does not behave properly in recursive subdirectories, it did the right thing in 2.7 which is similar to a combination of compile_dir(dir, prependdir=ddir, stripdir=dir) after this

[issue39769] compileall.compile_dir(..., ddir="") omits the intermediate package paths when prepending the prefix

2020-02-26 Thread Gregory P. Smith
Gregory P. Smith added the comment: Ironically 3.9a4 gains some compileall enhancements that could be used as an awkward workaround from https://bugs.python.org/issue38112: python 2.7 compile_dir(d, ddir="") behavior can be had with python 3.9a4 compile_dir(d, prependdir="", stripdir=d) I

[issue39771] EmailMessage.add_header doesn't work

2020-02-26 Thread hwgdb Smith
hwgdb Smith added the comment: "but msg.as_string() doesn't change. " , I mean using filename=file_name or filename=("GBK", "", f"{file_name}") or filename=("utf-8", "", f"{file_name}") msg.as_string() doesn't change. -- ___ Python

[issue39771] EmailMessage.add_header doesn't work

2020-02-26 Thread hwgdb Smith
New submission from hwgdb Smith : here is the partial code: msg = EmailMessage() file_name = "超e保3000P.csv" ctype, encoding = mimetypes.guess_type(file_name) if ctype is None or encoding is not None: ctype = "application/octet-stream" maintype, subtype =

[issue36144] Dictionary union. (PEP 584)

2020-02-26 Thread Brandt Bucher
Brandt Bucher added the comment: > I think for `|=` the only choice is for it to be essentially an alias to > `.update()`. So that means `cm |= other` becomes `cm.maps[0].update(other)`. Agreed. > These semantics make `|=` behave rather differently from `|`. Is that okay? > If not, which of

[issue39768] remove tempfile.mktemp()

2020-02-26 Thread wyz23x2
Change by wyz23x2 : -- nosy: -ZackerySpytz ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscribe:

[issue39770] Remove unnecessary size calculation in array_modexec in Modules/arraymodule.c

2020-02-26 Thread Andy Lester
Change by Andy Lester : -- pull_requests: -18035 ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscribe:

[issue39770] Remove unnecessary size calculation in array_modexec in Modules/arraymodule.c

2020-02-26 Thread Andy Lester
Change by Andy Lester : -- pull_requests: +18035 pull_request: https://github.com/python/cpython/pull/18673 ___ Python tracker ___

[issue39770] Remove unnecessary size calculation in array_modexec in Modules/arraymodule.c

2020-02-26 Thread Andy Lester
Change by Andy Lester : -- pull_requests: +18034 pull_request: https://github.com/python/cpython/pull/18674 ___ Python tracker ___

[issue39770] Remove unnecessary size calculation in array_modexec in Modules/arraymodule.c

2020-02-26 Thread Andy Lester
Change by Andy Lester : -- pull_requests: -18034 ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscribe:

[issue39768] remove tempfile.mktemp()

2020-02-26 Thread wyz23x2
wyz23x2 added the comment: Reopen. 1.See https://mail.python.org/pipermail/python-dev/2019-March/156765.html and https://owasp.org/www-community/vulnerabilities/Insecure_Temporary_File. It's *serious*. 2.Why not use this to generate a temporary name that an other program will create/act on?

[issue39770] Remove unnecessary size calculation in array_modexec in Modules/arraymodule.c

2020-02-26 Thread Andy Lester
Change by Andy Lester : -- pull_requests: -18032 ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscribe:

[issue39770] Remove unnecessary size calculation in array_modexec in Modules/arraymodule.c

2020-02-26 Thread Andy Lester
Change by Andy Lester : -- pull_requests: -18031 ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscribe:

[issue39770] Remove unnecessary size calculation in array_modexec in Modules/arraymodule.c

2020-02-26 Thread Andy Lester
Change by Andy Lester : -- pull_requests: +18033 pull_request: https://github.com/python/cpython/pull/18675 ___ Python tracker ___

[issue39768] remove tempfile.mktemp()

2020-02-26 Thread Serhiy Storchaka
Change by Serhiy Storchaka : -- resolution: -> duplicate stage: -> resolved status: open -> closed superseder: -> Remove tempfile.mktemp() ___ Python tracker ___

[issue39768] remove tempfile.mktemp()

2020-02-26 Thread wyz23x2
wyz23x2 added the comment: Sorry, in (a)(b) is should be with "open(mktemp(),'x') as f:". -- ___ Python tracker ___ ___

[issue39768] remove tempfile.mktemp()

2020-02-26 Thread wyz23x2
wyz23x2 added the comment: I know it's hard to achieve :) -- ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscribe:

[issue39768] remove tempfile.mktemp()

2020-02-26 Thread wyz23x2
wyz23x2 added the comment: case c is used for the case that is stated in https://mail.python.org/pipermail/python-dev/2019-March/156725.html (a temporary name that an other program will create / act on). -- ___ Python tracker

[issue39770] Remove unnecessary size calculation in array_modexec in Modules/arraymodule.c

2020-02-26 Thread Andy Lester
Change by Andy Lester : -- pull_requests: +18032 pull_request: https://github.com/python/cpython/pull/18674 ___ Python tracker ___

[issue36144] Dictionary union. (PEP 584)

2020-02-26 Thread Guido van Rossum
Guido van Rossum added the comment: I think for `|=` the only choice is for it to be essentially an alias to `.update()`. So that means `cm |= other` becomes `cm.maps[0].update(other)`. For `|` we are breaking new ground and we could indeed make `cm | other` do something like

[issue39770] Remove unnecessary size calculation in array_modexec in Modules/arraymodule.c

2020-02-26 Thread Andy Lester
Change by Andy Lester : -- keywords: +patch pull_requests: +18031 stage: -> patch review pull_request: https://github.com/python/cpython/pull/18673 ___ Python tracker ___

[issue39768] remove tempfile.mktemp()

2020-02-26 Thread wyz23x2
wyz23x2 added the comment: (c) from tempfile import mktemp # do something... path = mktemp() # do something... (the "path" var is not used at all) ## No Warning -- ___ Python tracker

[issue39770] Remove unnecessary size calculation in array_modexec in Modules/arraymodule.c

2020-02-26 Thread Andy Lester
New submission from Andy Lester : The array_modexec function in Modules/arraymodule.c has a loop that calculates the number of elements in the descriptors array. This size was used at one point, but is no longer. The loop can be removed. -- components: Interpreter Core messages:

[issue39768] remove tempfile.mktemp()

2020-02-26 Thread wyz23x2
wyz23x2 added the comment: You could add a check that does this: (a) from tempfile import mktemp with open(mktemp()) as f: # do something... ## No Warnings (b) from tempfile import mktemp path = mktemp() # do something... with open(mktemp()) as f: # do something... ## RuntimeWarning:

[issue39768] remove tempfile.mktemp()

2020-02-26 Thread wyz23x2
wyz23x2 added the comment: But I think the function should redirect to NamedTemporaryFile(delete=False). -- ___ Python tracker ___

[issue39768] remove tempfile.mktemp()

2020-02-26 Thread wyz23x2
wyz23x2 added the comment: Sorry, didn't realize that. -- ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscribe:

[issue39769] compileall.compile_dir(..., ddir="") omits the intermediate package paths when prepending the prefix

2020-02-26 Thread Gregory P. Smith
Gregory P. Smith added the comment: This has probably been happening for many 3 releases. I noticed it on 3.6 when investigating a problem with wrong paths in tracebacks coming from code which we used compileall.compile_dir(src_root, quiet=1, ddir=") on. I'm guessing ddir= (-d on the cli)

[issue39769] compileall.compile_dir(..., ddir="") omits the intermediate package paths when prepending the prefix

2020-02-26 Thread Gregory P. Smith
New submission from Gregory P. Smith : Easiest to demonstrate as such: ```shell #!/bin/bash mkdir bug touch bug/__init__.py mkdir bug/foo touch bug/foo/__init__.py touch bug/foo/bar.py python3 -m compileall -d "" bug python2 -m compileall -d "" bug echo "prefix embedded in PY3 pyc code

[issue39087] [C API] No efficient C API to get UTF-8 string from unicode object.

2020-02-26 Thread Inada Naoki
Inada Naoki added the comment: New changeset 02a4d57263a9846de35b0db12763ff9e7326f62c by Inada Naoki in branch 'master': bpo-39087: Optimize PyUnicode_AsUTF8AndSize() (GH-18327) https://github.com/python/cpython/commit/02a4d57263a9846de35b0db12763ff9e7326f62c --

[issue37497] Add inspect.Signature.from_text().

2020-02-26 Thread Yury Selivanov
Yury Selivanov added the comment: What's the actual use case for exposing this functionality? -- ___ Python tracker ___ ___

[issue39768] remove tempfile.mktemp()

2020-02-26 Thread Zackery Spytz
Zackery Spytz added the comment: I think this is a duplicate of bpo-36309. -- nosy: +ZackerySpytz ___ Python tracker ___ ___

[issue39768] remove tempfile.mktemp()

2020-02-26 Thread wyz23x2
Change by wyz23x2 : -- components: +Library (Lib) ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscribe:

[issue39768] remove tempfile.mktemp()

2020-02-26 Thread wyz23x2
wyz23x2 added the comment: A small typo in the 1st comment: The tempfile.mktemp() function was deprecated since version 2.3; it's long ago (nearly 17 years!). It should be removed since it causes security holes, as stated in the tempfile doc

[issue39768] remove tempfile.mktemp()

2020-02-26 Thread wyz23x2
New submission from wyz23x2 : the tempfile.mktemp() function was deprecated since version 2.3; it's long ago (nearly 17 years)! It should be removed since it causes security holes, as stated in the tempfile doc (https://docs.python.org/3/library/tempfile.html#tempfile.mktemp). --

[issue36144] Dictionary union. (PEP 584)

2020-02-26 Thread Josh Rosenberg
Josh Rosenberg added the comment: Sorry, I think I need examples to grok this in the general case. ChainMap unioned with dict makes sense to me (it's equivalent to update or copy-and-update on the top level dict in the ChainMap). But ChainMap unioned with another ChainMap is less clear.

[issue15474] Differentiate decorator and decorator factory in docs

2020-02-26 Thread Raymond Hettinger
Raymond Hettinger added the comment: Thanks Andrés. I'm going to close this one as it has been open for a long time and not attracted interest. Also, in practice this ambiguity doesn't seem to be an issue and people almost universally refer to anything usable with the @-notation as a

[issue36144] Dictionary union. (PEP 584)

2020-02-26 Thread Brandt Bucher
Brandt Bucher added the comment: The plan is to follow dict’s semantics. The |= operator will basically delegate to the first map in the chain. The | operator will create a new ChainMap where the first map is the merged result of the old first map, and the others are the same. So, basically

[issue15474] Differentiate decorator and decorator factory in docs

2020-02-26 Thread Andrés Delfino
Andrés Delfino added the comment: Hi, no I'm no longer working on this. -- ___ Python tracker ___ ___ Python-bugs-list mailing list

[issue36144] Dictionary union. (PEP 584)

2020-02-26 Thread Josh Rosenberg
Josh Rosenberg added the comment: What is ChainMap going to do? Normally, the left-most argument to ChainMap is the "top level" dict, but in a regular union scenario, last value wins. Seems like layering the right hand side's dict on top of the left hand side's would match dict union

[issue38597] C Extension import limit

2020-02-26 Thread Xinfa Zhu
Xinfa Zhu added the comment: I have had wheel installed. Following this SO answer (https://stackoverflow.com/a/50314071/7269441), I added "import setuptools" before distutils (my setup.py attached). Following is the log, where we see the VS path it is using. BTW, I am trying to reduce my

[issue39699] Some CIs silence potentially useful output from make

2020-02-26 Thread Steve Dower
Steve Dower added the comment: Had to disable the doctests in the 3.7 branch because I just couldn't get them passing. Pablo did the work for 3.8 and later though, so they're on for those. -- resolution: -> fixed stage: patch review -> resolved status: open -> closed

[issue39767] create multiprocessing.SharedMemory by pointing to existing memoryview

2020-02-26 Thread Dariusz Trawinski
New submission from Dariusz Trawinski : Currently, in order to share numpy array between processes via multiprocessing.SharedMemory object, it is required to copy the memory content with: input = np.ones((1,10,10,10)) shm = shared_memory.SharedMemory(create=True, size=input.nbytes)

[issue39766] unittest's assertRaises removes locals from tracebacks

2020-02-26 Thread daniel hahler
daniel hahler added the comment: The test for issue9815 passes since bbd3cf8f1e (bpo-23890). It seems like `traceback.clear_frames(tb)` should probably removed altogether? -- nosy: +vstinner ___ Python tracker

[issue39763] distutils.spawn should use subprocess (hang in parallel builds on QNX)

2020-02-26 Thread Guido van Rossum
Guido van Rossum added the comment: When I run this on macOS, either with the bug, or with the buggy line commented out, I get the same hang. When I interrupt it, I get a separate traceback from each thread. Here's the full session: Parent 78918 Parent 78919 Child 78918 Parent 78920 Child

[issue39622] KeyboardInterrupt is ignored when await asyncio.sleep(0)

2020-02-26 Thread Maor Kleinberger
Maor Kleinberger added the comment: I have pushed an update to my PR. While implementing the new solution I made the following list: Examples for code segments where KeyboardInterrupt must not be raised: - Between popping and running a handle from the ready queue (a handle is lost) - After

[issue39761] Python 3.9.0a4 fails to build when configured with --with-dtrace

2020-02-26 Thread David CARLIER
Change by David CARLIER : -- keywords: +patch nosy: +devnexen nosy_count: 4.0 -> 5.0 pull_requests: +18029 stage: -> patch review pull_request: https://github.com/python/cpython/pull/18672 ___ Python tracker

[issue39765] asyncio loop.add_signal_handler() may not behave as expected

2020-02-26 Thread Roger Dahl
Roger Dahl added the comment: > I'm sorry. but loop.set_signal_handler() method doesn't exist. Oops, fixed. > Assuming you mean loop.add_signal_handler() method, I would say that a > minute-long delay is a sign of long blocking calls in your program. During the delay for the callback to

[issue39762] PyLong_AS_LONG missing from longobject.h

2020-02-26 Thread Enji Cooper
Enji Cooper added the comment: PyInt_AS_LONG doesn't exist on python 3, however: $ grep -r PyInt_AS_LONG /usr/include/ [/usr/include/python2.7/intobject.h:#define PyInt_AS_LONG(op) (((PyIntObject *)(op))->ob_ival) The code smell for the pieces that use PyInt_AS_LONG seems a bit questionable

[issue39765] asyncio loop.add_signal_handler() may not behave as expected

2020-02-26 Thread Andrew Svetlov
Andrew Svetlov added the comment: Assuming you mean loop.add_signal_handler() method, I would say that a minute-long delay is a sign of long blocking calls in your program. Typical asyncio program blocks the loop for 1-10 milliseconds at most, and signal handlers are called with this delay.

[issue39765] asyncio loop.set_signal_handler() may not behave as expected

2020-02-26 Thread Andrew Svetlov
Andrew Svetlov added the comment: I'm sorry. but loop.set_signal_handler() method doesn't exist. -- ___ Python tracker ___ ___

[issue38884] __import__ is not thread-safe on Python 3

2020-02-26 Thread Ryan Petrello
Ryan Petrello added the comment: I believe I'm also encountering some version of this bug while importing code from the kombu library within a multi-threaded context. For what it's worth, I'm able to reproduce the reported deadlock (https://bugs.python.org/file48737/issue38884.zip) using

[issue39699] Some CIs silence potentially useful output from make

2020-02-26 Thread Steve Dower
Steve Dower added the comment: New changeset 3bf9de2fb954bd1131f4f41517d7d5c316fb95f8 by Steve Dower in branch '3.7': bpo-39699: Don't silence make on Azure and Github CIs (GH-18583) https://github.com/python/cpython/commit/3bf9de2fb954bd1131f4f41517d7d5c316fb95f8 --

[issue39766] unittest's assertRaises removes locals from tracebacks

2020-02-26 Thread daniel hahler
New submission from daniel hahler : I was a bit surprised to find that unittest's assertRaises clears the locals on the traceback, which e.g. prevents pytest to display them in case of failures. This was done via https://bugs.python.org/issue9815

[issue39763] distutils.spawn should use subprocess (hang in parallel builds on QNX)

2020-02-26 Thread Elad Lahav
Elad Lahav added the comment: "Your script contains a bug (there is no definition of 'exec_fn')" Told you I wasn't much of a Python developer ;-) This was just copy-pasted from spawn.py and I missed the fact that exec_fn() is not a library function. Your last comment wasn't clear - do you

[issue27657] urlparse fails if the path is numeric

2020-02-26 Thread Ned Deily
Ned Deily added the comment: FYI, for those following along, now that 3.8.2 has been released with the revert of the regression, we are planning to accelerate the schedule for 3.7.7, the next 3.7.x bugfix release, in part to get the revert out to 3.7.x users sooner

[issue39760] ast.FormattedValue.format_spec unnecessarily wrapped in JoinedStr

2020-02-26 Thread Eric V. Smith
Eric V. Smith added the comment: > FYI you can use ast CLI: I did not know that. That's awesome, thanks for pointing it out. -- ___ Python tracker ___

[issue36144] Dictionary union. (PEP 584)

2020-02-26 Thread Brandt Bucher
Brandt Bucher added the comment: Yep. I'm currently working on OrderedDict, defaultdict, and MappingProxyType. My brother is looking to make his first contribution, so he'll be taking care of ChainMap. -- ___ Python tracker

[issue39761] Python 3.9.0a4 fails to build when configured with --with-dtrace

2020-02-26 Thread Miro Hrončok
Miro Hrončok added the comment: Oh, my bad. DFLAGS=" " ^ that indeed works. -- ___ Python tracker ___ ___ Python-bugs-list

[issue39758] StreamWriter.wait_closed() can hang indefinitely.

2020-02-26 Thread Julien Palard
Julien Palard added the comment: Can reproduce in: - 3.8.0 - 3.8.2 - 3.7.6 -- nosy: +mdk ___ Python tracker ___ ___

[issue39761] Python 3.9.0a4 fails to build when configured with --with-dtrace

2020-02-26 Thread David Carlier
David Carlier added the comment: If it works for you, it might mean making a specific case for Linux systems in configure.ac as a proper fix. -- ___ Python tracker ___

[issue38066] Hide internal asyncio.Stream methods

2020-02-26 Thread tzickel
tzickel added the comment: The documentation needs to scrub this methods as well, for example: https://docs.python.org/3/library/asyncio-stream.html#asyncio.StreamReader.at_eof still mentions them. -- nosy: +tzickel ___ Python tracker

[issue39761] Python 3.9.0a4 fails to build when configured with --with-dtrace

2020-02-26 Thread David Carlier
David Carlier added the comment: ah sorry I meant DFLAGS=" " (with a space). -- ___ Python tracker ___ ___ Python-bugs-list

[issue39765] asyncio loop.set_signal_handler() may not behave as expected

2020-02-26 Thread Roger Dahl
Change by Roger Dahl : -- keywords: +patch pull_requests: +18028 stage: -> patch review pull_request: https://github.com/python/cpython/pull/18664 ___ Python tracker ___

[issue39765] asyncio loop.set_signal_handler() may not behave as expected

2020-02-26 Thread Roger Dahl
New submission from Roger Dahl : This is a ticket to document two ways in which the behavior of loop.set_signal_handler() may not match what the user expects. First, callbacks to handlers registered with loop.set_signal_handler() may be significantly delayed. I have a program where I've

[issue39761] Python 3.9.0a4 fails to build when configured with --with-dtrace

2020-02-26 Thread Miro Hrončok
Miro Hrončok added the comment: $ make clean && make distclean $ git clean -x $ export DFLAGS="" $ export DFFLAGS="" $ ./configure --with-dtrace && make ... undefined reference to `python_audit_semaphore' ... -- ___ Python tracker

[issue39763] distutils.spawn should use subprocess (hang in parallel builds on QNX)

2020-02-26 Thread Guido van Rossum
Guido van Rossum added the comment: @Antoine: I can sort of see why you consider the small example a red herring, since it mixes threads and fork. Nevertheless, a simpler version (not using an executor) would probably work just fine? It's the edge cases where the mixture becomes explosive.

[issue39763] distutils.spawn should use subprocess (hang in parallel builds on QNX)

2020-02-26 Thread Elad Lahav
Elad Lahav added the comment: I'm not convinced that a multi-threaded fork()+exec() from C would be any better, unless the Python code goes to great lengths to avoid any non-async-signal-safe operations between the fork() and the exec(). So along with the proposed change to switch to the

[issue22947] Enable 'imageop' - "Multimedia Srvices Feature module" for 64-bit platform

2020-02-26 Thread Serhiy Storchaka
Serhiy Storchaka added the comment: Python 2.7 no longer supported. -- nosy: +serhiy.storchaka resolution: -> out of date stage: -> resolved status: open -> closed ___ Python tracker

[issue39763] distutils.spawn should use subprocess (hang in parallel builds on QNX)

2020-02-26 Thread Antoine Pitrou
Change by Antoine Pitrou : -- nosy: +dstufft, eric.araujo, p-ganssle, vstinner ___ Python tracker ___ ___ Python-bugs-list mailing

[issue39763] distutils.spawn should use subprocess (hang in parallel builds on QNX)

2020-02-26 Thread Antoine Pitrou
Change by Antoine Pitrou : -- title: Hang after fork due to logging trying to reacquire the module lock in an atfork() handler -> distutils.spawn should use subprocess (hang in parallel builds on QNX) ___ Python tracker

[issue36144] Dictionary union. (PEP 584)

2020-02-26 Thread Guido van Rossum
Guido van Rossum added the comment: @Brandt: you have some more followup PRs planned right? Let's keep this issue open until you've done all of those. -- ___ Python tracker

[issue39763] Hang after fork due to logging trying to reacquire the module lock in an atfork() handler

2020-02-26 Thread Antoine Pitrou
Antoine Pitrou added the comment: Note the original problem stems when you using "setup.py -j ". The attached reproducer is a bit of a red herring, because indeed doing fork() + exec() in pure Python is too fragile. That is why the standard subprocess does it in C. The problem here is

[issue36144] Dictionary union. (PEP 584)

2020-02-26 Thread Guido van Rossum
Guido van Rossum added the comment: New changeset d0ca9bd93bb9d8d4aa9bbe939ca7fd54ac870c8f by Brandt Bucher in branch 'master': bpo-36144: Document PEP 584 (GH-18659) https://github.com/python/cpython/commit/d0ca9bd93bb9d8d4aa9bbe939ca7fd54ac870c8f --

[issue39762] PyLong_AS_LONG missing from longobject.h

2020-02-26 Thread Serhiy Storchaka
Serhiy Storchaka added the comment: The reason why there was the PyInt_AS_LONG macro is that it is very simple and efficient. It never fails, because the value of the int object always fits in the C long. PyInt_AsLong is much slower. If you know that the object is int, you can use

[issue39763] Hang after fork due to logging trying to reacquire the module lock in an atfork() handler

2020-02-26 Thread Guido van Rossum
Change by Guido van Rossum : -- nosy: +gvanrossum, pitrou ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscribe:

[issue39699] Some CIs silence potentially useful output from make

2020-02-26 Thread Steve Dower
Steve Dower added the comment: New changeset 343bc06d8047e4a2e675394528dbb5155be1b3b5 by Steve Dower in branch '3.8': bpo-39699: Don't silence make on Azure and Github CIs (GH-18583) https://github.com/python/cpython/commit/343bc06d8047e4a2e675394528dbb5155be1b3b5 --

[issue39698] asyncio.sleep() does not adhere to time.sleep() behavior for negative numbers

2020-02-26 Thread Marco Sulla
Marco Sulla added the comment: > I also distinctly remember seeing code (and writing such code myself) that > performs computation on timeouts and does not care if the end value goes > below 0. This is not a good statistics. Frankly we can't measure the impact of the change from these

[issue39698] asyncio.sleep() does not adhere to time.sleep() behavior for negative numbers

2020-02-26 Thread Marco Sulla
Change by Marco Sulla : -- resolution: not a bug -> rejected ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscribe:

[issue39699] Some CIs silence potentially useful output from make

2020-02-26 Thread Steve Dower
Change by Steve Dower : -- pull_requests: +18027 pull_request: https://github.com/python/cpython/pull/18671 ___ Python tracker ___

[issue39699] Some CIs silence potentially useful output from make

2020-02-26 Thread Steve Dower
Change by Steve Dower : -- pull_requests: +18026 pull_request: https://github.com/python/cpython/pull/18670 ___ Python tracker ___

[issue39761] Python 3.9.0a4 fails to build when configured with --with-dtrace

2020-02-26 Thread David Carlier
David Carlier added the comment: Weird I just tried on ubuntu/systemtap... -- ___ Python tracker ___ ___ Python-bugs-list mailing

[issue39764] PyAsyncGenObject causes task.get_stack() raising AttributeError

2020-02-26 Thread Lidi Zheng
New submission from Lidi Zheng : This issue exists since 3.6. The implementation of get stack on Task is looking for two attribute [1]: "cr_frame" for coroutines, "gi_frame" for generators (legacy coroutines). However, PyAsyncGenObject provides none of them but "ag_frame" [2]. Fix PR:

[issue39761] Python 3.9.0a4 fails to build when configured with --with-dtrace

2020-02-26 Thread Miro Hrončok
Miro Hrončok added the comment: Nope. -- ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscribe:

[issue39761] Python 3.9.0a4 fails to build when configured with --with-dtrace

2020-02-26 Thread David Carlier
David Carlier added the comment: What about DFFLAGS=" " ? -- ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscribe:

[issue39699] Some CIs silence potentially useful output from make

2020-02-26 Thread Steve Dower
Steve Dower added the comment: New changeset 6aa1f1ecf7142a4117eedb8c570f30da1598616c by Ammar Askar in branch 'master': bpo-39699: Don't silence make on Azure and Github CIs (GH-18583) https://github.com/python/cpython/commit/6aa1f1ecf7142a4117eedb8c570f30da1598616c --

[issue25397] improve ac_cv_have_long_long_format GCC fallback

2020-02-26 Thread Serhiy Storchaka
Serhiy Storchaka added the comment: It is too later for 2.7. The long long type is required for recent Python 3 versions, so this macro is no longer used. -- nosy: +serhiy.storchaka resolution: -> out of date stage: -> resolved status: open -> closed

[issue39763] Hang after fork due to logging trying to reacquire the module lock in an atfork() handler

2020-02-26 Thread Elad Lahav
New submission from Elad Lahav : The attached code causes the child processes to hang on QNX. The hang is caused by the logging module trying to acquire the module lock while in an atfork() handler. In a system where semaphore state is kept in user mode and is thus inherited from the parent

[issue23164] "pydoc filter" documentation restrictive

2020-02-26 Thread Serhiy Storchaka
Serhiy Storchaka added the comment: It was fixed in Python 3, and it is too late for 2.7. -- nosy: +serhiy.storchaka resolution: -> out of date stage: -> resolved status: open -> closed ___ Python tracker

[issue22714] target of 'import statement' entry in general index for 'i' is wrong

2020-02-26 Thread Serhiy Storchaka
Serhiy Storchaka added the comment: There are 5 links for the "import statement" entry. Issue35506 partially solved the problem -- the main link is now emphasized. But it is still the last of links. I afraid it is a limitation of Sphinx. If no other solution be proposed I'll close this

[issue34396] Certain methods that heap allocated subtypes inherit suffer a 50-80% performance penalty

2020-02-26 Thread Marco Sulla
Marco Sulla added the comment: I asked why on StackOverflow, and an user seemed to find the reason. The problem for him/her is in `update_one_slot()`. `dict` implements directly `__contains__()` and `__getitem__()`. Usually, `sq_contains` and `mp_subscript` are wrapped to implement

[issue39754] update_one_slot() does not inherit sq_contains and mp_subscript if they are explictly declared

2020-02-26 Thread Marco Sulla
Change by Marco Sulla : -- resolution: -> duplicate stage: -> resolved status: open -> closed ___ Python tracker ___ ___

[issue39762] PyLong_AS_LONG missing from longobject.h

2020-02-26 Thread Enji Cooper
Enji Cooper added the comment: @serhiy.storchaka: understood. Figured this would be a good errata note for others to potentially find in the future. -- ___ Python tracker

[issue39761] Python 3.9.0a4 fails to build when configured with --with-dtrace

2020-02-26 Thread Miro Hrončok
Miro Hrončok added the comment: export DFLAGS="" does not seem to workaround this. $ make distclean && export DFLAGS="" && ./configure --with-dtrace && make ... undefined reference to `python_line_semaphore' ... -- ___ Python tracker

[issue31015] PyErr_WriteUnraisable should be more verbose in Python 2.7

2020-02-26 Thread Serhiy Storchaka
Serhiy Storchaka added the comment: It is too late for 2.7. -- nosy: +serhiy.storchaka resolution: -> wont fix stage: -> resolved status: open -> closed ___ Python tracker

[issue8269] Missing return values for PyUnicode C/API functions

2020-02-26 Thread Serhiy Storchaka
Serhiy Storchaka added the comment: Sorry, we missed this issue. refcounts.dat was updated in other issues. -- nosy: +serhiy.storchaka resolution: -> out of date stage: patch review -> resolved status: open -> closed ___ Python tracker

[issue39762] PyLong_AS_LONG missing from longobject.h

2020-02-26 Thread Serhiy Storchaka
Serhiy Storchaka added the comment: Python 2 is no longer supported. -- nosy: +serhiy.storchaka resolution: -> out of date stage: -> resolved status: open -> closed ___ Python tracker

[issue39762] PyLong_AS_LONG missing from longobject.h

2020-02-26 Thread Enji Cooper
Enji Cooper added the comment: Workaround PR posted here: https://github.com/encukou/py3c/pull/28 -- ___ Python tracker ___ ___

[issue39762] PyLong_AS_LONG missing from longobject.h

2020-02-26 Thread Enji Cooper
Enji Cooper added the comment: For the record, this seems like it might be the only discrepancy, per the py3c project's exported PyInt APIs: $ for api in `awk '$2 ~ /^PyInt/ { print $3 }' include/py3c/compat.h`; do grep -q $api /usr/include/python2.7/longobject.h || echo $api; done

[issue39762] PyLong_AS_LONG missing from longobject.h

2020-02-26 Thread Enji Cooper
Enji Cooper added the comment: For the record, some projects (like Cython, pywin32) worked around this by adding a preprocessor alias, PyLong_AS_LONG -> PyInt_AS_LONG with python 2.x. -- ___ Python tracker

  1   2   >