[issue29590] Incorrect stack traces when re-entering a generator/coroutine stack via .throw()

2020-05-04 Thread Chris Jerdonek


Chris Jerdonek  added the comment:

I proposed a PR to fix this: https://github.com/python/cpython/pull/19896

--

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue29587] Generator/coroutine 'throw' discards exc_info state, which is bad

2020-05-04 Thread Chris Jerdonek


Chris Jerdonek  added the comment:

Since none of you are subscribed to the other issue except for Nathaniel, I 
thought I'd let you know I also posted a PR to fix another issue he filed 
similar to this one (but this time about the stack trace being incorrect for 
`gen.throw()` in certain circumstances): https://bugs.python.org/issue29590

That issue is the second of the two issues he cited back in 2017 about 
`gen.throw()` being broken:
https://vorpus.org/~njs/misc/trio-language-summit-2017.pdf

--

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue40408] GenericAlias does not support nested type variables

2020-05-04 Thread Serhiy Storchaka


Serhiy Storchaka  added the comment:


New changeset 41a64587a0fd68bcd21ba42999cd3940801dff7c by Serhiy Storchaka in 
branch 'master':
bpo-40408: Fix support of nested type variables in GenericAlias. (GH-19836)
https://github.com/python/cpython/commit/41a64587a0fd68bcd21ba42999cd3940801dff7c


--

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue40408] GenericAlias does not support nested type variables

2020-05-04 Thread Serhiy Storchaka


Change by Serhiy Storchaka :


--
resolution:  -> fixed
stage: patch review -> resolved
status: open -> closed

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue40494] collections.abc.Callable and type variables

2020-05-04 Thread Serhiy Storchaka


New submission from Serhiy Storchaka :

There is a difference between typing.Callable and collections.abc.Callable.

>>> import typing, collections.abc
>>> T = typing.TypeVar('T')
>>> C1 = typing.Callable[[T], T]
>>> C2 = collections.abc.Callable[[T], T]
>>> C1
typing.Callable[[~T], ~T]
>>> C2
collections.abc.Callable[[~T], ~T]
>>> C1[int]
typing.Callable[[int], int]
>>> C2[int]
collections.abc.Callable[[~T], int]

--
components: Library (Lib)
messages: 368015
nosy: gvanrossum, levkivskyi, serhiy.storchaka
priority: normal
severity: normal
status: open
title: collections.abc.Callable and type variables
type: behavior
versions: Python 3.9

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue40491] Typo in SyntaxError produced by pegen for numeric literals

2020-05-04 Thread Serhiy Storchaka


Serhiy Storchaka  added the comment:


New changeset c3f001461d5794c81cf5f70e08ae5435fe935ceb by Shantanu in branch 
'master':
bpo-40491: Fix typo in syntax error for numeric literals (GH-19893)
https://github.com/python/cpython/commit/c3f001461d5794c81cf5f70e08ae5435fe935ceb


--
nosy: +serhiy.storchaka

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue40491] Typo in SyntaxError produced by pegen for numeric literals

2020-05-04 Thread Serhiy Storchaka


Change by Serhiy Storchaka :


--
resolution:  -> fixed
stage: patch review -> resolved
status: open -> closed
type:  -> behavior
versions: +Python 3.9

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue40426] Unable to use lowercase hexadecimal digits for percent encoding

2020-05-04 Thread Serhiy Storchaka


Serhiy Storchaka  added the comment:

What is wrong with the current behavior? Why does the case of hexadecimal 
digits matter?

There are no options to repr() to control the case of hexadecimal digits in 
 and '\ufffe', and I doubt there are such 
options in other functions producing hexadecimals. So it is a very uncommon 
request.

--
nosy: +serhiy.storchaka

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue40492] -m cProfile -o f.pstats with a script that does chdir() writes to the changed directory and not `.`

2020-05-04 Thread Serhiy Storchaka


Serhiy Storchaka  added the comment:

I think it is worth to fix and it should be not difficult to fix. Either make 
the output file name absolute before executing the script, or open the output 
file before executing the script (what is easier). Unless I miss something.

--
nosy: +serhiy.storchaka
stage:  -> patch review
versions: +Python 3.7, Python 3.8

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue40408] GenericAlias does not support nested type variables

2020-05-04 Thread Ivan Levkivskyi


Ivan Levkivskyi  added the comment:

> But this behavior is not specified and is not covered by tests.

FWIW, to be most close to the static type checkers behavior, both D[int][str] 
and D[int, str] should fail for D = Dict[T, List]. Not important however, since 
this is a really rare corner case I think.

--

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue40494] collections.abc.Callable and type variables

2020-05-04 Thread Ivan Levkivskyi


Ivan Levkivskyi  added the comment:

Here I think the behavior of typing.Callable is correct.

--

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue40051] Dead link in help(lib2to3/idlelib/turtledemo/tkinter.sub/test_*/?)

2020-05-04 Thread wyz23x2


wyz23x2  added the comment:

Patch?

--

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue40495] compileall: option to hardlink duplicate optimization levels bytecode cache files

2020-05-04 Thread Lumír Balhar

New submission from Lumír Balhar :

We would like to include a possibility of hardlink deduplication of identical 
pyc files to compileall module in Python 3.9. We've discussed the change [0] 
and tested it in Fedora RPM build system via implementation in the compileall2 
module [1].

The discussion [0] contains a lot of details so I mention here only the key 
features:
* the deduplication can be enabled only if multiple optimization levels are 
processed at once
* it generates a pyc file (optimization level 0) as usual but if it finds that 
optimized files (optimization levels 1 and 2) have the same content, it uses 
hardlinks (os.link) to prevents duplicates
* the deduplication is disabled by default

We believe that this might be handy for more Pythonistas. In our case, this 
functionality lowers the installation size of Python 3.9 from 125 MiB to 103 
MiB.

[0] 
https://discuss.python.org/t/compileall-option-to-hardlink-duplicate-optimization-levels-bytecode-cache-files/3014
[1] https://github.com/fedora-python/compileall2

--
components: Library (Lib)
messages: 368022
nosy: frenzy
priority: normal
severity: normal
status: open
title: compileall: option to hardlink duplicate optimization levels bytecode 
cache files
type: enhancement
versions: Python 3.9

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue40495] compileall: option to hardlink duplicate optimization levels bytecode cache files

2020-05-04 Thread Miro Hrončok

Change by Miro Hrončok :


--
nosy: +hroncok

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue40495] compileall: option to hardlink duplicate optimization levels bytecode cache files

2020-05-04 Thread Filipe Laíns

Change by Filipe Laíns :


--
nosy: +FFY00

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue40495] compileall: option to hardlink duplicate optimization levels bytecode cache files

2020-05-04 Thread Christian Heimes


Christian Heimes  added the comment:

Python's import system is fully compatible with this approach.

importlib never directly writes to a .pyc file. Instead it always creates a new 
temporary file next to the .pyc file and then overrides the .pyc file with an 
atomic file system operation. See _write_atomic() in 
Lib/importlib/_bootstrap_external.py.

compileall and py_compile also use _write_atomic().

--
nosy: +christian.heimes

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue40495] compileall: option to hardlink duplicate optimization levels bytecode cache files

2020-05-04 Thread Christian Heimes


Christian Heimes  added the comment:

Brett, FYI

--
nosy: +brett.cannon

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue40495] compileall: option to hardlink duplicate optimization levels bytecode cache files

2020-05-04 Thread Lumír Balhar

Lumír Balhar  added the comment:

I forgot to mention that I am working on PR which should be ready soon because 
the implementation is already done and tested in compileall2.

--

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue40496] re.findall() deadlock on Python 3.6.10

2020-05-04 Thread Sergio Rael


New submission from Sergio Rael :

I have found a deadlock using Python 3.6.10 that seems to have been solved on 
3.7.x. probably related to capture groups. To reproduce the deadlock just do 
something like this:

re.findall(
'\[et_pb_image(?:\w|=|"|\d|\.| 
|_|\/)*src="(https?:\/\/(?:www\.)?\w*\.\w*(?:\/|\w|\d|\.|-)*\.(?:png|jpg|jpeg|gif))"(?:\w|=|"|\d|\.|
 |_|\/|%|\|)*(?:\/?\])(?:\[\/et_pb_image\])?',
'[et_pb_image _builder_version="3.27.2" 
src="https://www.somewhere.com/wp-content/uploads/2019/08/stabilizers.jpg"; 
box_shadow_horizontal_tablet="0px" box_shadow_vertical_tablet="0px" 
box_shadow_blur_tablet="40px" box_shadow_spread_tablet="0px" 
z_index_tablet="500" url="https://youtu.be/fTrC5gkyYBM"; url_new_window="on" /]',
)

I noticed that the problem is related to having two image urls on the content. 
The regex says to look only for the one starting with "src=" so the one 
starting with "url=" should be ignored. If "url=\"XXX\"" is removed from the 
tag it works fine.

--
components: Regular Expressions
messages: 368026
nosy: ezio.melotti, mrabarnett, srael
priority: normal
severity: normal
status: open
title: re.findall() deadlock on Python 3.6.10
type: behavior
versions: Python 3.6

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue40497] subprocess.check_output() accept the check keyword argument

2020-05-04 Thread Rémi Lapeyre

New submission from Rémi Lapeyre :

The subprocess.check_output() raises TypeError when given the `check` 
keyword-argument:

Python 3.8.2 (v3.8.2:7b3ab5921f, Feb 24 2020, 17:52:18) 
[Clang 6.0 (clang-600.0.57)] on darwin
Type "help", "copyright", "credits" or "license" for more information.
>>> import subprocess
>>> subprocess.check_output(['ls'], check=False)
Traceback (most recent call last):
  File "", line 1, in 
  File 
"/Library/Frameworks/Python.framework/Versions/3.8/lib/python3.8/subprocess.py",
 line 411, in check_output
return run(*popenargs, stdout=PIPE, timeout=timeout, check=True,
TypeError: run() got multiple values for keyword argument 'check'

It should just use True as the default when it's not specified in kwargs.

--
components: Library (Lib)
messages: 368027
nosy: remi.lapeyre
priority: normal
severity: normal
status: open
title: subprocess.check_output() accept the check keyword argument
type: behavior
versions: Python 3.7, Python 3.8, Python 3.9

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue40497] subprocess.check_output() accept the check keyword argument

2020-05-04 Thread Rémi Lapeyre

Change by Rémi Lapeyre :


--
keywords: +patch
pull_requests: +19208
stage:  -> patch review
pull_request: https://github.com/python/cpython/pull/19897

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue40360] Deprecate lib2to3 (and 2to3) for future removal

2020-05-04 Thread Miro Hrončok

Change by Miro Hrončok :


--
pull_requests: +19209
pull_request: https://github.com/python/cpython/pull/19898

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue40496] re.findall() takes a long time (100% cup usage) on Python 3.6.10

2020-05-04 Thread Sergio Rael


Sergio Rael  added the comment:

Sorry, this is not a deadlock. Python puts the CPU to 100% of usage, but it 
takes so long that a I didn't know if it can finish the task.

--
title: re.findall() deadlock on Python 3.6.10 -> re.findall() takes a long time 
(100% cup usage) on Python 3.6.10

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue40497] subprocess.check_output() accept the check keyword argument

2020-05-04 Thread Christian Heimes


Christian Heimes  added the comment:

-1

check_output() should not accept check=False. Please only improve the error 
message. I would be fine with accepting check=True, too

--
nosy: +christian.heimes
stage: patch review -> 

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue40496] re.findall() takes a long time (100% cup usage) on Python 3.6.10

2020-05-04 Thread Rémi Lapeyre

Rémi Lapeyre  added the comment:

I don't think this is a deadlock rather it is certainly related to the number 
of '*' there is in your pattern, the regexp has to search an exponentially 
growing number of patterns. 

You could try a simple pattern to match your attribute and it should be faster.

--
nosy: +remi.lapeyre

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue40497] subprocess.check_output() accept the check keyword argument

2020-05-04 Thread Rémi Lapeyre

Rémi Lapeyre  added the comment:

> check_output() should not accept check=False.

I thought about raising ValueError instead but `subprocess.check_output([...], 
check=False)` is actually a convenient shortcut over `subprocess.run([...], 
stdout=subprocess.PIPE).stdout` and I can't think of much drawbacks if someone 
explicitly ask for the check to be disabled. Is there any way we could have 
that?

--

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue40497] subprocess.check_output() accept the check keyword argument

2020-05-04 Thread Christian Heimes


Christian Heimes  added the comment:

IMHO it's both confusing and bad API design to have a function like

validate_result(..., validate=False)

Now a reviewer has to check that a developer uses the validate_result() 
function *and* the developer is not passing validate=False into the function.

GH-19897 is also provides a new feature, so it cannot get into Python 3.7 and 
3.8.

--

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue40489] INCREF/DECREFs around the rich comparison needs tests

2020-05-04 Thread Serhiy Storchaka


Serhiy Storchaka  added the comment:

See issue1517.

--

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue40334] PEP 617: new PEG-based parser

2020-05-04 Thread Pablo Galindo Salgado


Pablo Galindo Salgado  added the comment:


New changeset e10e7c771bf06112c4a311e0ef6b8af6423b0cca by Lysandros Nikolaou in 
branch 'master':
bpo-40334: Spacialized error message for invalid args after bare '*' (GH-19865)
https://github.com/python/cpython/commit/e10e7c771bf06112c4a311e0ef6b8af6423b0cca


--

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue40497] subprocess.check_output() accept the check keyword argument

2020-05-04 Thread Rémi Lapeyre

Rémi Lapeyre  added the comment:

> Now a reviewer has to check that a developer uses the validate_result() 
> function *and* the developer is not passing validate=False into the function.

Fair enough, I updated the PR to raise ValueError instead.

--

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue39159] Ideas for making ast.literal_eval() usable

2020-05-04 Thread Batuhan Taskaya


Change by Batuhan Taskaya :


--
keywords: +patch
pull_requests: +19210
stage:  -> patch review
pull_request: https://github.com/python/cpython/pull/19899

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue40334] PEP 617: new PEG-based parser

2020-05-04 Thread Charalampos Stratakis


Change by Charalampos Stratakis :


--
nosy:  -cstratak

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue40334] PEP 617: new PEG-based parser

2020-05-04 Thread Miro Hrončok

Change by Miro Hrončok :


--
nosy:  -hroncok

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue40498] Holding spacebar on button widget permanently makes it SUNKEN even after release (and wait).

2020-05-04 Thread PythonAmateur742


New submission from PythonAmateur742 :

See my Stack Overflow question for an example code.

https://stackoverflow.com/questions/61588397/problems-with-tkinter-button-bindings-and-behaviour

Reproduction:

1. create a single button (even without command)
2. Use tab to navigate to the button.
3. Hold space for a bit.

result: Button is now SUNKEN. Even after clicking or pressing the space again.

--
components: Tkinter
messages: 368036
nosy: PythonAmateur742
priority: normal
severity: normal
status: open
title: Holding spacebar on button widget permanently makes it SUNKEN even after 
release (and wait).
type: behavior

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue40498] Holding spacebar on button widget permanently makes it SUNKEN even after release (and wait).

2020-05-04 Thread PythonAmateur742


PythonAmateur742  added the comment:

This is a win10 issue. I haven't tried it on linux.

--

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue40246] Different error messages for same error - invalid string prefixes

2020-05-04 Thread Pablo Galindo Salgado


Pablo Galindo Salgado  added the comment:


New changeset 846d8b28ab9bb6197ee81372820311c0abe509c0 by Lysandros Nikolaou in 
branch 'master':
bpo-40246: Revert reporting of invalid string prefixes (GH-19888)
https://github.com/python/cpython/commit/846d8b28ab9bb6197ee81372820311c0abe509c0


--

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue40246] Different error messages for same error - invalid string prefixes

2020-05-04 Thread Lysandros Nikolaou


Lysandros Nikolaou  added the comment:

The revert is in. Now the question is if we want to take additional action to 
address the original issue of this.

--

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue40246] Different error messages for same error - invalid string prefixes

2020-05-04 Thread Miro Hrončok

Miro Hrončok  added the comment:

I will soon come back with what Fedora package were affected by the problem. 
That could give some data about how to handle this.

--

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue33453] from __future__ import annotations breaks dataclasses ClassVar and InitVar handling

2020-05-04 Thread Filipe Laíns

Change by Filipe Laíns :


--
nosy: +FFY00

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue40499] asyncio.wait documentation on non-emptiness requirement lost in bpo-33649

2020-05-04 Thread Joel Rosdahl


New submission from Joel Rosdahl :

bpo-21596 documented that the sequence of futures passed to asyncio.wait must 
not be empty:

The sequence *futures* must not be empty.

This note was however lost in the bpo-33649 commit
(3faaa8857a42a36383bb18425444e597fc876797).

--
assignee: docs@python
components: Documentation
messages: 368041
nosy: Joel Rosdahl, docs@python
priority: normal
severity: normal
status: open
title: asyncio.wait documentation on non-emptiness requirement lost in bpo-33649
versions: Python 3.7, Python 3.8, Python 3.9

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue39159] Ideas for making ast.literal_eval() usable

2020-05-04 Thread Serhiy Storchaka


Serhiy Storchaka  added the comment:

It can also crash.

ast.literal_eval('+0'*10**6)

The cause is that all AST handling C code (in particularly converting the AST 
from C to Python) is recursive, and therefore can overflow the C stack. Some 
recursive code has arbitrary limits which cause raising exceptions like 
MemoryError in the initial example, but not all code has such checks.

--
nosy: +serhiy.storchaka

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue40499] asyncio.wait documentation on non-emptiness requirement lost in bpo-33649

2020-05-04 Thread Joel Rosdahl


Change by Joel Rosdahl :


--
keywords: +patch
nosy: +jrosdahl
nosy_count: 2.0 -> 3.0
pull_requests: +19211
stage:  -> patch review
pull_request: https://github.com/python/cpython/pull/19900

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue21596] asyncio.wait fails when futures list is empty

2020-05-04 Thread Joel Rosdahl


Change by Joel Rosdahl :


--
nosy: +jrosdahl
nosy_count: 8.0 -> 9.0
pull_requests: +19212
pull_request: https://github.com/python/cpython/pull/19900

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue33649] asyncio docs overhaul

2020-05-04 Thread Joel Rosdahl


Change by Joel Rosdahl :


--
nosy: +jrosdahl
nosy_count: 14.0 -> 15.0
pull_requests: +19213
pull_request: https://github.com/python/cpython/pull/19900

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue40495] compileall: option to hardlink duplicate optimization levels bytecode cache files

2020-05-04 Thread Lumír Balhar

Change by Lumír Balhar :


--
keywords: +patch
pull_requests: +19214
stage:  -> patch review
pull_request: https://github.com/python/cpython/pull/19901

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue40500] test_multiprocessing_fork leaks processes on PPC64LE RHEL8 LTO + PGO 3.x

2020-05-04 Thread STINNER Victor


New submission from STINNER Victor :

PPC64LE RHEL8 LTO + PGO 3.x:
https://buildbot.python.org/all/#/builders/450/builds/313

0:01:22 load avg: 7.01 [242/423/1] test_multiprocessing_fork failed (env 
changed) (1 min 17 sec) -- running: test_concurrent_futures (1 min 3 sec), 
test_multiprocessing_forkserver (1 min 19 sec)

Warning -- multiprocessing.Manager still has [, ] active children 
after 5.1161000469874125 seconds

Warning -- Dangling processes: {}

Warning -- multiprocessing.Manager still has [, ] active children after 
5.116447829990648 seconds

test__all__ (test.test_multiprocessing_fork.MiscTestCase) ... ok
test_answer_challenge_auth_failure (test.test_multiprocessing_fork.OtherTest) 
... ok
test_deliver_challenge_auth_failure (test.test_multiprocessing_fork.OtherTest) 
... ok
(...)

--
components: Tests
messages: 368043
nosy: pitrou, tomMoral, vstinner
priority: normal
severity: normal
status: open
title: test_multiprocessing_fork leaks processes on PPC64LE RHEL8 LTO + PGO 3.x
versions: Python 3.9

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue40051] Dead link in help(lib2to3/idlelib/turtledemo/tkinter.sub/test_*/?)

2020-05-04 Thread Terry J. Reedy


Terry J. Reedy  added the comment:

Not until decision made.  And not be me until I have my development machine 
running.

--

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue40246] Different error messages for same error - invalid string prefixes

2020-05-04 Thread Miro Hrončok

Miro Hrončok  added the comment:

Not that many:

cpython itself (fixed via PR)
demjson (fixed via PR)
asn1crypto (fixed via PR)
dnf (fixed via PR)
freeipa (fixed via PR)

I gave up sending PRs at this point.

waf
weasyprint
virt-who
thrift
salt
wxpython4
rosdistro
mne
pycairo
libstoragemgmt (possibly via bundled lsm/external/xmltodict)
dput-ng
ddupdate
aubio (via bundled waf)

--

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue40256] Python 3.8 Not Launching on Bootcamp Windows 10.

2020-05-04 Thread Steve Dower


Steve Dower  added the comment:

I assume the Bootcamp side of this is irrelevant and it's just an issue with 
Windows.

Yusuf, can you open Powershell and run "py" on its own?

If you've been going there and running "python" and you didn't select to update 
PATH, you're probably triggering the redirect to install via the Microsoft 
Store. When you pass that arguments, it fails (correctly) but doesn't print a 
message (incorrectly - I'm trying to get it fixed). But when you run it 
interactively it'll jump you to the store page for Python.

You probably just want to use the "py" launcher, since you've installed that 
way. Or if you install from the Store instead then it'll configure 
python/python3/python3.8 commands for you.

--
components:  -macOS

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue39573] [C API] Make PyObject an opaque structure in the limited C API

2020-05-04 Thread Dong-hee Na


Dong-hee Na  added the comment:


New changeset 5e8ffe147710e449c2e935a4e2ff5cbd19828a8a by Hai Shi in branch 
'master':
bpo-39573: Use Py_IS_TYPE to check for types (GH-19882)
https://github.com/python/cpython/commit/5e8ffe147710e449c2e935a4e2ff5cbd19828a8a


--

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue40455] GCC 10 compiler warnings

2020-05-04 Thread Dong-hee Na


Dong-hee Na  added the comment:


New changeset b88cd585d36d6285a5aeb0b6fdb70c134062181e by Dong-hee Na in branch 
'master':
bpo-40455: Remove gcc10 warning about x_digits (#19852)
https://github.com/python/cpython/commit/b88cd585d36d6285a5aeb0b6fdb70c134062181e


--

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue40489] INCREF/DECREFs around the rich comparison needs tests

2020-05-04 Thread Dong-hee Na


Dong-hee Na  added the comment:

I can crash python interpreter with few lines of code when if we remove those 
codes.



class S(str):

def __eq__(self, other):
d.clear()
return NotImplemented

def __hash__(self):
return hash('test')

d = {S(): 'value'}
'test' in d

--
nosy: +corona10

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue40489] INCREF/DECREFs around the rich comparison needs tests

2020-05-04 Thread Dong-hee Na


Dong-hee Na  added the comment:

Would you like to add a test for this case?

--

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue2380] Raise a Py3K warning for catching nested tuples with non-BaseException exceptions

2020-05-04 Thread Zachary Ware


Zachary Ware  added the comment:

With 2.7 out of support, closing.

--
nosy: +zach.ware
resolution:  -> out of date
stage: needs patch -> resolved
status: open -> closed

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue40489] INCREF/DECREFs around the rich comparison needs tests

2020-05-04 Thread Dong-hee Na


Dong-hee Na  added the comment:

> Would you like to add a test for this case?

Oh, I mean, is it good to add a test for this case?

--

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue29587] Generator/coroutine 'throw' discards exc_info state, which is bad

2020-05-04 Thread STINNER Victor


Change by STINNER Victor :


--
pull_requests: +19216
pull_request: https://github.com/python/cpython/pull/19902

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue29587] Generator/coroutine 'throw' discards exc_info state, which is bad

2020-05-04 Thread STINNER Victor


STINNER Victor  added the comment:

tl; dr I wrote PR 19902 to remove the "XXX" comment.

--

Commit 21893fbb74e8fde2931fbed9b511e2a41362b1ab adds the following code:

/* XXX It seems like we shouldn't have to check not equal to Py_None
   here because exc_type should only ever be a class.  But not including
   this check was causing crashes on certain tests e.g. on Fedora. */
if (gen->gi_exc_state.exc_type && gen->gi_exc_state.exc_type != Py_None) { 
... }

I don't think that you should mention "Fedora" as a platform impacted by this 
issue: all platforms should be affected. It's just unclear why the issue was 
first seen on Fedora.

gen_send_ex() copies tstate->exc_info to gen->gi_exc_state.

tstate->exc_info->exc_type is set at least in the following 3 places in CPython 
code base:

* ceval.c: POP_EXCEPT opcode: exc_info->exc_type = POP();
* ceval.c: UNWIND_EXCEPT_HANDLER() macro: exc_info->exc_type = POP();
* errors.c: PyErr_SetExcInfo()

I saw in practice POP_EXCEPT and UNWIND_EXCEPT_HANDLER() setting 
exc_info->exc_type to Py_None (I didn't test PyErr_SetExcInfo()).

_PyErr_GetTopmostException() also handles exc_info->exc_type == Py_None case:

_PyErr_StackItem *
_PyErr_GetTopmostException(PyThreadState *tstate)
{
_PyErr_StackItem *exc_info = tstate->exc_info;
while ((exc_info->exc_type == NULL || exc_info->exc_type == Py_None) &&
   exc_info->previous_item != NULL)
{
exc_info = exc_info->previous_item;
}
return exc_info;
}

--

So exc_type=None is not a bug, but it's done on purpose.

If you don't want to get None in genobject.c, we should modify all places which 
set tstate->exc_info->exc_type. Problem: the structure currently exposed in the 
public C API (bpo-40429), and I wouldn't be surprised if Cython or greenlet 
modify tstate->exc_info directly.

--

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue40455] GCC 10 compiler warnings

2020-05-04 Thread Andy Lester


Andy Lester  added the comment:

For anyone following along, note that the PR above is different than the 
original suggestion.  The PR correctly sets x_size, not leaving it zero.

--

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue40426] Unable to use lowercase hexadecimal digits for percent encoding

2020-05-04 Thread Lysandros Nikolaou


Change by Lysandros Nikolaou :


--
nosy:  -lys.nikolaou

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue40135] multiprocessing: test_shared_memory_across_processes() cannot be run twice in parallel

2020-05-04 Thread STINNER Victor


STINNER Victor  added the comment:


New changeset caa3ef284a2e5e5b9bdd6a9e619804122c842d80 by Hai Shi in branch 
'master':
bpo-40135: Fix multiprocessing test_shared_memory_across_processes() (GH-19892)
https://github.com/python/cpython/commit/caa3ef284a2e5e5b9bdd6a9e619804122c842d80


--

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue40494] collections.abc.Callable and type variables

2020-05-04 Thread Guido van Rossum


Guido van Rossum  added the comment:

Yeah, the fix will require a variant of types.GenericAlias that substitute's 
type variables in lists.

--

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue40135] multiprocessing: test_shared_memory_across_processes() cannot be run twice in parallel

2020-05-04 Thread STINNER Victor


STINNER Victor  added the comment:

Thanks for the fix Hai Shi!

--
resolution:  -> fixed
stage: patch review -> resolved
status: open -> closed

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue40135] multiprocessing: test_shared_memory_across_processes() cannot be run twice in parallel

2020-05-04 Thread miss-islington


Change by miss-islington :


--
nosy: +miss-islington
nosy_count: 2.0 -> 3.0
pull_requests: +19217
pull_request: https://github.com/python/cpython/pull/19903

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue40494] collections.abc.Callable and type variables

2020-05-04 Thread Serhiy Storchaka


Serhiy Storchaka  added the comment:

Of course. There is more than one way to fix it:

* Make GenericAlias substituting type variables in list. It is easier and it 
will fix this particular case, but there will be subtle differences in __args__.
* Add a GenericAlias subclass with overridden constructor, __repr__, 
__getitem__, __reduce__ (like the _GenericAlias subclass added in issue40397).

I think we should first resolve issue40397 and later decide what way be better. 
It is not necessary to reproduce all details of _GenericAlias if the practical 
behavior is the same.

--

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue32030] PEP 432: Rewrite Py_Main()

2020-05-04 Thread Gregory Szorc


Change by Gregory Szorc :


--
nosy: +indygreg
nosy_count: 7.0 -> 8.0
pull_requests: +19218
pull_request: https://github.com/python/cpython/pull/19746

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue40135] multiprocessing: test_shared_memory_across_processes() cannot be run twice in parallel

2020-05-04 Thread miss-islington


miss-islington  added the comment:


New changeset 70fe95cdc9ac1b00d4f86b7525dca80caf7003e1 by Miss Islington (bot) 
in branch '3.8':
bpo-40135: Fix multiprocessing test_shared_memory_across_processes() (GH-19892)
https://github.com/python/cpython/commit/70fe95cdc9ac1b00d4f86b7525dca80caf7003e1


--

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue40458] test_bad_getattr crashes on APPX test

2020-05-04 Thread Steve Dower


Steve Dower  added the comment:

Yeah, I already got that part. If you check the PR, I added some better 
diagnostics to faulthandler for this case, but I don't see where I can add it 
for other platforms?

--

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue38323] asyncio: MultiLoopWatcher has a race condition (test_asyncio: test_close_kill_running() hangs on AMD64 RHEL7 Refleaks 3.x)

2020-05-04 Thread STINNER Victor


STINNER Victor  added the comment:

Issue open since 2019-09-30 and tests still hang randomly. What's the progress 
on this issue?

--

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue40246] Different error messages for same error - invalid string prefixes

2020-05-04 Thread STINNER Victor


STINNER Victor  added the comment:

Lysandros:
> The revert is in. Now the question is if we want to take additional action to 
> address the original issue of this.

If someone cares of that, I suggest to open an issue in pylint, pyflakes and 
similar tools to emit a warning in linters.

--

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue40334] PEP 617: new PEG-based parser

2020-05-04 Thread STINNER Victor


Change by STINNER Victor :


--
nosy:  -vstinner

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue21596] asyncio.wait fails when futures list is empty

2020-05-04 Thread STINNER Victor


Change by STINNER Victor :


--
nosy:  -vstinner

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue35907] [security][CVE-2019-9948] Unnecessary URL scheme exists to allow local_file:// reading file in urllib

2020-05-04 Thread STINNER Victor


STINNER Victor  added the comment:

> We should whitelist the protocols. The current solution with `getattr` is 
> really fragile. For example, this crashes with a `TypeError`: 
> `URLopener().open("unknown_proxy://test")`

Would you mind to elaborate why do you consider that the solution is 
incomplete? Your issue doesn't show that Python is vulnerable. TypeError *is* 
the expected behavior.

Would you prefer another error message? If yes, please open a seperated issue.

--

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue13097] [easy C issue] ctypes: segfault with large number of callback arguments

2020-05-04 Thread STINNER Victor


STINNER Victor  added the comment:

I suggest to raise an exception if it's called with more than 1024 arguments.

--
keywords: +easy (C), newcomer friendly
title: ctypes: segfault with large number of callback arguments -> [easy C 
issue] ctypes: segfault with large number of callback arguments

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue9216] FIPS support for hashlib

2020-05-04 Thread STINNER Victor


STINNER Victor  added the comment:

> _hashlib.get_fips_mode() is not compatible with new FIPS design in OpenSSL 
> 3.0.0:

I suggest to modify the code so the private function becomes unavailable in 
_hashlib on OpenSSL 3.0 and newer. What do you think?

--

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue40501] Deprecate and remove ctypes usage in uuid

2020-05-04 Thread Steve Dower


New submission from Steve Dower :

The uuid module uses ctypes to try and load likely system libraries to provide 
some functionality of the uuid module.

This is a security risk (depending on your sensitivity to DLL hijacking), but 
it also seems to be not very necessary? It would be nice to remove the ctypes 
usage from an otherwise (almost) pure Python module.

--
components: Library (Lib)
messages: 368066
nosy: steve.dower
priority: normal
severity: normal
stage: test needed
status: open
title: Deprecate and remove ctypes usage in uuid
versions: Python 3.9

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue40025] enum: _generate_next_value_ is not called if its definition occurs after calls to auto()

2020-05-04 Thread hongweipeng


Change by hongweipeng :


--
nosy: +hongweipeng
nosy_count: 9.0 -> 10.0
pull_requests: +19219
pull_request: https://github.com/python/cpython/pull/19904

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue40350] modulefinder chokes on numpy - dereferencing None in spec.loader

2020-05-04 Thread Brett Cannon


Change by Brett Cannon :


--
nosy:  -brett.cannon

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue40501] Deprecate and remove ctypes usage in uuid

2020-05-04 Thread Steve Dower


Steve Dower  added the comment:

There are three scenarios where ctypes is used in this module:

* get libuuid.uuid_generate_time_safe and uuid_generate_time (if _uuid was not 
compiled)
* get rpcrt4.UuidCreateSequential (on Windows, depending on how the libuuid 
lookup failed)
* GetSystemDirectory (on Windows, safe to replace with alternative approach)

I'll happily move the UuidCreateSequential call into _uuid and add it to the 
Windows build, but it's not clear whether the libuuid lookup is important or 
not. If anyone knows of scenarios where you can't compile against libuuid but 
can load it with ctypes, would be great to hear about it!

--

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue40501] Deprecate and remove ctypes usage in uuid

2020-05-04 Thread STINNER Victor


STINNER Victor  added the comment:

uuid.py has a long history. The recent history is the addition of the _uuid 
module which exposes libuuid function properly. IMHO it's a better approach 
than ctypes.

On Windows, it seems like ctypes remains used to get access to Windows function 
UuidCreateSequential(). It is used by uuid.getnode() for example. We should 
expose UuidCreateSequential() in _uuid rather than using ctypes for that.

I propose to do that in two steps:

(A) Ensure that _uuid works on macOS, FreeBSD and Linux, especially in the 
macOS installer of python.org. If yes, remove the ctypes code to access libuuid 
functions.

(B) Add a function to _uuid to expose Windows UuidCreateSequential(), use it in 
uuid.py and remove the related ctypes code.

Both steps can be done in parallel.

--
nosy: +vstinner

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue40417] PyImport_ReloadModule emits deprecation warning

2020-05-04 Thread Brett Cannon


Change by Brett Cannon :


--
versions:  -Python 3.5, Python 3.6, Python 3.9

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue40275] test.support has way too many imports

2020-05-04 Thread hai shi


Change by hai shi :


--
pull_requests: +19220
pull_request: https://github.com/python/cpython/pull/19905

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue40489] INCREF/DECREFs around the rich comparison needs tests

2020-05-04 Thread Dong-hee Na


Change by Dong-hee Na :


--
keywords: +patch
pull_requests: +19221
stage:  -> patch review
pull_request: https://github.com/python/cpython/pull/19906

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue40417] PyImport_ReloadModule emits deprecation warning

2020-05-04 Thread Brett Cannon


Brett Cannon  added the comment:

This can't be backported cleanly. If you're up for making PRs for 3.8 and 3.7, 
Robert, we can look at applying them.

--

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue40501] Deprecate and remove ctypes usage in uuid

2020-05-04 Thread Steve Dower


Steve Dower  added the comment:

Do you think either need a deprecation cycle? I'd say not for the Windows 
change, but I'm not sure whether people could be relying on libuuid showing up 
after build.

--

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue40501] Deprecate and remove ctypes usage in uuid

2020-05-04 Thread Dong-hee Na


Change by Dong-hee Na :


--
nosy: +corona10

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue40501] Deprecate and remove ctypes usage in uuid

2020-05-04 Thread STINNER Victor


STINNER Victor  added the comment:

> Do you think either need a deprecation cycle? I'd say not for the Windows 
> change, but I'm not sure whether people could be relying on libuuid showing 
> up after build.

If the behavior doesn't change, no deprecation is needed.

For example, if libuuid was already used trough _uuid module, the ctypes code 
path is basically just dead code. But it should be checked manually.

--

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue39232] asyncio crashes when tearing down the proactor event loop

2020-05-04 Thread Chris Meyer


Change by Chris Meyer :


--
nosy: +cmeyer

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue40489] INCREF/DECREFs around the rich comparison needs tests

2020-05-04 Thread Dong-hee Na


Dong-hee Na  added the comment:


New changeset 785f5e6d674306052bf865677d885c30561985ae by Dong-hee Na in branch 
'master':
bpo-40489: Add test case for dict contain use after free (GH-19906)
https://github.com/python/cpython/commit/785f5e6d674306052bf865677d885c30561985ae


--

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue40275] test.support has way too many imports

2020-05-04 Thread STINNER Victor


STINNER Victor  added the comment:


New changeset 975408c065b645e7d717546b0d744415abb45cd1 by Hai Shi in branch 
'master':
bpo-40275: test.support imports lazily locale import (GH-19761)
https://github.com/python/cpython/commit/975408c065b645e7d717546b0d744415abb45cd1


--

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue40502] PyNode_New() does not initialize n->n_col_offset

2020-05-04 Thread Tomasz Pytel


New submission from Tomasz Pytel :

I found this by accident by compiling empty strings since I use column 
information from the AST tree, if not initialized I get a starting column of 
-842150451. The easy fix is to initialize n->n_col_offset = 0; in 
Parser/node.c:PyNode_New().

--
components: Interpreter Core
messages: 368074
nosy: Tomasz Pytel
priority: normal
severity: normal
status: open
title: PyNode_New() does not initialize n->n_col_offset
versions: Python 3.9

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue1635741] Py_Finalize() doesn't clear all Python objects at exit

2020-05-04 Thread Dong-hee Na


Change by Dong-hee Na :


--
pull_requests: +19222
pull_request: https://github.com/python/cpython/pull/19907

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue40480] "fnmatch" exponential execution time

2020-05-04 Thread Tim Peters


Tim Peters  added the comment:

Changed version to 3.9, because anything done would change the regexp 
generated, and fnmatch.translate()` makes that regexp visible.

--
stage:  -> needs patch
versions: +Python 3.9 -Python 3.8

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue40480] "fnmatch" exponential execution time

2020-05-04 Thread Tim Peters


Change by Tim Peters :


--
keywords: +patch
pull_requests: +19223
stage: needs patch -> patch review
pull_request: https://github.com/python/cpython/pull/19908

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue40503] PEP 615: Add zoneinfo module

2020-05-04 Thread Paul Ganssle


New submission from Paul Ganssle :

This is an issue to track the implementation of PEP 615: 
https://www.python.org/dev/peps/pep-0615/

It should mostly involve migrating from the reference implementation: 
https://github.com/pganssle/zoneinfo/

--
assignee: p-ganssle
components: Library (Lib)
messages: 368076
nosy: belopolsky, lemburg, p-ganssle
priority: high
severity: normal
stage: needs patch
status: open
title: PEP 615: Add zoneinfo module
type: enhancement
versions: Python 3.9

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue40503] PEP 615: Add zoneinfo module

2020-05-04 Thread Paul Ganssle


Change by Paul Ganssle :


--
keywords: +patch
pull_requests: +19224
stage: needs patch -> patch review
pull_request: https://github.com/python/cpython/pull/19909

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue40360] Deprecate lib2to3 (and 2to3) for future removal

2020-05-04 Thread Gregory P. Smith

Gregory P. Smith  added the comment:


New changeset 18f1c60a1625d341a905c7e07367c32c08f222df by Miro Hrončok in 
branch 'master':
bpo-40360: Add a What's New entry for lib2to3 pending deprecation (GH-19898)
https://github.com/python/cpython/commit/18f1c60a1625d341a905c7e07367c32c08f222df


--

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue39159] Ideas for making ast.literal_eval() usable

2020-05-04 Thread Emmanuel Arias


Change by Emmanuel Arias :


--
nosy: +eamanu

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue40492] -m cProfile -o f.pstats with a script that does chdir() writes to the changed directory and not `.`

2020-05-04 Thread Anthony Sottile


Change by Anthony Sottile :


--
keywords: +patch
pull_requests: +19225
pull_request: https://github.com/python/cpython/pull/19910

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue39470] Indicate that os.makedirs is equivalent to Path.mkdir

2020-05-04 Thread Joannah Nanjekye


Joannah Nanjekye  added the comment:


New changeset f25fb6ebfec894c01bc927c9aae7924ffc826d11 by Joannah Nanjekye in 
branch 'master':
bpo-39470: Indicate that ``os.makedirs`` is equivalent to ``Path.mkdir`` 
(GH-18216)
https://github.com/python/cpython/commit/f25fb6ebfec894c01bc927c9aae7924ffc826d11


--

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue40464] functools.singledispatch doesn't verify annotation is on FIRST parameter

2020-05-04 Thread Dutcho


Dutcho  added the comment:

I'm afraid my "even return" was interpreted in 
https://github.com/python/cpython/pull/19871 as "only return", while as stated 
"any annotation" suffices. To rephrase:
If the *first* parameter of the registered function isn't annotated, any 
non-first annotation suffices for registering, but will not dispatch correctly.
Example:
```
>>> @functools.singledispatch
... def func(arg, x):...
>>> @func.register
... def _int(arg, x:int):...
>>> @func.register
... def _str(arg, x:str):...
```
No errors happen, although parameter `x` is annotated, not the first parameter 
`arg`. So `func()` will dispatch on the type of `arg` according to the 
annotation of `x`.
So I'm afraid the PR solves the specific "return" example case, but not the 
flagged general issue.

--

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



  1   2   >