You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
trace fails when test imported a temporary file #55200
Note: these values reflect the state of the issue at the time it was migrated and might not reflect the current state.
Show more details
GitHub fields:
assignee=Noneclosed_at=<Date2019-05-14.04:15:47.691>created_at=<Date2011-01-23.23:31:12.014>labels= ['type-bug', 'library']
title='trace fails when test imported a temporary file'updated_at=<Date2019-05-14.04:15:47.690>user='https://github.com/brettcannon'
If you run test.regrtest -T you will discover that (at least) test_importlib and test_runpy prevent coverage data from being written out as 'trace' will try to find files which no longer exist. Both test suites create temp files, import them, and then delete them. Unfortunately 'trace' doesn't ignore that fact and throws an exception that the temporary files are gone.
Since the file is simply gone it probably makes sense to have 'trace' just print out a warning that the file could not be found and move on.
Activity
brettcannon commentedon Jan 23, 2011
If you run
test.regrtest -Tyou will discover that (at least) test_importlib and test_runpy prevent coverage data from being written out as 'trace' will try to find files which no longer exist. Both test suites create temp files, import them, and then delete them. Unfortunately 'trace' doesn't ignore that fact and throws an exception that the temporary files are gone.Since the file is simply gone it probably makes sense to have 'trace' just print out a warning that the file could not be found and move on.
BreamoreBoy commentedon Jul 16, 2014
Knowing the platform this occurred on would be useful, but given the age do we care?
SilentGhost commentedon May 13, 2019
Brett, is this something that is still relevant for the supported versions or are you OK with closing this issue as out of date or wont fix?
brettcannon commentedon May 14, 2019
Since I'm not bothered enough to check if this is still an issue I'm fine with closing this.