fix(run): run unattended short also on Windows (#242)

We already have a short run unattended on macOS and we wanna do
the same for Windows. See https://github.com/ooni/probe/issues/1377.
This commit is contained in:
Simone Basso 2021-03-08 12:47:19 +01:00 committed by GitHub
parent 2ef5fb503a
commit f5461323db
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -76,10 +76,11 @@ func init() {
unattendedCmd := cmd.Command("unattended", "")
unattendedCmd.Action(func(_ *kingpin.ParseContext) error {
if runtime.GOOS == "darwin" {
// Until we have enabled the check-in API we're called every
// hour on darwin and we need to self throttle.
// TODO(bassosimone): switch to check-in and remove this hack.
// Until we have enabled the check-in API we're called every
// hour on darwin and we need to self throttle.
// TODO(bassosimone): switch to check-in and remove this hack.
switch runtime.GOOS {
case "darwin", "windows":
const veryFew = 10
probe.Config().Nettests.WebsitesURLLimit = veryFew
}