Skip to content

Do not clear arbitrary errors on import #112660

Closed
@serhiy-storchaka

Description

@serhiy-storchaka

Currently the import and module code can clear arbitrary errors when format error message for ImportError or AttributeError and override them with ImportError or AttributeError. Usually it is not an issue, because these errors (accessing missed attribute or dict key) should be ignored, but in theory it can be arbitrary error, like KeyboardInterrupt, MemoryError or Recursion error which should not be ignored.

Linked PRs

Metadata

Metadata

Assignees

No one assigned

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions