-
-
Notifications
You must be signed in to change notification settings - Fork 638
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Add test_timeout
fields to go_package
#13707
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
What if the user provides a -timeout
option on the command-line? Shouldn't that take precedence?
I was thinking the option should be a global default. Note that unlike Go, the timeout would be applied per package - not an overall timeout for the whole run. Also how often are you changing the timeout on the fly via CLI arg rather than permanent config in field or pants.toml? For python, we do know it's common to disable timeouts globally though. -- The other approach we can do is to consider banning timeout in the Go pass through args and mirror how Python handles timeouts. Global options for a default and max, a timeout field for the target, and a --timeouts bool option to temporarily disable timeouts. That would be way more consistent. Wdyt? |
skip_tests
and test_timeout
fields to go_package
test_timeout
fields to go_package
Maybe just add a separate "default test timeout" option then and apply it if a As a user, I expect the timeout supplied on the command-line to take precedence if I run a command like |
K, so to recap, you think this?
And then I had suggested banning |
What is the motivation for |
# Rust tests and lints will be skipped. Delete if not intended. [ci skip-rust] # Building wheels and fs_util will be skipped. Delete if not intended. [ci skip-build-wheels]
17bc27b
to
104df61
Compare
So we decided to not spend more time on this PR to focus on other priorities. Meaning not (yet) implementing It's still an open question what to do for
@tdyas do you still think #2 makes sense even without those other options implemented? I think it's a bad idea to document using |
The issue for me is not that the user will set |
[ci skip-rust] [ci skip-build-wheels]
# Rust tests and lints will be skipped. Delete if not intended. [ci skip-rust] # Building wheels and fs_util will be skipped. Delete if not intended. [ci skip-build-wheels]
# Rust tests and lints will be skipped. Delete if not intended. [ci skip-rust] # Building wheels and fs_util will be skipped. Delete if not intended. [ci skip-build-wheels]
9218051
to
71531f5
Compare
# Rust tests and lints will be skipped. Delete if not intended. [ci skip-rust] # Building wheels and fs_util will be skipped. Delete if not intended. [ci skip-build-wheels]
# Rust tests and lints will be skipped. Delete if not intended. [ci skip-rust] # Building wheels and fs_util will be skipped. Delete if not intended. [ci skip-build-wheels]
Closes #13530.
Unlike Python, we use Go's native timeout support instead of the engine's. Users could have already set the timeout globally via
[go-test].args
, so we have to special-case that the field should override those args.