Can flake8 flag function calls that do not catch exceptions?

Suppose we have a function my_function that throws exceptions. Can flake8 (or a plugin) tell whether this function was called without handling exceptions, i.e., outside a try block? I would like to verify that my code handles the exceptions that may be raised by any function it calls. If this feature is not available, I believe it would be useful to add. Many thanks, Inigo

Flake8 is a framework for others to use to implement checks like what you're asking for. It's theoretically possible for something to implement this within the scope of a module, but outside of that, this would be very difficult to implement. I suspect pylint has a better way of implementing something like this, regardless of its (the problem space) probable high rate of false negatives Sent from my phone with my typo-happy thumbs. Please excuse my brevity On Sun, Mar 5, 2023, 12:34 Inigo Incer <inigo@eecs.berkeley.edu> wrote:

Flake8 is a framework for others to use to implement checks like what you're asking for. It's theoretically possible for something to implement this within the scope of a module, but outside of that, this would be very difficult to implement. I suspect pylint has a better way of implementing something like this, regardless of its (the problem space) probable high rate of false negatives Sent from my phone with my typo-happy thumbs. Please excuse my brevity On Sun, Mar 5, 2023, 12:34 Inigo Incer <inigo@eecs.berkeley.edu> wrote:
participants (2)
-
Ian Stapleton Cordasco
-
Inigo Incer