[issue41818] Lib/pty.py major revision

2020-10-25 Thread Soumendra Ganguly


Change by Soumendra Ganguly :


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

___
Python tracker 

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



[issue26228] pty.spawn hangs on FreeBSD 9.3, 10.x, 12.1

2020-10-25 Thread Soumendra Ganguly


Change by Soumendra Ganguly :


--
pull_requests: +21879
pull_request: https://github.com/python/cpython/pull/22962

___
Python tracker 

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



[issue35823] Use vfork() in subprocess on Linux

2020-10-25 Thread Gregory P. Smith


Gregory P. Smith  added the comment:

Performance improvement measured on a 1.4Ghz quad aarch64 A57 (nvidia jetson 
nano):

#define VFORK_USABLE 1
 test_subprocess: 36.5 seconds

#undef VFORK_USABLE
 test_subprocess: 45 seconds

Nice.  I really didn't expect a 20% speedup on its testsuite alone!

Lets dive into that with a microbenchmark:

$ ./build-novfork/python ten_seconds_of_truth.py
Launching /bin/true for 10 seconds in a loop.
Launched 2713 subprocesses in 10.00194378796732 seconds.
271.247275281014 subprocesses/second.
Increased our mapped pages by 778240KiB.
Launching /bin/true for 10 seconds in a loop.
Launched 212 subprocesses in 10.006392606999725 seconds.
21.186456331095847 subprocesses/second.

$ ./build/python ten_seconds_of_truth.py
Launching /bin/true for 10 seconds in a loop.
Launched 3310 subprocesses in 10.001623224001378 seconds.
330.94628000551285 subprocesses/second.
Increased our mapped pages by 778240KiB.
Launching /bin/true for 10 seconds in a loop.
Launched 3312 subprocesses in 10.001519071985967 seconds.
331.1496959773679 subprocesses/second.

Demonstrating perfectly the benefit of vfork().  The more mapped pages, the 
slower regular fork() becomes.  With vfork() the size of the process's memory 
map does not matter.

ten_seconds_of_truth.py:

```python
from time import monotonic as now
import subprocess

def benchmark_for_ten():
print('Launching /bin/true for 10 seconds in a loop.')

count = 0
start = now()
while now() - start < 10.:
subprocess.run(['/bin/true'])
count += 1
end = now()
duration = end-start

print(f'Launched {count} subprocesses in {duration} seconds.')
print(f'{count/duration} subprocesses/second.')

benchmark_for_ten()

map_a_bunch_of_pages = '4agkahglahaa^#\0ag3\3'*1024*1024*40

print(f'Increased our mapped pages by {len(map_a_bunch_of_pages)//1024}KiB.')

benchmark_for_ten()
```

--

___
Python tracker 

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



[issue38233] datetime.datetime.fromtimestamp have different behaviour on windows and mac

2020-10-25 Thread Ronald Oussoren


Ronald Oussoren  added the comment:

Can this issue be closed? Fixing #36439 would also fix this issue.

--

___
Python tracker 

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



[issue41214] -O0: Segmentation fault in _PyArg_UnpackStack

2020-10-25 Thread LE GARREC Vincent


LE GARREC Vincent  added the comment:

I still have the problem with python 3.7.9 but not with python 3.8.6.

Since I migrated my system to python 3.8, it's not a problem anymore. I still 
have python 3.7 installed so if you want, I still can do some tests.

--
nosy: +bansan85

___
Python tracker 

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



[issue41607] pdb - Clickable path to breakpoints

2020-10-25 Thread Artur Tamborski


Change by Artur Tamborski :


--
keywords: +patch
nosy: +arturtamborski
nosy_count: 2.0 -> 3.0
pull_requests: +21881
stage:  -> patch review
pull_request: https://github.com/python/cpython/pull/22964

___
Python tracker 

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



[issue42120] Depreciated MACRO of copysign for MSVC

2020-10-25 Thread Ronald Oussoren


Ronald Oussoren  added the comment:

The standard is for copysign to work on doubles, with copysignf as the same 
functionality for floats.


https://en.cppreference.com/w/c/numeric/math/copysign

--
nosy: +ronaldoussoren

___
Python tracker 

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



[issue41919] Modify test_codecs to use the new codecs.unregister() function

2020-10-25 Thread Pablo Galindo Salgado


Pablo Galindo Salgado  added the comment:

AS this is masking other issues in the build bots, we need to revert the commit 
unless is fixed in 24 hours per the buildbot workflow

--

___
Python tracker 

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



[issue41919] Modify test_codecs to use the new codecs.unregister() function

2020-10-25 Thread Pablo Galindo Salgado

Pablo Galindo Salgado  added the comment:

Commit c9f696cb96d1c362d5cad871f61da520572d9b08 introduced a reference leak in 
the test suite. See https://bugs.python.org/issue42145:

c9f696cb96d1c362d5cad871f61da520572d9b08 is the first bad commit
commit c9f696cb96d1c362d5cad871f61da520572d9b08
Author: Hai Shi 
Date:   Fri Oct 16 16:34:15 2020 +0800

bpo-41919, test_codecs: Move codecs.register calls to setUp() (GH-22513)

Reverting the commit eliminates the problem:

rences, sum=12
test_io leaked [1, 1, 1, 1] memory blocks, sum=4
test_io failed

== Tests result: FAILURE ==

1 test failed:
test_io

Total duration: 397 ms
Tests result: FAILURE
g
~/github/python/master master|bisect*
❯ git revert c9f696cb96d1c362d5cad871f61da520572d9b08
Auto-merging Lib/test/test_codecs.py
[master f3de7c00b4] Revert "bpo-41919, test_codecs: Move codecs.register calls 
to setUp() (GH-22513)"
 7 files changed, 112 insertions(+), 16 deletions(-)

~/github/python/master master|bisect* ⇡
❯ make -j -s
 CC='gcc -pthread' LDSHARED='gcc -pthread -shared' OPT='-g -Og -Wall'   
_TCLTK_INCLUDES='' _TCLTK_LIBS=''   ./python -E ./setup.py -q build

The following modules found by detect_modules() in setup.py, have been
built by the Makefile instead, as configured by the Setup files:
_abc  atexitpwd
time


~/github/python/master master|bisect* ⇡
❯ ./python -m test test_io -m 
test.test_io.CTextIOWrapperTest.test_read_one_by_one -R :
0:00:00 load avg: 2.57 Run tests sequentially
0:00:00 load avg: 2.57 [1/1] test_io
beginning 9 repetitions
123456789
.

== Tests result: SUCCESS ==

1 test OK.

Total duration: 455 ms
Tests result: SUCCESS

* Move the codecs' (un)register operation to testcases.
* Remove _codecs._forget_codec() and _PyCodec_Forget()

 Lib/test/test_charmapcodec.py|  7 +--
 Lib/test/test_codecs.py  | 25 +++--
 Lib/test/test_io.py  |  7 +++
 Lib/test/test_unicode.py |  5 -
 Modules/_codecsmodule.c  | 20 
 Modules/clinic/_codecsmodule.c.h | 39 +--
 Python/codecs.c  | 25 -
 7 files changed, 16 insertions(+), 112 deletions(-)

--
nosy: +pablogsal

___
Python tracker 

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



[issue42145] test_io is leaking references

2020-10-25 Thread Pablo Galindo Salgado

Pablo Galindo Salgado  added the comment:

Commit c9f696cb96d1c362d5cad871f61da520572d9b08 introduced a reference leak in 
the test suite. See https://bugs.python.org/issue42145:

c9f696cb96d1c362d5cad871f61da520572d9b08 is the first bad commit
commit c9f696cb96d1c362d5cad871f61da520572d9b08
Author: Hai Shi 
Date:   Fri Oct 16 16:34:15 2020 +0800

bpo-41919, test_codecs: Move codecs.register calls to setUp() (GH-22513)

Reverting the commit eliminates the problem:

rences, sum=12
test_io leaked [1, 1, 1, 1] memory blocks, sum=4
test_io failed

== Tests result: FAILURE ==

1 test failed:
test_io

Total duration: 397 ms
Tests result: FAILURE
g
~/github/python/master master|bisect*
❯ git revert c9f696cb96d1c362d5cad871f61da520572d9b08
Auto-merging Lib/test/test_codecs.py
[master f3de7c00b4] Revert "bpo-41919, test_codecs: Move codecs.register calls 
to setUp() (GH-22513)"
 7 files changed, 112 insertions(+), 16 deletions(-)

~/github/python/master master|bisect* ⇡
❯ make -j -s
 CC='gcc -pthread' LDSHARED='gcc -pthread -shared' OPT='-g -Og -Wall'   
_TCLTK_INCLUDES='' _TCLTK_LIBS=''   ./python -E ./setup.py -q build

The following modules found by detect_modules() in setup.py, have been
built by the Makefile instead, as configured by the Setup files:
_abc  atexitpwd
time


~/github/python/master master|bisect* ⇡
❯ ./python -m test test_io -m 
test.test_io.CTextIOWrapperTest.test_read_one_by_one -R :
0:00:00 load avg: 2.57 Run tests sequentially
0:00:00 load avg: 2.57 [1/1] test_io
beginning 9 repetitions
123456789
.

== Tests result: SUCCESS ==

1 test OK.

Total duration: 455 ms
Tests result: SUCCESS

* Move the codecs' (un)register operation to testcases.
* Remove _codecs._forget_codec() and _PyCodec_Forget()

 Lib/test/test_charmapcodec.py|  7 +--
 Lib/test/test_codecs.py  | 25 +++--
 Lib/test/test_io.py  |  7 +++
 Lib/test/test_unicode.py |  5 -
 Modules/_codecsmodule.c  | 20 
 Modules/clinic/_codecsmodule.c.h | 39 +--
 Python/codecs.c  | 25 -
 7 files changed, 16 insertions(+), 112 deletions(-)

--

___
Python tracker 

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



[issue41919] Modify test_codecs to use the new codecs.unregister() function

2020-10-25 Thread Pablo Galindo Salgado


Change by Pablo Galindo Salgado :


--
resolution: fixed -> 
status: closed -> open

___
Python tracker 

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



[issue41919] Modify test_codecs to use the new codecs.unregister() function

2020-10-25 Thread Pablo Galindo Salgado


Change by Pablo Galindo Salgado :


--
pull_requests: +21877
stage: resolved -> patch review
pull_request: https://github.com/python/cpython/pull/22961

___
Python tracker 

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



[issue41052] Opt out serialization/deserialization for heap type

2020-10-25 Thread Serhiy Storchaka


Change by Serhiy Storchaka :


--
pull_requests: +21880
pull_request: https://github.com/python/cpython/pull/22963

___
Python tracker 

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



[issue34597] Python needs to check existence of functions at runtime for targeting older macOS platforms

2020-10-25 Thread Ronald Oussoren


Ronald Oussoren  added the comment:

The active PR in bpo-41100 will fix this issue as well.

--
dependencies: +Build failure on macOS 11 (beta)

___
Python tracker 

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



[issue42147] Micro optimization for longrange iteration if step is 1

2020-10-25 Thread Serhiy Storchaka


Serhiy Storchaka  added the comment:

Sorry, but I do not think it is worth. If there are any issues with multiplying 
by 1, it may be worth to optimize multiplication of integers in general. But 
iterating range(1 << 1000, (1 << 1000) + 100) looks a pretty artificial example.

--
nosy: +mark.dickinson, rhettinger, serhiy.storchaka

___
Python tracker 

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



[issue42148] floating point representation issues

2020-10-25 Thread Andrea Tuccia


New submission from Andrea Tuccia :

I'm noticing some floating point representation precision issues that occurs on 
all versions and platforms:

>>> 277*0.1
27.703
>>> 1.2-1.0
0.19996
>>> import numpy as np
>>> np.double(277*0.1)
27.703
>>> np.double(1.2-1.0)
0.19996
>>> np.longdouble(277*0.1)
27.702842
>>> np.longdouble(1.2-1.0)
0.19995559

Verified with python 2.7 to 3.8. On x86 (i386 and amd64) and ARM (32 and 64 
bits). It does not occur in C, LUA, Perl, ...

--
components: Interpreter Core, Library (Lib)
messages: 379589
nosy: atuccia
priority: normal
severity: normal
status: open
title: floating point representation issues
type: behavior

___
Python tracker 

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



[issue42145] test_io is leaking references

2020-10-25 Thread Dong-hee Na


Change by Dong-hee Na :


--
nosy: +shihai1991

___
Python tracker 

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



[issue42146] subprocess.Popen() leaks cwd in case of uid/gid overflow

2020-10-25 Thread Alexey Izbyshev


Change by Alexey Izbyshev :


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

___
Python tracker 

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



[issue42144] A missing "goto" in the _ssl module!

2020-10-25 Thread miss-islington


miss-islington  added the comment:


New changeset c32f2976b8f4034724c3270397aa16f38daf470f by Zackery Spytz in 
branch 'master':
bpo-42144: Add a missing "goto error;" in the _ssl module (GH-22959)
https://github.com/python/cpython/commit/c32f2976b8f4034724c3270397aa16f38daf470f


--
nosy: +miss-islington

___
Python tracker 

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



[issue42144] A missing "goto" in the _ssl module!

2020-10-25 Thread miss-islington


Change by miss-islington :


--
pull_requests: +21892
pull_request: https://github.com/python/cpython/pull/22975

___
Python tracker 

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



[issue42144] A missing "goto" in the _ssl module!

2020-10-25 Thread miss-islington


Change by miss-islington :


--
pull_requests: +21891
pull_request: https://github.com/python/cpython/pull/22974

___
Python tracker 

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



[issue42141] Speedup various dict inits

2020-10-25 Thread Marco Sulla


Marco Sulla  added the comment:

Note that this time I've no slowdown in the macro bench, since I used normal 
builds, not optimized ones. I suppose an optimized build will show slowdown 
because the new functions are not in the test battery.

--

___
Python tracker 

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



[issue4489] shutil.rmtree is vulnerable to a symlink attack

2020-10-25 Thread daniel hahler


Change by daniel hahler :


--
nosy: +blueyed
nosy_count: 18.0 -> 19.0
pull_requests: +21884
pull_request: https://github.com/python/cpython/pull/22968

___
Python tracker 

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



[issue39108] random needs doc for "gauss" versus "normalvariate"

2020-10-25 Thread Raymond Hettinger


Raymond Hettinger  added the comment:


New changeset 3cde3788b68bce7deee1e6d31e265bbfce337731 by Raymond Hettinger in 
branch 'master':
bpo-39108: Document threading issues for random.gauss() (GH-22928)
https://github.com/python/cpython/commit/3cde3788b68bce7deee1e6d31e265bbfce337731


--

___
Python tracker 

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



[issue42147] Micro optimization for longrange iteration if step is 1

2020-10-25 Thread Dong-hee Na


Dong-hee Na  added the comment:

if somebody try to sum very large value with range.
sum(range(1 << 1000, (1 << 1000) + 100))
it can be affected by this patch.

--

___
Python tracker 

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



[issue42090] zipfile.Path.joinpath API inconsistent with pathlib.Path.joinpath

2020-10-25 Thread Jason R. Coombs


Jason R. Coombs  added the comment:

This issue is fixed in zipp 3.4.0.

--
assignee:  -> jaraco
stage:  -> backport needed

___
Python tracker 

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



[issue41919] Modify test_codecs to use the new codecs.unregister() function

2020-10-25 Thread Pablo Galindo Salgado


Change by Pablo Galindo Salgado :


--
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



[issue41919] Modify test_codecs to use the new codecs.unregister() function

2020-10-25 Thread Pablo Galindo Salgado


Pablo Galindo Salgado  added the comment:


New changeset 14cdc215aa952d280c18626005d3aff967901d92 by Hai Shi in branch 
'master':
bpo-41919: Avoid resource leak in test_io (GH-22973)
https://github.com/python/cpython/commit/14cdc215aa952d280c18626005d3aff967901d92


--

___
Python tracker 

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



[issue42145] test_io is leaking references

2020-10-25 Thread Pablo Galindo Salgado


Pablo Galindo Salgado  added the comment:

Fixed by https://github.com/python/cpython/pull/22973

--
resolution:  -> fixed
stage:  -> 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



[issue42145] test_io is leaking references

2020-10-25 Thread Pablo Galindo Salgado


Pablo Galindo Salgado  added the comment:

Thanks for the quick fix, hai shi

--

___
Python tracker 

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



[issue42141] Speedup various dict inits

2020-10-25 Thread Marco Sulla


Marco Sulla  added the comment:

I'm quite sure I not invented the wheel :) but I think it's a good improvement:

| pathlib | 35.8 ms  | 35.1 ms| 1.02x 
faster | Significant (t=13.21) |
| scimark_monte_carlo | 176 ms   | 172 ms | 1.02x 
faster | Significant (t=9.48)  |
| scimark_sor | 332 ms   | 325 ms | 1.02x 
faster | Significant (t=11.96) |
| telco   | 11.0 ms  | 10.8 ms| 1.03x 
faster | Significant (t=8.52)  |
| unpickle_pure_python| 525 us   | 514 us | 1.02x 
faster | Significant (t=19.97) |
| xml_etree_process   | 132 ms   | 129 ms | 1.02x 
faster | Significant (t=17.59) |

--
components: +Interpreter Core
type:  -> performance
versions: +Python 3.10

___
Python tracker 

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



[issue38233] datetime.datetime.fromtimestamp have different behaviour on windows and mac

2020-10-25 Thread Eryk Sun


Change by Eryk Sun :


--
resolution:  -> duplicate
status: open -> closed

___
Python tracker 

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



[issue39108] random needs doc for "gauss" versus "normalvariate"

2020-10-25 Thread Raymond Hettinger


Raymond Hettinger  added the comment:


New changeset af891a962b62268d76ace0d4768ab0e1934a2cd1 by Miss Skeleton (bot) 
in branch '3.9':
bpo-39108: Document threading issues for random.gauss() (GH-22928) (GH-22972)
https://github.com/python/cpython/commit/af891a962b62268d76ace0d4768ab0e1934a2cd1


--

___
Python tracker 

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



[issue33962] IDLE: use ttk.spinbox with configdialog

2020-10-25 Thread Mark Roseman


Mark Roseman  added the comment:

Whoops, sorry... there's a "readonly" state flag that disables direct editing 
of the entry (like with combobox) and just allows manipulation of the arrows. 
I've updated the PR to set that. I've also changed it so that the contents of 
the entry part isn't selected whenever the arrows are used (agreed, it looks 
ugly). Please give it a try and let me know.

p.s. I just checked, the entry's width configuration option works. You just 
have to remove the "fill=X" when the widget is packed. FWIW, I kept the 
previous layout to keep the patch as minimal as possible, under the assumption 
that other layout changes (here, on in general) were planned.

--

___
Python tracker 

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



[issue42144] A missing "goto" in the _ssl module!

2020-10-25 Thread miss-islington


miss-islington  added the comment:


New changeset 83c86cf54b36a7325f615f5adf22b28e48f0e72d by Miss Skeleton (bot) 
in branch '3.9':
bpo-42144: Add a missing "goto error;" in the _ssl module (GH-22959)
https://github.com/python/cpython/commit/83c86cf54b36a7325f615f5adf22b28e48f0e72d


--

___
Python tracker 

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



[issue42141] Speedup various dict inits

2020-10-25 Thread Marco Sulla


Marco Sulla  added the comment:

The fact is that, IMHO, PGO will "false" the results, since it's quite 
improbable that in the test battery there's a test of creation of a dict from 
another dict with an hole. It seems to me that the comparison between the 
normal builds are more significant.

--

___
Python tracker 

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



[issue7175] Define a standard location and API for configuration files

2020-10-25 Thread Ronald Oussoren


Change by Ronald Oussoren :


--
nosy:  -ronaldoussoren

___
Python tracker 

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



[issue41052] Opt out serialization/deserialization for heap type

2020-10-25 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



[issue15872] shutil.rmtree(..., ignore_errors=True) doesn't ignore all errors

2020-10-25 Thread daniel hahler


Change by daniel hahler :


--
nosy: +blueyed
nosy_count: 11.0 -> 12.0
pull_requests: +21883
pull_request: https://github.com/python/cpython/pull/22967

___
Python tracker 

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



[issue42141] Speedup various dict inits

2020-10-25 Thread Inada Naoki


Inada Naoki  added the comment:

I run pyperformance=1.0.0 for your speedup_dictinit branch (7df3b9c) and master 
branch, with PGO+LTO build.

```
$ ./python -m pyperf compare_to master-opt.json dictinit.json -G --min-speed=1
Slower (22):
- unpack_sequence: 62.7 ns +- 0.7 ns -> 70.3 ns +- 0.5 ns: 1.12x slower (+12%)
- pickle_dict: 28.6 us +- 0.1 us -> 30.7 us +- 0.1 us: 1.07x slower (+7%)
- regex_dna: 233 ms +- 1 ms -> 245 ms +- 0 ms: 1.05x slower (+5%)
- unpickle_list: 5.22 us +- 0.22 us -> 5.46 us +- 0.10 us: 1.05x slower (+5%)
- sqlite_synth: 3.29 us +- 0.05 us -> 3.43 us +- 0.05 us: 1.04x slower (+4%)
- regex_v8: 26.1 ms +- 0.1 ms -> 27.1 ms +- 0.4 ms: 1.04x slower (+4%)
- spectral_norm: 147 ms +- 1 ms -> 153 ms +- 2 ms: 1.04x slower (+4%)
- scimark_sparse_mat_mult: 5.28 ms +- 0.03 ms -> 5.48 ms +- 0.01 ms: 1.04x 
slower (+4%)
- unpickle_pure_python: 326 us +- 4 us -> 338 us +- 3 us: 1.04x slower (+4%)
- nbody: 143 ms +- 3 ms -> 148 ms +- 2 ms: 1.03x slower (+3%)
- regex_effbot: 3.43 ms +- 0.01 ms -> 3.53 ms +- 0.02 ms: 1.03x slower (+3%)
- django_template: 52.7 ms +- 0.7 ms -> 54.1 ms +- 0.9 ms: 1.03x slower (+3%)
- scimark_fft: 405 ms +- 4 ms -> 415 ms +- 9 ms: 1.03x slower (+3%)
- fannkuch: 523 ms +- 2 ms -> 535 ms +- 2 ms: 1.02x slower (+2%)
- xml_etree_process: 80.2 ms +- 0.8 ms -> 82.0 ms +- 0.8 ms: 1.02x slower (+2%)
- json_dumps: 14.6 ms +- 0.1 ms -> 14.9 ms +- 0.1 ms: 1.02x slower (+2%)
- scimark_sor: 209 ms +- 2 ms -> 213 ms +- 2 ms: 1.02x slower (+2%)
- genshi_text: 32.1 ms +- 0.5 ms -> 32.7 ms +- 0.4 ms: 1.02x slower (+2%)
- logging_format: 10.9 us +- 0.2 us -> 11.0 us +- 0.2 us: 1.02x slower (+2%)
- pyflate: 734 ms +- 6 ms -> 745 ms +- 8 ms: 1.01x slower (+1%)
- float: 134 ms +- 1 ms -> 135 ms +- 2 ms: 1.01x slower (+1%)
- raytrace: 511 ms +- 5 ms -> 517 ms +- 5 ms: 1.01x slower (+1%)

Faster (2):
- logging_silent: 209 ns +- 5 ns -> 205 ns +- 6 ns: 1.02x faster (-2%)
- pickle_list: 5.04 us +- 0.03 us -> 4.96 us +- 0.04 us: 1.02x faster (-2%)

Benchmark hidden because not significant (36):
```

I suppose all delta are noise. But there is a possibility small performance 
down caused by fatter binary.

--

___
Python tracker 

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



[issue42146] subprocess.Popen() leaks cwd in case of uid/gid overflow

2020-10-25 Thread Alexey Izbyshev


Change by Alexey Izbyshev :


--
pull_requests: +21885
pull_request: https://github.com/python/cpython/pull/22970

___
Python tracker 

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



[issue42146] subprocess.Popen() leaks cwd in case of uid/gid overflow

2020-10-25 Thread Alexey Izbyshev


Change by Alexey Izbyshev :


--
type: behavior -> resource usage

___
Python tracker 

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



[issue41919] Modify test_codecs to use the new codecs.unregister() function

2020-10-25 Thread hai shi


hai shi  added the comment:

> AS this is masking other issues in the build bots, we need to revert the 
> commit unless is fixed in 24 hours per the buildbot workflow

Thanks, Pablo. I checked that only test_io.py have resource leak.
I create PR-22973, pls take a look if you have free time, thanks.

--

___
Python tracker 

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



[issue41919] Modify test_codecs to use the new codecs.unregister() function

2020-10-25 Thread hai shi


Change by hai shi :


--
pull_requests: +21888
pull_request: https://github.com/python/cpython/pull/22973

___
Python tracker 

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



[issue39108] random needs doc for "gauss" versus "normalvariate"

2020-10-25 Thread Raymond Hettinger


Change by Raymond Hettinger :


--
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



[issue42130] AsyncIO's wait_for can hide cancellation in a rare race condition

2020-10-25 Thread Taras Voinarovskyi


Taras Voinarovskyi  added the comment:

Hi Chris,
Yes, I do believe that is the respectful change, if we look the CancelledError 
is not checked to be external or originate from the timer. 
Best regards, 
Taras Voinarovskyi

--

___
Python tracker 

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



[issue42146] subprocess.Popen() leaks cwd in case of uid/gid overflow

2020-10-25 Thread Alexey Izbyshev


Change by Alexey Izbyshev :


--
keywords: +patch
stage:  -> patch review

___
Python tracker 

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



[issue42147] Micro optimization for longrange iteration if step is 1

2020-10-25 Thread Dong-hee Na


Change by Dong-hee Na :


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

___
Python tracker 

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



[issue39108] random needs doc for "gauss" versus "normalvariate"

2020-10-25 Thread miss-islington


Change by miss-islington :


--
nosy: +miss-islington
nosy_count: 4.0 -> 5.0
pull_requests: +21887
pull_request: https://github.com/python/cpython/pull/22972

___
Python tracker 

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



[issue37776] [subinterpreters] Test Py_Finalize() from a subinterpreter

2020-10-25 Thread Lewis Gaul


Change by Lewis Gaul :


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

___
Python tracker 

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



[issue41052] Opt out serialization/deserialization for heap type

2020-10-25 Thread Serhiy Storchaka


Serhiy Storchaka  added the comment:


New changeset 0aaecb30483e98fc29c1f4253967d05da092f0c5 by Serhiy Storchaka in 
branch '3.9':
[3.9] bpo-41052: Fix pickling heap types implemented in C with protocols 0 and 
1 (GH-22870). (GH-22963)
https://github.com/python/cpython/commit/0aaecb30483e98fc29c1f4253967d05da092f0c5


--

___
Python tracker 

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



[issue38865] [subinterpreters] Can Py_Finalize() be called if the current interpreter is not the main interpreter?

2020-10-25 Thread Lewis Gaul


Change by Lewis Gaul :


--
pull_requests: +21889
pull_request: https://github.com/python/cpython/pull/17575

___
Python tracker 

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



[issue42147] Micro optimization for longrange iteration if step is 1

2020-10-25 Thread Dong-hee Na


Dong-hee Na  added the comment:

s/
I approach as same case that step=1 is quite a lot usecase until user designate 
step value.
/My assumtion is that step=1 is quite often usecase until user designate step 
value.

--

___
Python tracker 

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



[issue42145] test_io is leaking references

2020-10-25 Thread hai shi


hai shi  added the comment:

I created a possible fix PR: PR-22973

--

___
Python tracker 

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



[issue42148] floating point representation issues

2020-10-25 Thread Eric V. Smith


Eric V. Smith  added the comment:

This isn't a bug. It's due to the base 2 representation of floating point 
numbers. See for example: See 
https://docs.python.org/3/tutorial/floatingpoint.html

It's possible, depending on your use case, you might want to use the decimal 
module. But that has it's own issues that you should be aware of. For example, 
1/7 is not exactly representable in either floats or Decimals.

--
nosy: +eric.smith
resolution:  -> not a bug
stage:  -> 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



[issue42144] A missing "goto" in the _ssl module!

2020-10-25 Thread miss-islington


miss-islington  added the comment:


New changeset 8e980ecfb7b42063ed41d665288aff69f0ed7fdc by Miss Skeleton (bot) 
in branch '3.8':
bpo-42144: Add a missing "goto error;" in the _ssl module (GH-22959)
https://github.com/python/cpython/commit/8e980ecfb7b42063ed41d665288aff69f0ed7fdc


--

___
Python tracker 

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



[issue41490] Update bundled pip to 20.2.1 and setuptools to 49.2.1

2020-10-25 Thread Jason R. Coombs


Jason R. Coombs  added the comment:


New changeset df8d4c83a6e1727e766191896aeabde886979587 by Jason R. Coombs in 
branch 'master':
bpo-41490: ``path`` and ``contents`` to aggressively close handles (#22915)
https://github.com/python/cpython/commit/df8d4c83a6e1727e766191896aeabde886979587


--

___
Python tracker 

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



[issue42146] subprocess.Popen() leaks cwd in case of uid/gid overflow

2020-10-25 Thread Alexey Izbyshev


New submission from Alexey Izbyshev :

The following test demonstrates the leak:

```
import subprocess

cwd = 'x' * 10**6
for __ in range(100):
try:
subprocess.call(['/xxx'], cwd=cwd, user=2**64)
except OverflowError:
pass

from resource import *
print(getrusage(RUSAGE_SELF).ru_maxrss)
```

The leak was introduced by bpo-36046. Previously, `cleanup:` label was not 
reachable after `cwd_obj2` was initialized at 
https://github.com/python/cpython/blob/492d513ccbebeec40a8ba85cbd894a027ca5b2b3/Modules/_posixsubprocess.c#L892

I'll submit a PR with a simple fix suitable for backporting to 3.9.

Also, I think it might make sense to unify the two almost-identical cleanup 
paths we have now. I'll follow up with another PR.

--
assignee: izbyshev
components: Extension Modules
keywords: 3.9regression
messages: 379575
nosy: gregory.p.smith, izbyshev, patrick.mclean
priority: normal
severity: normal
status: open
title: subprocess.Popen() leaks cwd in case of uid/gid overflow
type: behavior
versions: Python 3.10, Python 3.9

___
Python tracker 

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



[issue42146] subprocess.Popen() leaks cwd in case of uid/gid overflow

2020-10-25 Thread Alexey Izbyshev


Alexey Izbyshev  added the comment:

I've submitted both PRs.

Regarding PR 22970:

* I made it a draft since we'd probably want to fix the leak first, but then it 
will have to be rebased. 

* It fixes a bug with _enable_gc(): if it failed after fork(), we'd raise 
OSError instead. Additionally, if fork() succeeded(), the errno inside OSError 
would be zero, and we'd leak the child process.

--
keywords:  -patch
stage: patch review -> 

___
Python tracker 

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



[issue42147] Micro optimization for longrange iteration if step is 1

2020-10-25 Thread Dong-hee Na


New submission from Dong-hee Na :

This is a similar case with https://bugs.python.org/issue41902
A quite possible usecase when the user use range with big number

./python -m pyperf compare_to longrange_master.json longrange_opt.json
Mean +- std dev: [longrange_master] 6.45 us +- 0.09 us -> [longrange_opt] 5.72 
us +- 0.07 us: 1.13x faster (-11%)

--
assignee: corona10
components: Interpreter Core
files: bench_longrange.py
messages: 379578
nosy: corona10, methane, vstinner
priority: normal
severity: normal
status: open
title: Micro optimization for longrange iteration if step is 1
type: performance
versions: Python 3.10
Added file: https://bugs.python.org/file49539/bench_longrange.py

___
Python tracker 

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



[issue24427] subclass of multiprocessing Connection segfault upon attribute acces

2020-10-25 Thread Irit Katriel


Change by Irit Katriel :


--
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



[issue42147] Micro optimization for longrange iteration if step is 1

2020-10-25 Thread Dong-hee Na


Dong-hee Na  added the comment:

At bpo-41092, we decide not to optimize mulitply operation itself.

I approach as same case that step=1 is quite a lot usecase until user designate 
step value.

If range with longobject is not that much use case, I can agree with your 
opinion

--

___
Python tracker 

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



[issue32122] Improve -x option documentation

2020-10-25 Thread Inada Naoki


Change by Inada Naoki :


--
keywords: +newcomer friendly
versions: +Python 3.10 -Python 2.7, Python 3.6, Python 3.7

___
Python tracker 

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



[issue30681] email.utils.parsedate_to_datetime() should return None when date cannot be parsed

2020-10-25 Thread Ned Deily


Change by Ned Deily :


--
nosy:  -ned.deily
versions:  -Python 3.7

___
Python tracker 

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



[issue41662] Bugs in binding parameters in sqlite3

2020-10-25 Thread Inada Naoki


Inada Naoki  added the comment:


New changeset a053a7ecfef006b834a9957468fa461dafb332db by Miss Skeleton (bot) 
in branch '3.8':
bpo-41662: Fix bugs in binding parameters in sqlite3 (GH-21998)
https://github.com/python/cpython/commit/a053a7ecfef006b834a9957468fa461dafb332db


--
nosy: +methane

___
Python tracker 

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



[issue41100] Build failure on macOS 11 (beta)

2020-10-25 Thread Ronald Oussoren


Change by Ronald Oussoren :


--
pull_requests: +21899
pull_request: https://github.com/python/cpython/pull/21115

___
Python tracker 

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



[issue30181] Correct the parsing of a test case docstring.

2020-10-25 Thread Chris Jerdonek


Chris Jerdonek  added the comment:

I'm closing this as a duplicate of issue 39450, which has been resolved.

--
resolution:  -> duplicate
stage:  -> resolved
status: open -> closed
superseder:  -> unittest TestCase shortDescription does not strip whitespace

___
Python tracker 

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



[issue42140] asyncio.wait function creates futures set two times

2020-10-25 Thread Chris Jerdonek


Chris Jerdonek  added the comment:

Are you suggesting this is a bug, or is it just a suggested code cleanup? I ask 
because the docs suggest that a set should be passed:
https://docs.python.org/3/library/asyncio-task.html#asyncio.wait

And the docstring says it should be a sequence:
https://github.com/python/cpython/blob/d1a0a960ee493262fb95a0f5b795b5b6d75cecb8/Lib/asyncio/tasks.py#L373-L376

So while code cleanup is okay, I'm not sure support for general iterator 
arguments can / should be guaranteed.

--
nosy: +chris.jerdonek

___
Python tracker 

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



[issue12832] The documentation for the print function should explain/point to how to control the sys.stdout encoding

2020-10-25 Thread Irit Katriel


Change by Irit Katriel :


--
type:  -> enhancement
versions: +Python 3.10, Python 3.9 -Python 2.7, Python 3.2, Python 3.3

___
Python tracker 

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



[issue42148] floating point representation issues

2020-10-25 Thread Eric V. Smith


Eric V. Smith  added the comment:

Thanks for double-checking the other languages, Steven.

--

___
Python tracker 

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



[issue42147] Micro optimization for longrange iteration if step is 1

2020-10-25 Thread Pablo Galindo Salgado


Pablo Galindo Salgado  added the comment:

My particular opinion is that I would advise against having more branching, 
especially for code that is rare: it augments the possibilities of branch 
mispredictions, the changes of untested code paths, and the possibilities of 
unknown interactions. In this case, I agree that the code is simple enough, but 
I still feel that the cost may not be worth the extra maintenance needs of 
those branches.

--

___
Python tracker 

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



[issue42151] Pure Python xml.etree.ElementTree is missing default attribute values

2020-10-25 Thread Karthikeyan Singaravelan


Change by Karthikeyan Singaravelan :


--
nosy: +eli.bendersky, scoder, serhiy.storchaka

___
Python tracker 

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



[issue42140] asyncio.wait function creates futures set two times

2020-10-25 Thread Denis S. Otkidach


Denis S. Otkidach  added the comment:

The current error message is way too cryptic anyway.  And restricting it to the 
set type only, as in docs, will certainly break a lot of code (passing a list 
is quite common).

--

___
Python tracker 

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



[issue33557] Windows multiprocessing doesn't propagate tabcheck to children

2020-10-25 Thread Inada Naoki


Inada Naoki  added the comment:

Python 2.7 became EOL.

--
nosy: +methane
resolution:  -> out of date
stage:  -> 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



[issue42151] Pure Python xml.etree.ElementTree is missing default attribute values

2020-10-25 Thread Felix C. Stegerman


New submission from Felix C. Stegerman :

I originally reported this as a bug in PyPy, but it turns out that CPython's C 
implementation (_elementtree) behaves differently than the pure Python version 
(b/c it sets specified_attributes = 1).

PyPy issue with example code: https://foss.heptapod.net/pypy/pypy/-/issues/

--
components: Library (Lib)
messages: 379637
nosy: obfusk
priority: normal
severity: normal
status: open
title: Pure Python xml.etree.ElementTree is missing default attribute values
type: behavior
versions: Python 3.10, Python 3.6, 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



[issue42151] Pure Python xml.etree.ElementTree is missing default attribute values

2020-10-25 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



[issue39871] math.copysign raises SystemError with non-float x and custom y

2020-10-25 Thread Inada Naoki


Inada Naoki  added the comment:


New changeset f6255a2ccb55a63194caf698f471c803c08be359 by Zackery Spytz in 
branch '3.8':
bpo-39871: Fix an error in a news entry (GH-21749)
https://github.com/python/cpython/commit/f6255a2ccb55a63194caf698f471c803c08be359


--

___
Python tracker 

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



[issue42043] zipfile.Path should support inheritance

2020-10-25 Thread Jason R. Coombs


Jason R. Coombs  added the comment:


New changeset d1a0a960ee493262fb95a0f5b795b5b6d75cecb8 by Jason R. Coombs in 
branch 'master':
bpo-42043: Add support for zipfile.Path subclasses (#22716)
https://github.com/python/cpython/commit/d1a0a960ee493262fb95a0f5b795b5b6d75cecb8


--

___
Python tracker 

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



[issue42147] Micro optimization for longrange iteration if step is 1

2020-10-25 Thread Pablo Galindo Salgado


Pablo Galindo Salgado  added the comment:

I concur with Serhiy

--
nosy: +pablogsal

___
Python tracker 

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



[issue2679] email.feedparser regex duplicate

2020-10-25 Thread Irit Katriel


Change by Irit Katriel :


--
type: behavior -> 
versions: +Python 3.10, Python 3.8, Python 3.9 -Python 2.6, Python 2.7, Python 
3.1, Python 3.2, Python 3.3

___
Python tracker 

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



[issue42150] Buffer overflow in bad_single_statement (Parser/pegen.c)

2020-10-25 Thread miss-islington


miss-islington  added the comment:


New changeset 0b290dd2171e745d94f48298cafb2327eb2de17c by Miss Skeleton (bot) 
in branch '3.9':
bpo-42150: Avoid buffer overflow in the new parser (GH-22978)
https://github.com/python/cpython/commit/0b290dd2171e745d94f48298cafb2327eb2de17c


--

___
Python tracker 

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



[issue12930] reindent.py inserts spaces in multiline literals

2020-10-25 Thread Dima Tisnek


Dima Tisnek  added the comment:

Given the trajectory of this bug, would it be easier to remove `reindent.py` 
from cpython code base entirely?

--

___
Python tracker 

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



[issue42147] Micro optimization for longrange iteration if step is 1

2020-10-25 Thread Dong-hee Na


Dong-hee Na  added the comment:

@pablogsal, @serhiy.storchaka

> I would advise against having more branching, especially for code that is 
> rare:

About bpo-41902, I believe those patches affect all range objects which is 
created with step is one .

I believe the usage of creation of range object with range(start), range(start, 
stop) is more than range(start, stop, step) unless there is significant proof 
that users prefer to create with range(start, stop, step)

So I think that those patches are worth to do it.

but PR 22971 is only affecting to longrange iteration.
it means if there no worth to optimize range(start), range(start, stop) when 
the start and stop is big number, this issue could be rejected.

And if the patch is rejected, I would like to suggest write a comment on the 
codeline for the future contributors why we decided to not optimizing this.

--

___
Python tracker 

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



[issue42147] Micro optimization for longrange iteration if step is 1

2020-10-25 Thread Inada Naoki


Inada Naoki  added the comment:

> On the other hand, GH-22479 is affect to all index API() whether the number 
> is large or small.

Then, no need to revert GH-22479 for consistency. Thanks.

> p.s by the way, Naoki is the last name or first name? ;)

It is difficult to say what is first name. Inada is surname and Naoki is given 
name. Surname comes first in Japanese.

Traditionally, we used reversed name order when write name in English to follow 
English-world manner. But China and Korea don't reverse name. And Japan is 
stopping reversed name order too. Japanese junior high schools teach 
surname-given name since about 2000.

--

___
Python tracker 

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



[issue42090] zipfile.Path.joinpath API inconsistent with pathlib.Path.joinpath

2020-10-25 Thread Jason R. Coombs


Change by Jason R. Coombs :


--
keywords: +patch
pull_requests: +21893
stage: backport needed -> patch review
pull_request: https://github.com/python/cpython/pull/22976

___
Python tracker 

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



[issue42149] Python 'make test' failed inside ssh+tmux

2020-10-25 Thread Kostiantyn Mashukov


Kostiantyn Mashukov  added the comment:

Does it mean that running python script inside ssh+tmux session could fail if 
it uses functionality that fails those tests?

--

___
Python tracker 

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



[issue42150] Buffer overflow in bad_single_statement (Parser/pegen.c)

2020-10-25 Thread Pablo Galindo Salgado


New submission from Pablo Galindo Salgado :

Building Python with the address sanitizer and executing ./python -m test 
test_repl -v shows this:

===
==26216==ERROR: AddressSanitizer: heap-buffer-overflow on address 
0x6023990f at pc 0x5625406527b2 bp 0x7ffe8d621910 sp 0x7ffe8d621900
READ of size 1 at 0x6023990f thread T0
#0 0x5625406527b1 in bad_single_statement Parser/pegen.c:993
#1 0x5625406527b1 in _PyPegen_run_parser Parser/pegen.c:1136
#2 0x5625406529b8 in _PyPegen_run_parser_from_file_pointer 
Parser/pegen.c:1179
#3 0x5625403f1945 in PyRun_InteractiveOneObjectEx Python/pythonrun.c:208
#4 0x5625403f3cd9 in PyRun_InteractiveLoopFlags Python/pythonrun.c:115
#5 0x5625403f4e3f in PyRun_AnyFileExFlags Python/pythonrun.c:74
#6 0x562540181792 in pymain_run_stdin Modules/main.c:512
#7 0x562540181792 in pymain_run_python Modules/main.c:601
#8 0x562540182904 in Py_RunMain Modules/main.c:677
#9 0x562540182904 in pymain_main Modules/main.c:707
#10 0x562540182904 in Py_BytesMain Modules/main.c:731
#11 0x7f25297aa151 in __libc_start_main (/usr/lib/libc.so.6+0x28151)
#12 0x56254017f0bd in _start 
(/home/pablogsal/github/python/master/python+0x1640bd)

0x6023990f is located 1 bytes to the left of 2-byte region 
[0x60239910,0x60239912)
allocated by thread T0 here:
#0 0x7f2529b70459 in __interceptor_malloc 
/build/gcc/src/gcc/libsanitizer/asan/asan_malloc_linux.cpp:145
#1 0x562540553416 in tok_nextc Parser/tokenizer.c:872
#2 0x562540554eb7 in tok_get Parser/tokenizer.c:1190
#3 0x562540559590 in PyTokenizer_Get Parser/tokenizer.c:1839
#4 0x56254064f6dd in _PyPegen_fill_token Parser/pegen.c:584
#5 0x5625406934a7 in statement_newline_rule Parser/parser.c:1296
#6 0x5625406934a7 in interactive_rule Parser/parser.c:769
#7 0x5625406934a7 in _PyPegen_parse Parser/parser.c:24823
#8 0x562540652382 in _PyPegen_run_parser Parser/pegen.c:
#9 0x5625406529b8 in _PyPegen_run_parser_from_file_pointer 
Parser/pegen.c:1179
#10 0x5625403f1945 in PyRun_InteractiveOneObjectEx Python/pythonrun.c:208
#11 0x5625403f3cd9 in PyRun_InteractiveLoopFlags Python/pythonrun.c:115
#12 0x5625403f4e3f in PyRun_AnyFileExFlags Python/pythonrun.c:74
#13 0x562540181792 in pymain_run_stdin Modules/main.c:512
#14 0x562540181792 in pymain_run_python Modules/main.c:601
#15 0x562540182904 in Py_RunMain Modules/main.c:677
#16 0x562540182904 in pymain_main Modules/main.c:707
#17 0x562540182904 in Py_BytesMain Modules/main.c:731
#18 0x7f25297aa151 in __libc_start_main (/usr/lib/libc.so.6+0x28151)

SUMMARY: AddressSanitizer: heap-buffer-overflow Parser/pegen.c:993 in 
bad_single_statement
Shadow bytes around the buggy address:
  0x0c0472d0: fa fa 00 04 fa fa 00 01 fa fa 00 04 fa fa 00 04
  0x0c0472e0: fa fa 00 04 fa fa 00 04 fa fa 00 04 fa fa 00 04
  0x0c0472f0: fa fa 00 04 fa fa 00 04 fa fa 00 04 fa fa 00 07
  0x0c047300: fa fa 00 04 fa fa 00 04 fa fa 06 fa fa fa 00 fa
  0x0c047310: fa fa fd fa fa fa fd fa fa fa fd fa fa fa fd fa
=>0x0c047320: fa[fa]02 fa fa fa fd fa fa fa fd fa fa fa fd fa
  0x0c047330: fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa
  0x0c047340: fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa
  0x0c047350: fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa
  0x0c047360: fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa
  0x0c047370: fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa
Shadow byte legend (one shadow byte represents 8 application bytes):
  Addressable:   00
  Partially addressable: 01 02 03 04 05 06 07
  Heap left redzone:   fa
  Freed heap region:   fd
  Stack left redzone:  f1
  Stack mid redzone:   f2
  Stack right redzone: f3
  Stack after return:  f5
  Stack use after scope:   f8
  Global redzone:  f9
  Global init order:   f6
  Poisoned by user:f7
  Container overflow:  fc
  Array cookie:ac
  Intra object redzone:bb
  ASan internal:   fe
  Left alloca redzone: ca
  Right alloca redzone:cb
  Shadow gap:  cc
==26216==ABORTING

--
components: Interpreter Core
messages: 379607
nosy: lys.nikolaou, pablogsal
priority: normal
severity: normal
status: open
title: Buffer overflow in bad_single_statement (Parser/pegen.c)
versions: Python 3.10

___
Python tracker 

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



[issue36207] robotsparser deny all with some rules

2020-10-25 Thread Nicolas


Nicolas  added the comment:

Seems like we have the same issue with http://meridigital.com/robots.txt

--
nosy: +nico702 -matthieuhemea

___
Python tracker 

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



[issue4246] doc: execution model - clear and complete example in documentation

2020-10-25 Thread Irit Katriel


Change by Irit Katriel :


--
title: execution model - clear and complete example in documentation -> doc: 
execution model - clear and complete example in documentation
versions: +Python 3.10, Python 3.9 -Python 2.7, Python 3.2, Python 3.3

___
Python tracker 

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



[issue1490929] urllib.retrieve's reporthook called with non-helpful value

2020-10-25 Thread Irit Katriel


Irit Katriel  added the comment:

The code in urllib is different now but I see that a test very similar to the 
one in the patch exists, so was this fixed?

https://github.com/python/cpython/blob/e68c67805e6a4c4ec80bea64be0e8373cc02d322/Lib/test/test_urllib.py#L813

--
nosy: +iritkatriel
status: open -> pending

___
Python tracker 

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



[issue42148] floating point representation issues

2020-10-25 Thread Steven D'Aprano


Steven D'Aprano  added the comment:

Eric I would normally agree with you but the only thing which gives me pause is 
the statement that this doesn't occur with C, Lua and Perl.

That alone doesn't mean much. Different interpreters can use different 
algorithms for printing floats, Python changed its algorithm in 3.1 and 
backported it to 2.7:

https://docs.python.org/3.1/whatsnew/3.1.html#other-language-changes

and now uses Gay's algorithm which will often give different, shorter, results 
than other algorithms. Other languages do other things, for example R is 
notorious for just terminating the float output after a few decimal places, so 
you have numbers which look identical but are unequal.

Andrea, do you still think this is a bug? Can you demonstrate some code in 
another language that shows the output you expect? (Preferably an interpreter 
rather than C.)

Most importantly, can you demonstrate that the other language's output is 
correct and Python's is wrong? In particular, are you sure that the output in 
those other languages is not just rounding the result to a certain number of 
decimal places?

If you can satisfy those, please re-open the ticket, otherwise I expect that 
Eric is correct.

--
nosy: +steven.daprano

___
Python tracker 

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



[issue41916] cxx pthread check is not overrideable

2020-10-25 Thread Dustin Spicuzza


Dustin Spicuzza  added the comment:

FWIW, I've been using the patch in my PR and it seems to work.

--

___
Python tracker 

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



[issue42144] A missing "goto" in the _ssl module!

2020-10-25 Thread Christian Heimes


Christian Heimes  added the comment:

Thanks, excellent finding.

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

___
Python tracker 

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



[issue12737] str.title() is overzealous by upcasing combining marks inappropriately

2020-10-25 Thread Irit Katriel

Irit Katriel  added the comment:

Of the examples given two seem ok now, but the Istanbul one is still wrong:

>>> "déme un café".title()
'Déme Un Café'
>>> "ᾲ στο διάολο".title()
'Ὰͅ Στο Διάολο'
>>>

>>> "i̇stanbul".title()
'İStanbul'

--
nosy: +iritkatriel
versions: +Python 3.10, Python 3.9 -Python 3.2, Python 3.3

___
Python tracker 

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



[issue42147] Micro optimization for longrange iteration if step is 1

2020-10-25 Thread Inada Naoki


Inada Naoki  added the comment:

I had not noticed that there are rangeobject and longrangeobject. It doesn't 
affect to range(1) definitely.

--

___
Python tracker 

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



[issue42147] Micro optimization for longrange iteration if step is 1

2020-10-25 Thread Dong-hee Na


Dong-hee Na  added the comment:

@methane

To be more precise, [[] for _ in range(1)] will not effort this patch 
because range(1) does not create longrangeiter object.
This patch will affect to if the number is veeery large.

On the other hand, GH-22479 is affect to all index API() whether the number is 
large or small.

p.s by the way, Naoki is the last name or first name? ;)

--

___
Python tracker 

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



[issue42147] Micro optimization for longrange iteration if step is 1

2020-10-25 Thread Dong-hee Na


Dong-hee Na  added the comment:

s / will not effort / will not be affected

--

___
Python tracker 

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



[issue42149] Python 'make test' failed inside ssh+tmux

2020-10-25 Thread Kostiantyn Mashukov


New submission from Kostiantyn Mashukov :

Short version:
When building python from source code on linux (Debian10 amd64) inside ssh+tmux 
session 'make test' ends up with some tests failed.
  
Long version:
Build environment - freshly installed Debian10-amd64 os. Added build dependency 
packages: libreadline-dev libbz2-dev libffi-dev liblzma-dev libssl-dev 
libsqlite3-dev libgdbm-dev libncursesw5-dev tk-dev libgdbm-compat-dev

If you ssh to this machine, start tmux and initiate build like this:
./configure && make && make test
the whole testing phase will fail due to some failed tests.

7 tests failed: 

  
   test_generators test_multiprocessing_fork

 
   test_multiprocessing_forkserver test_multiprocessing_spawn   


   test_pdb test_regrtest test_threading

 


  
14 tests skipped:   

  
   test_devpoll test_gdb test_ioctl test_kqueue test_msilib 

  
   test_ossaudiodev test_startfile test_tix test_tk test_ttk_guionly

 
test_winconsoleio test_winreg test_winsound test_zipfile64  

  


  
7 re-run tests: 

  
test_generators test_multiprocessing_fork   

  
test_multiprocessing_forkserver test_multiprocessing_spawn  

  
test_pdb test_regrtest test_threading   

  


  
Total duration: 10 min 34 sec   

  
Tests result: FAILURE then FAILURE
-
Running the same build process on the same machine ends up fine, if running: 
locally inside xterm, locally inside xterm+tmux, remotely inside ssh only 
(without tmux).

--
components: Build
messages: 379603
nosy: kmash
priority: normal
severity: normal
status: open
title: Python 'make test' failed inside ssh+tmux
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



[issue27495] Pretty printing sorting for set and frozenset instances

2020-10-25 Thread Ben Bonenfant


Change by Ben Bonenfant :


--
nosy: +bbonenfant
nosy_count: 6.0 -> 7.0
pull_requests: +21894
pull_request: https://github.com/python/cpython/pull/22977

___
Python tracker 

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



[issue42150] Buffer overflow in bad_single_statement (Parser/pegen.c)

2020-10-25 Thread Pablo Galindo Salgado


Change by Pablo Galindo Salgado :


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

___
Python tracker 

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



  1   2   >