[issue45210] tp_dealloc docs should mention error indicator may be set

2021-09-15 Thread Edward Yang
New submission from Edward Yang : The fact that the error indicator may be set during tp_dealloc is somewhat well known (https://github.com/posborne/dbus-python/blob/fef4bccfc535c6c2819e3f15384600d7bc198bc5/_dbus_bindings/conn.c#L387) but it's not documented in the official manual. We s

[issue12458] Tracebacks should contain the first line of continuation lines

2021-06-15 Thread Edward Yang
Edward Yang added the comment: Supposing I like the old behavior (line number of the end of the statement), is there any way to recover that line number from the traceback after this change? -- nosy: +ezyang ___ Python tracker <ht

[issue40897] Inheriting from Generic causes inspect.signature to always return (*args, **kwargs) for constructor (and all subclasses)

2020-06-06 Thread Edward Yang
New submission from Edward Yang : Consider the following program: ``` import inspect from typing import Generic, TypeVar T = TypeVar('T') class A(Generic[T]): def __init__(self) -> None: pass print(inspect.signature(A)) ``` I expect inspect.signature to ret

[issue14531] Backtrace should not attempt to open file

2012-04-08 Thread Edward Yang
Edward Yang added the comment: "" is a valid name of a file on Unix systems. So the fix is not so clear. ezyang@javelin:~$ python Python 2.7.2+ (default, Oct 4 2011, 20:03:08) [GCC 4.6.1] on linux2 Type "help", "copyright", "credits" or "license

[issue14531] Backtrace should not attempt to open file

2012-04-08 Thread Edward Yang
New submission from Edward Yang : When generating a backtrace from an interactive Python session (e.g. the input is from , Python attempts to actually find a file named , to somewhat hilarious consequences. See the strace'd Python session below: >>> foo open("/etc/defaul

[issue14416] syslog missing constants

2012-03-26 Thread Edward Yang
Edward Yang added the comment: I misspoke about UUCP. SYSLOG appears to be missing from the documentation. Arguably they should be present if Linux supports them, and missing if they don't (same as LOG_PERROR, and some of the other constants.) Then you can do feature detection Python

[issue14416] syslog missing constants

2012-03-26 Thread Edward Yang
New submission from Edward Yang : The syslog module is missing constants for a number of logging priorities available on modern Linuxen. In particular, the following options are missing: LOG_ODELAY, LOG_AUTHPRIV, LOG_SYSLOG, LOG_UUCP. -- components: Library (Lib) messages: 156842 nosy