Skip to content

fix: replace bare except clauses with except Exception in facade.py#486

Open
harshadkhetpal wants to merge 1 commit intoglobocom:masterfrom
harshadkhetpal:patch-2
Open

fix: replace bare except clauses with except Exception in facade.py#486
harshadkhetpal wants to merge 1 commit intoglobocom:masterfrom
harshadkhetpal:patch-2

Conversation

@harshadkhetpal
Copy link
Copy Markdown

Replace bare except: clauses with except Exception: in api_interface/facade.py.

Bare except: catches all exceptions including SystemExit, KeyboardInterrupt, and GeneratorExit, which can mask critical errors and make debugging harder (PEP 8 E722).

Since these blocks handle fallback logic without re-raising, except Exception: is the correct narrower alternative. No behavioral change for normal operation.

Replace bare `except:` clauses with `except Exception:` in api_interface/facade.py.

Bare `except:` catches all exceptions including `SystemExit`, `KeyboardInterrupt`, and `GeneratorExit`, which can mask critical errors and make debugging harder (PEP 8 E722).

Since these blocks handle fallback logic without re-raising, `except Exception:` is the correct narrower alternative. No behavioral change for normal operation.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant