Perfect your code
With built-in code review tools, GitHub makes it easy to raise the quality bar before you ship. Join the 40 million developers who've merged over 200 million pull requests.
Sign up for free See pricing for teams and enterprisesbpo-38614: Use test.support.LONG_TIMEOUT constant #17562
Conversation
Replace hardcoded timeout constants in tests with LONG_TIMEOUT of test.support, so it's easier to ajdust this timeout for all tests at once. LONG_TIMEOUT is 5 minutes by default, but it can be longer depending on --timeout command line option.
LGTM I checked locally and this does not make the test suite run longer (no hanging timeout is involved in any successful test) but I assume that now if test hang, will hang 5 times more, no? |
This comment has been minimized.
This comment has been minimized.
"but I assume that now if test hang, will hang 5 times more, no?" Yes, it hangs 5 times longer. But buildbots are automated, they dont waste developers time. If a test hangs 1 min or 1 hour, it is the same for me. But I care of flaky tests which only fail because a timeout is too short. We can make LONG_TIMEOUT shorter if it becomes an issue. Previously, each test had to be fine tuned :-( To be clear, if a test hangs, it is a bug |
vstinner commentedDec 10, 2019
•
edited by bedevere-bot
Replace hardcoded timeout constants in tests with LONG_TIMEOUT of
test.support, so it's easier to ajdust this timeout for all tests at
once.
LONG_TIMEOUT is 5 minutes by default, but it can be longer depending
on --timeout command line option.
https://bugs.python.org/issue38614