Skip to content

Allow setting global timeout on command line#7

Merged
laverya merged 1 commit intoch2399/support-bundle-categoriesfrom
ch2999/timeout-improvements
Oct 26, 2017
Merged

Allow setting global timeout on command line#7
laverya merged 1 commit intoch2399/support-bundle-categoriesfrom
ch2999/timeout-improvements

Conversation

@laverya
Copy link
Copy Markdown
Contributor

@laverya laverya commented Oct 26, 2017

Allow setting timeouts within specs if they are lower than the global timeout

Allow setting timeouts within specs if they are lower than the global timeout
@laverya laverya merged commit c5e0868 into ch2399/support-bundle-categories Oct 26, 2017
Comment thread plans/byte-source.go
}

data, err := task.Producer(ctx)
useCtx := ctx
Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

why not

if task.Timeout != 0 {
    ctx, _ = context.WithTimeout(ctx, task.Timeout)
}

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Now changed

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants