[Python-Dev] raising a io exception when fileno is requested on a tarfile FileInFile

2021-10-29 Thread Stephen J. Turnbull
makap...@gmail.com writes: > When you call extractfile() on a TarFile, the result is a buffered > version of a _FileInFile pseudo-file. When fileno() is called on > this resulting file, fileno() it not exist (understandably) and an > AttributeError is raised. I would like to suggest raising

[Python-Dev] Re: Should the definition of an "(async) iterator" include __iter__?

2021-10-29 Thread Brett Cannon
FYI I opened https://github.com/python/cpython/pull/29170 to loosen/correct the definition of "iterator", but I got push-back on the PR and this thread never reached a clear conclusion. As such I'll ask the SC to make a call. ___ Python-Dev mailing

[Python-Dev] Re: Oh wow, this is really impressive

2021-10-29 Thread Abdur-Rahmaan Janhangeer
The last thing Py which got a  from me was pip's caching mechanism when installing packages! ___ Python-Dev mailing list -- python-dev@python.org To unsubscribe send an email to python-dev-le...@python.org

[Python-Dev] Summary of Python tracker Issues

2021-10-29 Thread Python tracker
ACTIVITY SUMMARY (2021-10-22 - 2021-10-29) Python tracker at https://bugs.python.org/ To view or respond to any of the issues listed below, click on the issue. Do NOT respond to this message. Issues counts and deltas: open7249 (+50) closed 50157 (+46) total 57406 (+96) Open issues

[Python-Dev] Re: Oh wow, this is really impressive

2021-10-29 Thread Pablo Galindo Salgado
I am glad you like it :) I have been told that this is a very popular improvement. I promise to keep looking for similar things in the future! Regards from cloudy London, Pablo Galindo Salgado On Fri, 29 Oct 2021, 18:23 Steven D'Aprano, wrote: > I was using Python 3.10 and got this NameError

[Python-Dev] Oh wow, this is really impressive

2021-10-29 Thread Steven D'Aprano
I was using Python 3.10 and got this NameError when I mistyped a name: NameError: name 'KeyboardInterrupted' is not defined. Did you mean: 'KeyboardInterrupt'? It even works for attribute errors too. That's fantastic! This is a really amazing useability improvement, thank you everyone who was

[Python-Dev] Re: PEP 3118 C APIs

2021-10-29 Thread Antoine Pitrou
Hi Joannah, On Thu, 21 Oct 2021 13:00:11 -0300 Joannah Nanjekye wrote: > Last year I opened the following issues, to implement > int PyObject_CopyToObject() and PyObject *PyObject_GetMemoryView(PyObject > *obj). > > They were meant to be as part of PEP 3118, I wonder if they are worth an >

[Python-Dev] raising a io exception when fileno is requested on a tarfile FileInFile

2021-10-29 Thread makapuf2
Hi, When you call extractfile() on a TarFile, the result is a buffered version of a _FileInFile pseudo-file. When fileno() is called on this resulting file, fileno() it not exist (understandably) and an AttributeError is raised. I would like to suggest raising an io.UnsupportedOperation

[Python-Dev] Re: Naming convention for AST types

2021-10-29 Thread Larry Hastings
Hey, as public mailing list mistakes go, that one's pretty mild. //arry/ On 10/28/21 6:35 PM, Jeremiah Vivian wrote: Sorry for the two replies, I didn't think the first one would be sent. ___ Python-Dev mailing list -- python-dev@python.org To

[Python-Dev] Re: Python multithreading without the GIL

2021-10-29 Thread Skip Montanaro
> > Did you try running the same code with stock Python? > > One reason I ask is the IIUC, you are using numpy for the individual > vector operations, and numpy already releases the GIL in some > circumstances. > I had not run the same code with stock Python (but see below). Also, I only used

[Python-Dev] Re: PEP 670: Convert macros to functions in the Python C API

2021-10-29 Thread Antoine Pitrou
On Wed, 20 Oct 2021 02:55:52 +0200 Victor Stinner wrote: > > Debug build > --- > > When Python is built in debug mode, most compiler optimizations are > disabled. For example, Visual Studio disables inlining. Benchmarks must > not be run on a Python debug build, only on release build: