Skip to content

allow BLE001 if traceback is generated? #2212

@spaceone

Description

@spaceone

BLE001 allows

try:
        foo
except Exception:
        raise

but disallows:

try:
        foo
except Exception:
        print(traceback.format_exc())
        logger.log(traceback.format_exc())
        logger.exception('something is broken')

I think generating a traceback is an indication of handling the exception properly.

Metadata

Metadata

Assignees

No one assigned

    Labels

    bugSomething isn't working

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions