[issue41626] port shebang of tools from python2 to python3

2020-10-22 Thread Terry J. Reedy

Terry J. Reedy  added the comment:

Thoughts I wrote on the PR that belong here.  (Thanks for the reminder,  Éric.):
*The use of #! in both stdlib and tools seems rather inconsistent.

* Stdlib modules are best run with  -m mod so as to run the code with 
the exact python binary they are meant for. So maybe the marker should be be 
removed at least from /Lib/*.  But...

-- I was not really aware of idlelib.pyshell.  Running with an explicit  binary 
seems particularly important for IDLE.  About once a month on SO, some beginner 
posts about not being able to import a module they downloaded when running IDLE 
(maybe only sometimes).  Nearly always, they have 2 pythons, such as from 
Anaconda and python.org.

I may want or need to deprecate using pyshell as entry instead of 
idle.py/idlew.py/idle.bat as I want to move startup code from pyshell to either 
idle.py or a separate startup only file.  I am not sure how to get from here to 
there, partly because I don't really know what 'here' is in practice. 

* With 2.7 put to bed, the line is hardly needed to select between latest 2.x 
and latest 3.x.

* The response of py.exe to shebang lines needs to be detailed and considered.  
I believe it only knows about python.org installs, so it will only start the 
latest python.org install.  I don't know what it does if 32- and 64- bit 
versions are both present.  I also don't know what it runs if the 'default' 
installed version is not the latest installed version.  Does py.exe know what 
the default is, or does that just affect what 'python' runs?

--
nosy: +terry.reedy

___
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-10-22 Thread Christian Heimes


Christian Heimes  added the comment:

The commit

bpo-1635741: Port multiprocessing ext to multiphase init (GH-21378)

https://github.com/python/cpython/commit/1d541c25c8019f7a0b80b3e1b437abe171e40b65


introduced a NULL pointer deref:

if (py_sem_value_max == NULL) {
Py_DECREF(py_sem_value_max);
return -1;
}

--
nosy: +christian.heimes

___
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-10-22 Thread Christian Heimes


Change by Christian Heimes :


--
pull_requests: +21821
pull_request: https://github.com/python/cpython/pull/22880

___
Python tracker 

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



[issue42096] zipfile.is_zipfile incorrectly identifying a gzipped file as a zip archive

2020-10-22 Thread Alex Roussel


Alex Roussel  added the comment:

Hi Irit, 

Thank you for the response, I'm afraid I'm not allowed to upload the file 
myself, however the file in question is 
'2020-10-18-1602979256-http_get_7549.json.gz', which is available at this link 
https://opendata.rapid7.com/sonar.http/?page=1. It becomes free to download one 
month after release so I'll make sure to come back on the 18th Nov and upload 
it once it is made freely available.

In the meantime, I've tested on python 3.8.5 and 3.9 and I get the same issue.

--

___
Python tracker 

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



[issue42103] [security] DoS (MemError via CPU and RAM exhaustion) when processing malformed Apple Property List files in binary format

2020-10-22 Thread Serhiy Storchaka


Change by Serhiy Storchaka :


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

___
Python tracker 

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



[issue42115] Caching infrastructure for the evaluation loop: specialised opcodes

2020-10-22 Thread Inada Naoki


Inada Naoki  added the comment:

FWIW, php7 is about 5x faster than Python on spectral norm benchmark.
https://benchmarksgame-team.pages.debian.net/benchmarksgame/fastest/php-python3.html

There two major reasons:

* PHP uses scalar type for float and int
* PHP uses type-specialized bytecode (PHP8 will use JIT, but PHP7 dosn't)

Source code is here:
php: 
https://benchmarksgame-team.pages.debian.net/benchmarksgame/program/spectralnorm-php-1.html
Python: 
https://benchmarksgame-team.pages.debian.net/benchmarksgame/program/spectralnorm-python3-8.html

The most hot function is eval_A()

```
def eval_A(i, j): # i and j are int.
ij = i + j
return ij * (ij + 1) // 2 + i + 1
```

And its bytecode:

```
Disassembly of :
  2   0 LOAD_FAST0 (i)
  2 LOAD_FAST1 (j)
  4 BINARY_ADD
  6 STORE_FAST   2 (ij)

  3   8 LOAD_FAST2 (ij)
 10 LOAD_FAST2 (ij)
 12 LOAD_CONST   1 (1)
 14 BINARY_ADD
 16 BINARY_MULTIPLY
 18 LOAD_CONST   2 (2)
 20 BINARY_FLOOR_DIVIDE
 22 LOAD_FAST0 (i)
 24 BINARY_ADD
 26 LOAD_CONST   1 (1)
 28 BINARY_ADD
 30 RETURN_VALUE
```

My thoughts:

* bytecode specialized for `int op int` will some help.
* there are many incref/decref overhead.
  * multi operand bytecode (e.g. BINARY_ADD_FAST_FAST, BINARY_ADD_FAST_CONST, 
etc) will reduce refcount overhead.

--

___
Python tracker 

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



[issue42103] [security] DoS (MemError via CPU and RAM exhaustion) when processing malformed Apple Property List files in binary format

2020-10-22 Thread Ronald Oussoren


Ronald Oussoren  added the comment:

Serhiy, thanks. Just the change in the format string would fix this particular 
example.

I see you're working on a PR with better validation. The current state of the 
draft looks good to me, but I haven't checked yet if there are other potential 
problems that can be added to the list of invalid binary plists.

--

___
Python tracker 

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



[issue42115] Caching infrastructure for the evaluation loop: specialised opcodes

2020-10-22 Thread Inada Naoki


Inada Naoki  added the comment:

One more idea: BINARY_ADD_INT. Operand is int immediate.
This idea can be implemented without opcode cache. I will try it.

--

___
Python tracker 

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



[issue42103] [security] DoS (MemError via CPU and RAM exhaustion) when processing malformed Apple Property List files in binary format

2020-10-22 Thread Serhiy Storchaka


Serhiy Storchaka  added the comment:

PR 22882 fixes problem in _read_ints(), adds validation for string size, and 
adds many tests for mailformed binary Plists.

There may be problems with recursive collections. I'll try to solve them too.

--

___
Python tracker 

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



[issue42103] [security] DoS (MemError via CPU and RAM exhaustion) when processing malformed Apple Property List files in binary format

2020-10-22 Thread Serhiy Storchaka


Serhiy Storchaka  added the comment:

No, with recursive collections all is good.

Then I'll just add a NEWS entry and maybe few more tests.

--

___
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-10-22 Thread miss-islington


miss-islington  added the comment:


New changeset dde91b1953c0f0d51c4dde056727ff84b7655190 by Christian Heimes in 
branch 'master':
bpo-1635741: Fix NULL ptr deref in multiprocessing (GH-22880)
https://github.com/python/cpython/commit/dde91b1953c0f0d51c4dde056727ff84b7655190


--

___
Python tracker 

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



[issue42115] Caching infrastructure for the evaluation loop: specialised opcodes

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



[issue24165] Free list for single-digits ints

2020-10-22 Thread Inada Naoki


Change by Inada Naoki :


--
pull_requests: +21823
pull_request: https://github.com/python/cpython/pull/22884

___
Python tracker 

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



[issue24165] Free list for single-digits ints

2020-10-22 Thread Inada Naoki


Inada Naoki  added the comment:

I updated the patch.
I can not run pyperformance for now, because:

  AssertionError: would build wheel with unsupported tag ('cp310', 'cp310', 
'linux_x86_64'

I added this config, but it can not solve the problem:

```
$ cat ~/.config/pip/pip.conf
[global]
no-cache-dir = true
```

--

___
Python tracker 

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



[issue42116] Inspect library ignore comments at the end of a function (inspect.getsource)

2020-10-22 Thread Gold Games


New submission from Gold Games :

inspect.getsource ignore comments at the end of the function:

for example this function:

def matmul_single(A, x, out):
  from numpy import matmul
  out[:] = matmul(A, x)
  # Some comment here...

using the inspect library:
>>> inspect.getsource(matmul_single)
>>> 
>>>  
>>> "def omp_matmul_single(A, x, out):\n  from numpy import matmul\n out[:] = 
>>> matmul(A, x)\n"

the result does not contain the comments at the end of the function.

--
components: Library (Lib)
messages: 379289
nosy: noureddine.hamid
priority: normal
severity: normal
status: open
title: Inspect library ignore comments at the end of a function 
(inspect.getsource)
versions: Python 3.8

___
Python tracker 

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



[issue42116] Inspect library ignore comments at the end of a function (inspect.getsource)

2020-10-22 Thread Gold Games


Change by Gold Games :


--
type:  -> enhancement

___
Python tracker 

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



[issue41835] Speed up dict vectorcall creation using keywords

2020-10-22 Thread Marco Sulla


Marco Sulla  added the comment:

Another bench:

python -m pyperf timeit --rigorous "dict(ihinvdono='doononon', 
gowwondwon='nwog', bdjbodbob='nidnnpn', nwonwno='vndononon', 
dooodbob='iohiwipwgpw', doidonooq='ndwnnpnpnp', fndionqinqn='ndjboqoqjb', 
nonoeoqgoqb='bdboboqbgoqeb', jdnvonvoddo='nvdjnvndvonoq', 
njnvodnoo='hiehgieba', nvdnvwnnp='wghgihpa', nvfnwnnq='nvdknnnqkm', 
ndonvnipnq='fndjnaobobvob', fjafosboab='ndjnodvobvojb', 
nownwnojwjw='nvknnndnow', niownviwnwnwi='nownvwinvwnwnwj')"

Result without pull:
Mean +- std dev: 486 ns +- 8 ns

Result with pull:
Mean +- std dev: 328 ns +- 4 ns

I compiled both with optimizations and lto.

Some arch info:

python -VV
Python 3.10.0a1+ (heads/master-dirty:dde91b1953, Oct 22 2020, 14:00:51) 
[GCC 10.1.1 20200718]

uname -a
Linux buzz 4.15.0-118-generic #119-Ubuntu SMP Tue Sep 8 12:30:01 UTC 2020 
x86_64 x86_64 x86_64 GNU/Linux

lsb_release -a
No LSB modules are available.
Distributor ID: Ubuntu
Description:Ubuntu 18.04.5 LTS

--

___
Python tracker 

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



[issue42035] [C API] PyType_GetSlot cannot get tp_name

2020-10-22 Thread fancitron


fancitron  added the comment:

True enough.  Btw, PyType_FromSpec accepts Py_tp_doc (char *), Py_tp_base 
(PyTypeObject *), etc ... so to be strictly standard compliant, a union would 
be necessary.

PyType_GetName() sounds great.

One "proper" workaround at the moment is PyObject_GetAttrString(Py_TYPE(x), 
"__name__") and then process the result.  This is somewhat "heavy" and strips 
the module name.  "Py_tp_name" provides a convenient, exception safe, and 
backward compatible way to access tp_name.

What I actually do right now is to access the (opaque) PyTypeObject::tp_name by 
pointer offset.  This certain defies the purpose of stable ABI!

--

___
Python tracker 

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



[issue42117] asyncio calls from sync/async, better docs or api support

2020-10-22 Thread Blaze Spinnaker


New submission from Blaze Spinnaker :

In jupyter / ipython, other repls, as well as from libraries,  asyncio code can 
be called.  To simplify integration, there should be a way for libraries to 
transparently do the right thing, call await or start a new global running 
event loop.  

This can be done without breaking the colored functions design constraint (only 
async can call async) and would not lead to dynamic coroutine architectures 
like gevent / lua.

The change would significantly reduce confusion that is pervasive in the python 
ecosystem and has lead to many people using a defacto approach of monkey 
patching (a monkey patch which only works on the surface).

Alternative, if this approach simply can not be accepted, better and more 
emphasized headline asyncio documentation would be appropriate to explain why 
the constraint is in place and the best patterns to use to work around the 
problem.   

It took me a lot of googling before I understood the reasoning of what is a 
very significant design choice.

There are many instances of this issue causing problems, but let me highlight 
this link:

https://github.com/ipython/ipykernel/issues/548#issuecomment-713637954

--
components: asyncio
messages: 379292
nosy: asvetlov, blazespinnaker, yselivanov
priority: normal
severity: normal
status: open
title: asyncio calls from sync/async, better docs or api support
type: enhancement

___
Python tracker 

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



[issue38980] Compile libpython with -fno-semantic-interposition

2020-10-22 Thread Petr Viktorin


Petr Viktorin  added the comment:

I was too eager in reviewing this :(
It turns out `-fno-semantic-interposition` is GCC 5.3, so [builds fail on older 
GCC](https://buildbot.python.org/all/#/builders/96/builds/216).

I'm researching how to make this conditional in autotools.

--
nosy: +petr.viktorin
status: closed -> open

___
Python tracker 

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



[issue42117] asyncio calls from sync/async, better docs or api support

2020-10-22 Thread Blaze Spinnaker


Change by Blaze Spinnaker :


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



[issue39046] collections.abc.Reversible should not be a subclass of Hashable

2020-10-22 Thread Zac Hatfield-Dodds


Zac Hatfield-Dodds  added the comment:

I'm closing this as not-a-bug.

The way protocols just check methods does make sense (thanks for your comment 
Guido!), and a later refactoring of the code that prompted this issue (to deal 
only in concrete classes) dissolved the problem.

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



[issue42117] asyncio calls from sync/async, better docs or api support

2020-10-22 Thread Blaze Spinnaker


Blaze Spinnaker  added the comment:

Note that the biggest problem are obviously repls, and there are quite a few 
(iPython has issues due to it's high coupling with jupyter).  Providing a 
contract for them will ensure consistent support across the ecosystem rather 
than a hodge podge of barely working hacks.


One solution, not meant to be prescriptive, is to provide a repl only API meant 
to execute at the top of the stack (from perspective of user) only.

--

___
Python tracker 

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



[issue38980] Compile libpython with -fno-semantic-interposition

2020-10-22 Thread Petr Viktorin


Change by Petr Viktorin :


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

___
Python tracker 

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



[issue42110] race condition in ThreadChildWatcher (default) and MultiLoopChildWatcher

2020-10-22 Thread Alan Jenkins


Alan Jenkins  added the comment:

There's one way to fix this in MultiLoopChildWatcher (but not 
ThreadedChildWatcher).  Make sure the waitpid() runs on the same thread that 
created the subprocess.  Prototype: 
https://github.com/sourcejedi/cpython/commit/92f979bce4582e807facb1c274a962b3caf0d2eb

The other approach would be to copy subprocess.wait(timeout) - keep waking up 
regularly and polling to see if the process has exited yet.

I'm not convinced ThreadedChildWatcher is fixable.  You can't call waitpid() in 
one thread, and let someone call kill() in a different thread.

You could try avoiding calling waitpid() until someone does `await 
asyncio.subprocess.Process.wait()`.  I think I didn't like it because - what 
happens if you cancel a wait() task?  I think you want to cancel the waitpid() 
so you could safely kill() again... And we don't have any way to cancel the 
blocking waitpid() call, at least not from python, definitely not since PEP-475.

--

___
Python tracker 

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



[issue42057] peephole optimizer bug relating to JUMP_IF_NOT_EXC_MATCH

2020-10-22 Thread Mark Shannon


Change by Mark Shannon :


--
pull_requests: +21825
pull_request: https://github.com/python/cpython/pull/22893

___
Python tracker 

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



[issue42110] race condition in ThreadChildWatcher (default) and MultiLoopChildWatcher

2020-10-22 Thread Alan Jenkins


Alan Jenkins  added the comment:

Put the other way, if you wanted to fix this bug in ThreadedChildWatcher, and 
go as far as allowing cancelling Process.wait(), followed by kill() / 
send_signal(), then I think you need -

* siginterrupt(SIGCHLD, 1)
* not to mind about any random C code that doesn't really handle being 
interrupted.  Like printf(), ho hum.  
https://groups.google.com/g/comp.unix.programmer/c/QZmFw1VytYs/m/BSBXBHTI1REJ
* add & use a new call like os.waitpid_interruptible(), which doesn't restart 
on EINTR, as a workaround for PEP-475.
* set a "stop" flag for the watcher thread
* use threading.pthread_kill() (available on *most* python platforms) to 
interrupt the watcher thread.  Spoof SIGCHLD, this will avoid conflicts with a 
python handler for any other signal.
* wait for the watcher thread to finish using Thread.join()
* now you can safely find out whether the child process has been reaped, or 
whether it's safe to kill it.

--

___
Python tracker 

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



[issue42111] Make the xxlimited module an example of best extension module practices

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



[issue42111] Make the xxlimited module an example of best extension module practices

2020-10-22 Thread Dong-hee Na


Dong-hee Na  added the comment:

I am +1 on this idea.

--

___
Python tracker 

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



[issue42086] AST: Document / re-design? the simple constructor nodes from sums

2020-10-22 Thread Batuhan Taskaya


Batuhan Taskaya  added the comment:

After doing experiments with annotating the operator nodes with position 
information, it is concluded that it doesn't worth the efforts of changing all 
occurrences of operators from enum to a struct. Other than that, it was 
designated that we'll keep this behavior and document it.

--

___
Python tracker 

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



[issue42118] TypeError gives wrong reserved name

2020-10-22 Thread Jason Schwefel


New submission from Jason Schwefel :

The following code gives a "TypeError: 'str' object is not callable" exception:

int = ''
s = '3500:day'
a = s.split(':')
i = int(a[0])

Proper exception message should be "TypeError: 'int' object is not callable" 

Only able to test on 3.8 and 3.9

--
components: Interpreter Core
messages: 379300
nosy: jason.schwefel78
priority: normal
severity: normal
status: open
title: TypeError gives wrong reserved name
type: behavior
versions: 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



[issue25655] Python errors related to failures loading DLL's lack information

2020-10-22 Thread Steve Dower


Steve Dower  added the comment:


New changeset b6f2fc90409e291822166d74ce7402e0ef4dba91 by Philippe Ombredanne 
in branch 'master':
bpo-25655: Improve Win DLL loading failures doc (GH-22372)
https://github.com/python/cpython/commit/b6f2fc90409e291822166d74ce7402e0ef4dba91


--

___
Python tracker 

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



[issue27477] IDLE: Switch search dialogs to ttk widgets, and other refinement

2020-10-22 Thread Mark Roseman


Mark Roseman  added the comment:

Just noting that the current search dialogs (and others) do not have a 
ttk.Frame directly inside the toplevel which encloses all other widgets. They 
therefore still display the mismatched backgrounds on macOS.

Given that, should #33987 be reopened? The patches seem to change the existing 
frames to the ttk equivalent, but don't add the new intervening frame.

--

___
Python tracker 

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



[issue25655] Python errors related to failures loading DLL's lack information

2020-10-22 Thread miss-islington


Change by miss-islington :


--
nosy: +miss-islington
nosy_count: 8.0 -> 9.0
pull_requests: +21826
pull_request: https://github.com/python/cpython/pull/22894

___
Python tracker 

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



[issue25655] Python errors related to failures loading DLL's lack information

2020-10-22 Thread miss-islington


Change by miss-islington :


--
pull_requests: +21827
pull_request: https://github.com/python/cpython/pull/22895

___
Python tracker 

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



[issue25655] Python errors related to failures loading DLL's lack information

2020-10-22 Thread Steve Dower


Steve Dower  added the comment:

Thanks for the PR!

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



[issue42057] peephole optimizer bug relating to JUMP_IF_NOT_EXC_MATCH

2020-10-22 Thread Dong-hee Na


Dong-hee Na  added the comment:


New changeset b52432cb8cd7f5f1fc71ea3b7c0ea11573d504f0 by Mark Shannon in 
branch 'master':
bpo-42057: Add regression test to master. (GH-22893)
https://github.com/python/cpython/commit/b52432cb8cd7f5f1fc71ea3b7c0ea11573d504f0


--
nosy: +corona10

___
Python tracker 

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



[issue42086] AST: Document / re-design? the simple constructor nodes from sums

2020-10-22 Thread Batuhan Taskaya


Change by Batuhan Taskaya :


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

___
Python tracker 

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



[issue42118] TypeError gives wrong reserved name

2020-10-22 Thread Eric V. Smith


Eric V. Smith  added the comment:

You've rebound "int" to a string. I think the error message is correct.

Here's a simpler case:

>>> int = ''
>>> int
''
>>> int()
Traceback (most recent call last):
  File "", line 1, in 
TypeError: 'str' object is not callable

What do you expect to gain with the "int = ''" statement?

--
nosy: +eric.smith

___
Python tracker 

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



[issue25655] Python errors related to failures loading DLL's lack information

2020-10-22 Thread miss-islington


miss-islington  added the comment:


New changeset 5d8bc65ba5be5742b3a4cc470dfd990512bdaa93 by Miss Skeleton (bot) 
in branch '3.8':
bpo-25655: Improve Win DLL loading failures doc (GH-22372)
https://github.com/python/cpython/commit/5d8bc65ba5be5742b3a4cc470dfd990512bdaa93


--

___
Python tracker 

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



[issue25655] Python errors related to failures loading DLL's lack information

2020-10-22 Thread Eryk Sun


Eryk Sun  added the comment:

Steve, the PR that you pushed has the wrong error and error message. I told 
Philippe in msg377335 that ctypes raises FileNotFoundError with no error code. 
For example:

>>> try: ctypes.CDLL('spam')
... except OSError as e: err = e
...
>>> err
FileNotFoundError("Could not find module 'spam' (or one of its 
dependencies). Try using the full path with constructor syntax.")
>>> err.winerror is None
True

The advice to use dumpbin is fine and works well in simple cases. I wouldn't 
use it generally since recursiveley parsing through the dependency graph of 
every dependent DLL could be tedious.

--

___
Python tracker 

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



[issue42086] AST: Document / re-design? the simple constructor nodes from sums

2020-10-22 Thread miss-islington


miss-islington  added the comment:


New changeset b37c994e5ac73268abe23c52005b80cdca099793 by Batuhan Taskaya in 
branch 'master':
bpo-42086: Document AST operator nodes acts as a singleton (GH-22896)
https://github.com/python/cpython/commit/b37c994e5ac73268abe23c52005b80cdca099793


--
nosy: +miss-islington

___
Python tracker 

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



[issue25655] Python errors related to failures loading DLL's lack information

2020-10-22 Thread miss-islington


miss-islington  added the comment:


New changeset f22f874a66d6ddb32fa74ad4325199db7e4c25fd by Miss Skeleton (bot) 
in branch '3.9':
bpo-25655: Improve Win DLL loading failures doc (GH-22372)
https://github.com/python/cpython/commit/f22f874a66d6ddb32fa74ad4325199db7e4c25fd


--

___
Python tracker 

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



[issue42086] AST: Document / re-design? the simple constructor nodes from sums

2020-10-22 Thread miss-islington


Change by miss-islington :


--
pull_requests: +21829
pull_request: https://github.com/python/cpython/pull/22897

___
Python tracker 

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



[issue38980] Compile libpython with -fno-semantic-interposition

2020-10-22 Thread Petr Viktorin


Petr Viktorin  added the comment:


New changeset c6d7e82d19c091af698d4e4b3623648e259843e3 by Petr Viktorin in 
branch 'master':
bpo-38980: Only apply -fno-semantic-interposition if available (GH-22892)
https://github.com/python/cpython/commit/c6d7e82d19c091af698d4e4b3623648e259843e3


--

___
Python tracker 

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



[issue38980] Compile libpython with -fno-semantic-interposition

2020-10-22 Thread Petr Viktorin


Change by Petr Viktorin :


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



[issue24165] Free list for single-digits ints

2020-10-22 Thread Pablo Galindo Salgado


Pablo Galindo Salgado  added the comment:

Inada-san, you can run pyperformance with this workaround:

python -m pip install pyperformance==1.0.0

We are fixing the error soon after 
https://discuss.python.org/t/pep-641-using-an-underscore-in-the-version-portion-of-python-3-10-compatibility-tags/5513
 lands

--
nosy: +pablogsal

___
Python tracker 

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



[issue2190] MozillaCookieJar ignores HttpOnly cookies

2020-10-22 Thread Daniel Lenski


Daniel Lenski  added the comment:

@terry.reedy, it looks like my PR just needs a core developer to review it. 
Would you mind taking a look? :-)

https://github.com/python/cpython/pull/22798

--

___
Python tracker 

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



[issue42119] Error when debugging logging.FileHandler subclass __init__ method

2020-10-22 Thread Françoise CONIL

New submission from Françoise CONIL :

In pdb, when I hit "a" to see __init__ parameters of a logging.FileHandler 
subclass, I get an error because __repr__ needs a logging level. The level has 
been removed from the parameters by configure_handler() when it instanciates 
the handler. The level is set after the handler instanciation.

I do not know if it can be changed or if I missed something.

Traceback (most recent call last):
  File "/usr/lib/python3.8/logging/config.py", line 563, in configure
handler = self.configure_handler(handlers[name])
  File "/usr/lib/python3.8/logging/config.py", line 744, in configure_handler
result = factory(**kwargs)
  File 
"/home/fconil/Progs/python/logging/multiprocesses-to-files-with-dict.py", line 
53, in __init__
pfilename = f"{filename}-{os.getpid()}.log"
  File 
"/home/fconil/Progs/python/logging/multiprocesses-to-files-with-dict.py", line 
53, in __init__
pfilename = f"{filename}-{os.getpid()}.log"
  File "/usr/lib/python3.8/bdb.py", line 88, in trace_dispatch
return self.dispatch_line(frame)
  File "/usr/lib/python3.8/bdb.py", line 112, in dispatch_line
self.user_line(frame)
  File "/usr/lib/python3.8/pdb.py", line 262, in user_line
self.interaction(frame, None)
  File "/usr/lib/python3.8/pdb.py", line 357, in interaction
self._cmdloop()
  File "/usr/lib/python3.8/pdb.py", line 322, in _cmdloop
self.cmdloop()
  File "/usr/lib/python3.8/cmd.py", line 138, in cmdloop
stop = self.onecmd(line)
  File "/usr/lib/python3.8/pdb.py", line 423, in onecmd
return cmd.Cmd.onecmd(self, line)
  File "/usr/lib/python3.8/cmd.py", line 217, in onecmd
return func(arg)
  File "/usr/lib/python3.8/pdb.py", line 1146, in do_args
self.message('%s = %r' % (name, dict[name]))
  File "/usr/lib/python3.8/logging/__init__.py", line 1186, in __repr__
level = getLevelName(self.level)
AttributeError: 'MultiFileHandler' object has no attribute 'level'

--
components: Library (Lib)
files: multiprocesses-to-files-with-dict.py
messages: 379313
nosy: fcodvpt
priority: normal
severity: normal
status: open
title: Error when debugging logging.FileHandler subclass __init__ method
type: enhancement
versions: Python 3.8
Added file: 
https://bugs.python.org/file49535/multiprocesses-to-files-with-dict.py

___
Python tracker 

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



[issue42118] TypeError gives wrong reserved name

2020-10-22 Thread Eric V. Smith


Eric V. Smith  added the comment:

I should point out that this is the same as doing:

>>> ''()
:1: SyntaxWarning: 'str' object is not callable; perhaps you missed a 
comma?
Traceback (most recent call last):
  File "", line 1, in 
TypeError: 'str' object is not callable

Except for the SyntaxWarning part, where the compiler is trying to be helpful.

--

___
Python tracker 

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



[issue25655] Python errors related to failures loading DLL's lack information

2020-10-22 Thread Steve Dower


Steve Dower  added the comment:

> Steve, the PR that you pushed has the wrong error and error message. 

Ah whoops. I'll reopen and hopefully someone can fix it up.

> The advice to use dumpbin is fine and works well in simple cases. 

It's only meant as a starting point. It's possible to brute force your way 
through more complex cases, but to describe anything more advanced we'd be 
writing a tutorial in our docs, which is not appropriate.

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



[issue25655] Python errors related to failures loading DLL's lack information

2020-10-22 Thread Steve Dower


Change by Steve Dower :


--
versions: +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



[issue42115] Caching infrastructure for the evaluation loop: specialised opcodes

2020-10-22 Thread Barry A. Warsaw


Change by Barry A. Warsaw :


--
nosy: +barry

___
Python tracker 

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



[issue42118] TypeError gives wrong reserved name

2020-10-22 Thread Raymond Hettinger


Raymond Hettinger  added the comment:

Closing as "not a bug".

--
nosy: +rhettinger
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



[issue42096] zipfile.is_zipfile incorrectly identifying a gzipped file as a zip archive

2020-10-22 Thread Brian Kohan


Brian Kohan  added the comment:

Hi all,

I'm experiencing the same issue. I took a look at the is_zipfile code - seems 
like its not checking the start of the file for the magic numbers, but looking 
deeper in. I presume because the magic numbers at the start are considered 
unreliable for some reason? Seems like this opens the check up to unlucky 
random false positives though.

Offending file:

https://www.dropbox.com/s/t2kafn6ek1m2huy/CHPI_Rinex.crx?dl=1

--
nosy: +bckohan
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



[issue2350] 'exceptions' import fixer

2020-10-22 Thread Irit Katriel


Irit Katriel  added the comment:

Updating the versions, though it seems that you may want to close this as 
rejected based on the discussion.

--
keywords:  -needs review, patch
nosy: +iritkatriel
versions: +Python 3.10, Python 3.8, Python 3.9 -Python 2.7, Python 3.2, Python 
3.3, Python 3.4

___
Python tracker 

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



[issue16094] Tuple extraction in a lambda isn't supported by 2to3

2020-10-22 Thread Irit Katriel


Irit Katriel  added the comment:

Updating the versions, but from the discussion I think this can probably be 
closed as "won't fix".

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

___
Python tracker 

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



[issue16515] TypeError message incorrect for max() with one keyword arg

2020-10-22 Thread Irit Katriel


Change by Irit Katriel :


--
versions: +Python 3.10, Python 3.8, Python 3.9 -Python 2.7, Python 3.2, Python 
3.3, Python 3.4

___
Python tracker 

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



[issue14979] pdb doc: Explain how to extend debugger instead of sending readers to the source

2020-10-22 Thread Irit Katriel


Change by Irit Katriel :


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

___
Python tracker 

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



[issue33987] IDLE: use ttk.Frame for ttk widgets

2020-10-22 Thread Terry J. Reedy


Change by Terry J. Reedy :


--
Removed message: https://bugs.python.org/msg332835

___
Python tracker 

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



[issue42118] TypeError gives wrong reserved name

2020-10-22 Thread Jason Schwefel


Jason Schwefel  added the comment:

>What do you expect to gain with the "int = ''" statement?

I did not expect anything. I made a mistake in my initial code and the error 
message indicated that I rebound 'str'. I could not find where I had used 'str' 
as a variable name. If it would have said 'int', as that was the function that 
I rebound as a variable name, I would have immediately known what to look for.

I understand that it is mostly cosmetic, but I am sure I am not the first 
person that went down the wrong path because of this. 

I understand that I was using the variable named 'int' as a string and 
therefore referencing it as 'str' object is technically correct. However, I am 
still relatively new to Python, as many others are, and the the error message 
could be a bit more clear.

--

___
Python tracker 

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



[issue33987] IDLE: use ttk.Frame for ttk widgets

2020-10-22 Thread Terry J. Reedy


Terry J. Reedy  added the comment:

I closed this prematurely. Cheryl's PR 11433 converts frames for help and 
statusbar.  My patch also omitted searchbase, perhaps because this I wanted to 
refactor at the same time.  In any case, the macOS appearance bug that 
motivated Mark's post remains, and a patch will have to make sure that the 
derived dialogs add frames inside the new master frame instead of the toplevel.

The message I deleted meant to say
#35598 converted config_key to ttk, including a ttk frame inside toplevel.

--
resolution: fixed -> 
stage: resolved -> needs patch
status: closed -> open
versions: +Python 3.10, Python 3.9 -Python 3.7

___
Python tracker 

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



[issue42118] TypeError gives wrong reserved name

2020-10-22 Thread Eric V. Smith


Eric V. Smith  added the comment:

Unfortunately there's not much that can be done about this. The code that 
writes that error message only knows about objects, which don't have names, 
only types and values.

--

___
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-22 Thread Erjia Guan


New submission from Erjia Guan :

At
https://github.com/python/cpython/blob/c60394c7fc9cc09b16e9675a3eeb5844b6d8523f/PC/pyconfig.h#L196,
 the MACRO converts copysign to _copysign. This MACRO is defined 13 years ago 
and it's really dangerous to define a lower-letter MACRO at this low level.
Currently, MSVC is supporting copysign 
(https://docs.microsoft.com/en-us/cpp/c-runtime-library/reference/copysign-copysignf-copysignl-copysign-copysignf-copysignl?view=vs-2019).
I am requesting to remove this MACRO, as my customized copysign API will also 
be converted to _copysign on MSVC platform.

--
components: C API
messages: 379323
nosy: ejguan
priority: normal
severity: normal
status: open
title: Depreciated MACRO of copysign for MSVC
type: compile error
versions: Python 3.8

___
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-22 Thread Erjia Guan


Change by Erjia Guan :


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



[issue33987] IDLE: use ttk.Frame for ttk widgets

2020-10-22 Thread Terry J. Reedy


Terry J. Reedy  added the comment:


New changeset facb522d44fceaf15de6bc95de1cd680c4621c2a by Cheryl Sabella in 
branch 'master':
bpo-33987: IDLE: Use ttk Frame on doc window and statusbar (GH-11433)
https://github.com/python/cpython/commit/facb522d44fceaf15de6bc95de1cd680c4621c2a


--

___
Python tracker 

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



[issue33987] IDLE: use ttk.Frame for ttk widgets

2020-10-22 Thread miss-islington


Change by miss-islington :


--
pull_requests: +21830
stage: needs patch -> patch review
pull_request: https://github.com/python/cpython/pull/22899

___
Python tracker 

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



[issue33987] IDLE: use ttk.Frame for ttk widgets

2020-10-22 Thread miss-islington


Change by miss-islington :


--
pull_requests: +21831
pull_request: https://github.com/python/cpython/pull/22900

___
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-22 Thread Zachary Ware


Change by Zachary Ware :


--
components: +Windows
nosy: +paul.moore, steve.dower, tim.golden, zach.ware

___
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-22 Thread Steve Dower


Steve Dower  added the comment:

Sounds good, but I don't think we can backport it. It's not _our_ public API, 
but it's still going to impact compiling modules.

Also, looking at the docs link above, copysign() is for floats and _copysign() 
is for doubles, which means it's an actual functional change. If POSIX/libc 
copysign() is floats, it's probably fine for a 3.10 change, but if we need to 
preserve the type then it needs to become _Py_copysign throughout.

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



[issue42064] Convert sqlite3 to multi-phase initialisation (PEP 489)

2020-10-22 Thread Erlend Egeberg Aasland


Erlend Egeberg Aasland  added the comment:

Sorted out item 7 (module state). Item 8 is mostly in place, although I get 
ref. count errors if I add traverse/clear callbacks, so I've temporarily 
disabled those.

Proof-of-concept of multi-phase init can be found here: 
https://github.com/erlend-aasland/cpython/commits/bpo-42064/all
I'll try to break items 3 and 7 up in smaller pieces for the reviewer's 
convenience.

--

___
Python tracker 

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



[issue5474] distutils produces invalid RPM packages of prerelease python packages

2020-10-22 Thread Éric Araujo

Éric Araujo  added the comment:

Given the age of this, the status of distutils and the existence of py2rpm, I 
am closing it.

--
resolution:  -> wont fix
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



[issue13316] build_py_2to3 does not convert when there was an error in the last run

2020-10-22 Thread Éric Araujo

Éric Araujo  added the comment:

Closing this.  It was not fixed when it would have been useful, and people 
mostly use other tools that distutils for packaging and 2to3 for transition.

--
resolution:  -> wont fix
stage: test needed -> 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



[issue11831] "pydoc -w" causes "no Python documentation found" error when the path is not current directory

2020-10-22 Thread Éric Araujo

Éric Araujo  added the comment:

pydoc help:

  pydoc -w  ...
Write out the HTML documentation for a module to a file in the current
directory. […]

So there is no support for not using the current directory, probably on purpose 
in order to use the current-dir-in-sys.path trick, so I’m not sure if this 
should be addressed.

(These days I would be more worried about src directories, which I’ve just 
tested are not handled well by pydoc, but that would be a different ticket.)

--

___
Python tracker 

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



[issue42115] Caching infrastructure for the evaluation loop: specialised opcodes

2020-10-22 Thread Yury Selivanov


Yury Selivanov  added the comment:

> This idea can be implemented without opcode cache. I will try it.

I'd actually encourage trying to use the opcode cache because this way the 
optimization will be more generic. E.g. `decimal + decimal` would also be 
specialized via the cache, because you'd cache a pointer to the specific `+` 
operator implementation. I'm really not sure that adding specialized byte code 
is a good idea.

> * PHP uses scalar type for float and int

While at it, maybe we push the number of bits per int digit to 60?

While at it, I'd also increase the digit size

--

___
Python tracker 

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



[issue2774] ctypes documentation not effective

2020-10-22 Thread Irit Katriel


Change by Irit Katriel :


--
assignee:  -> docs@python
components: +ctypes
nosy: +docs@python
versions: +Python 3.10, Python 3.8, Python 3.9 -Python 2.7, Python 3.2, Python 
3.3, Python 3.4

___
Python tracker 

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



[issue13047] imp.find_module("") and imp.find_module(".")

2020-10-22 Thread Irit Katriel


Change by Irit Katriel :


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



[issue33987] IDLE: use ttk.Frame for ttk widgets

2020-10-22 Thread Terry J. Reedy


Terry J. Reedy  added the comment:


New changeset 06c9e01c651c35c2e058eca0f7073dd405578f78 by Miss Skeleton (bot) 
in branch '3.8':
bpo-33987: IDLE: Use ttk Frame on doc window and statusbar (GH-11433) (GH-22900)
https://github.com/python/cpython/commit/06c9e01c651c35c2e058eca0f7073dd405578f78


--

___
Python tracker 

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



[issue33987] IDLE: use ttk.Frame for ttk widgets

2020-10-22 Thread Terry J. Reedy


Terry J. Reedy  added the comment:


New changeset 25687bbe0da160ebdd3cd422a01d677ce467e72e by Miss Skeleton (bot) 
in branch '3.9':
bpo-33987: IDLE: Use ttk Frame on doc window and statusbar (GH-11433) (GH-22899)
https://github.com/python/cpython/commit/25687bbe0da160ebdd3cd422a01d677ce467e72e


--

___
Python tracker 

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



[issue42115] Caching infrastructure for the evaluation loop: specialised opcodes

2020-10-22 Thread Yury Selivanov


Yury Selivanov  added the comment:

> This idea can be implemented without opcode cache. I will try it.

I'd actually encourage trying to use the opcode cache because this way the 
optimization will be more generic. E.g. `decimal + decimal` would also be 
specialized via the cache, because you'd cache a pointer to the specific `+` 
operator implementation. I'm really not sure that adding specialized byte code 
is a good idea.

> * PHP uses scalar type for float and int

While at it, maybe we push the number of bits per int digit to 60?

--

___
Python tracker 

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



[issue42115] Caching infrastructure for the evaluation loop: specialised opcodes

2020-10-22 Thread Yury Selivanov


Change by Yury Selivanov :


--
Removed message: https://bugs.python.org/msg379330

___
Python tracker 

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



[issue40215] Use xdg basedir spec on linux

2020-10-22 Thread Éric Araujo

Éric Araujo  added the comment:

Thanks for the report, but at this stage of the distutils lifecycle (mostly 
unmaintained, may be removed from stdlib) I don’t think such a change would be 
useful.  Packaging guides recommend other tools, such as twine or flit, that 
don’t use this config file.

--
resolution:  -> wont fix
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



[issue41143] distutils uses the locale encoding for the .pypirc file

2020-10-22 Thread Éric Araujo

Éric Araujo  added the comment:

Probably should have been specified as UTF-8, but now compatibility would 
prevent changing it.  I recommend no change.

--

___
Python tracker 

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



[issue41755] Docs: Please remove `from distutils.core import setup`

2020-10-22 Thread Éric Araujo

Éric Araujo  added the comment:

That page is documenting distutils, so it is correctly showing a distutils 
import.  The page also starts with a note linking to setuptools doc.  
Therefore, I would close this ticket.

--
resolution:  -> not a bug
status: open -> pending

___
Python tracker 

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



[issue1109659] distutils argument parsing is bogus

2020-10-22 Thread Éric Araujo

Éric Araujo  added the comment:

Given the current status of distutils (mostly used as a base for setuptools, 
and maybe soon removed from stdlib), I am closing this.

--
resolution:  -> wont fix
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



[issue16729] Document how to provide defaults for setup.py commands options

2020-10-22 Thread Éric Araujo

Change by Éric Araujo :


--
resolution:  -> wont fix
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



[issue27320] ./setup.py --help-commands should sort extra commands

2020-10-22 Thread Éric Araujo

Éric Araujo  added the comment:

This is probably better now that dicts retain insertion order.
If people still think sorting would be better, please forward the feature 
request to setuptools.

--
resolution:  -> wont fix
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



[issue24970] Make distutils.Command an ABC

2020-10-22 Thread Éric Araujo

Change by Éric Araujo :


--
resolution:  -> wont fix
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



[issue24970] Make distutils.Command an ABC

2020-10-22 Thread Antony Lee


Change by Antony Lee :


--
nosy:  -Antony.Lee

___
Python tracker 

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



[issue42117] asyncio calls from sync/async, better docs or api support

2020-10-22 Thread Yury Selivanov


Yury Selivanov  added the comment:

I'm not sure what you're actually proposing, and only have a vague 
understanding of what you're complaining about. This is perhaps related to 
https://bugs.python.org/issue33523? If so then maybe leave a comment there?

--

___
Python tracker 

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



[issue27320] ./setup.py --help-commands should sort extra commands

2020-10-22 Thread Antony Lee


Change by Antony Lee :


--
nosy:  -Antony.Lee

___
Python tracker 

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



[issue24876] distutils.errors not wildcard-import-safe

2020-10-22 Thread Éric Araujo

Éric Araujo  added the comment:

The docstring is wrong, but I don’t think there is much value in changing it 
now.  Style guides generally recommend against star imports, and not many 
people need to import from distutils.errors (setuptools and maybe numpy?).

--
nosy: +jaraco
resolution:  -> wont fix
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



[issue31073] Change metadata handling in check command

2020-10-22 Thread Éric Araujo

Éric Araujo  added the comment:

Not sure how you read that from my comment — I merely wanted to be sure about 
what the spec said! :)

Most people use setuptools than distutils these days, and it’s mostly 
unmaintained, so your idea to report this issue to setuptols is the right one.  
Thanks for the report nonetheless!

--
resolution:  -> wont fix
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



[issue29708] support reproducible Python builds

2020-10-22 Thread Éric Araujo

Change by Éric Araujo :


--
dependencies: +Reproducible pyc: frozenset is not serialized in a deterministic 
order, setup.py sdist --format=gztar should use (equivalent of) `gzip -n`, 
setup.py sdist should honor SOURCE_DATE_EPOCH

___
Python tracker 

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



[issue29708] support reproducible Python builds

2020-10-22 Thread Éric Araujo

Change by Éric Araujo :


--
dependencies:  -setup.py sdist --format=gztar should use (equivalent of) `gzip 
-n`, setup.py sdist should honor SOURCE_DATE_EPOCH

___
Python tracker 

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



[issue28533] Replace asyncore

2020-10-22 Thread Kyle Stanley


Kyle Stanley  added the comment:

Since this issue is now a significant blocker for PEP 594 (remove stdlib dead 
batteries, which includes asyncore and asynchat), I'm going to prioritize 
working on this and assign it to myself.

--
assignee:  -> aeros

___
Python tracker 

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



[issue38727] setup.py sdist --format=gztar should use (equivalent of) `gzip -n`

2020-10-22 Thread Éric Araujo

Éric Araujo  added the comment:

Distutils isn’t used much (directly), I think this should be reported to the 
tools that create sdists, such as setuptools and flit.

--

___
Python tracker 

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



[issue41669] Case mismatch between "include" and "Include"

2020-10-22 Thread Éric Araujo

Éric Araujo  added the comment:

Is this the same as #24908 ?

--
nosy: +eric.araujo

___
Python tracker 

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



[issue29708] support reproducible Python builds

2020-10-22 Thread Will Thompson


Change by Will Thompson :


--
nosy:  -Will Thompson

___
Python tracker 

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



[issue42121] unable to input certain Unicode characters in Text widget

2020-10-22 Thread Xuan Wu

New submission from Xuan Wu :

When creating a text editor with tkinter Text widget, I found that some Chinese 
punctuations cound't be input correctly.

When input "(", which is open parenthesis in Chinese, it behaves like a back 
space.
When input ")", close parenthesis in Chinese, it seems like a tab instead.
When input ";", semicolon in Chinese, it does nothing.

Then I tried input the same in IDLE 3.7.6 and the same happened. Also, the same 
happens in thonny, the python IDE. I suppose they all use Text widget.

Pitifully I don't think of a way to reproduce the issue without using Chinese 
input method.

Please let me know how to help with debugging. Thanks.

--
components: Tkinter
messages: 379345
nosy: nobodxbodon
priority: normal
severity: normal
status: open
title: unable to input certain Unicode characters in Text widget
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



  1   2   >