Re: Would this be called a bug in inspect ?

Collapse
This topic is closed.
X
X
 
  • Time
  • Show
Clear All
new posts
  • Terry Reedy

    Re: Would this be called a bug in inspect ?

    Stef Mientki wrote:
    But the real point is, should a module like inspect not be insensitive
    to these kind of errors ?
    In my opinion, no. In any case, the doc says

    "inspect.getmem bers(object[, predicate])
    Return all the members of an object in a list of (name, value) pairs
    sorted by name. "

    so it is behaving according to spec. Getting the name,value pairs
    should not raise exceptions. If it does, *something* is wrong, as it
    was in this case. Stopping is as sensible as anything, and in line with
    the general behavior of Python.

Working...