[New-bugs-announce] [issue39629] inspect.signature fails on math.hypot

Eric Fahlgren report at bugs.python.org
Thu Feb 13 13:16:37 EST 2020


New submission from Eric Fahlgren <ericfahlgren at gmail.com>:

Python 3.8's new math.hypot function also appears to suffer from the same issue as math.log:

>>> import math, inspect
>>> inspect.signature(math.hypot)
Traceback (most recent call last):
  File "<stdin>", line 1, in <module>
  File "C:\Program Files\Python38\lib\inspect.py", line 3093, in signature
    return Signature.from_callable(obj, follow_wrapped=follow_wrapped)
  File "C:\Program Files\Python38\lib\inspect.py", line 2842, in from_callable
    return _signature_from_callable(obj, sigcls=cls,
  File "C:\Program Files\Python38\lib\inspect.py", line 2296, in _signature_from_callable
    return _signature_from_builtin(sigcls, obj,
  File "C:\Program Files\Python38\lib\inspect.py", line 2107, in _signature_from_builtin
    raise ValueError("no signature found for builtin {!r}".format(func))
ValueError: no signature found for builtin <built-in function hypot>

Possibly related to issue29299?

----------
components: Library (Lib)
messages: 361966
nosy: eric.fahlgren
priority: normal
severity: normal
status: open
title: inspect.signature fails on math.hypot
type: behavior
versions: Python 3.8

_______________________________________
Python tracker <report at bugs.python.org>
<https://bugs.python.org/issue39629>
_______________________________________


More information about the New-bugs-announce mailing list