Skip to content

Cryptic error message about ENV CHANGED #132581

Open
@serhiy-storchaka

Description

@serhiy-storchaka

See for example #132535.

When there are leaked resources that emit a resource warning in destructor, and the test was ran with the -Werror option, the warnings are converted to unhandled exceptions, and the error report will contain:

...

== Tests result: ENV CHANGED then ENV CHANGED ==

...

1 test altered the execution environment (env changed):
    test_timeout

...

Total test files: run=467/470 (filtered) env_changed=1 skipped=16 resource_denied=4 rerun=1
Result: ENV CHANGED then ENV CHANGED

...

These "ENV CHANGED then ENV CHANGED" look pretty cryptic for regular user. And "altered the execution environment (env changed)" is not particularly useful at all. Even if "env changed" is repeated in three places, it does not add clarity.

It would be nice to decipher it and provide more details. For every test explain what "environment" was altered in more human words -- leaked files, unhandled exceptions, etc.

Metadata

Metadata

Assignees

No one assigned

    Labels

    3.13bugs and security fixes3.14new features, bugs and security fixestestsTests in the Lib/test dir

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions