feat: implement proper context in scope methods#1575
Conversation
✅ Deploy Preview for kubernetes-sigs-cluster-api-gcp ready!
To edit notification comments on pull requests, go to your Netlify project configuration. |
|
[APPROVALNOTIFIER] This PR is APPROVED This pull-request has been approved by: salasberryfin The full list of commands accepted by this bot can be found here. The pull request process is described here DetailsNeeds approval from an approver in each of these files:
Approvers can indicate their approval by writing |
Signed-off-by: Carlos Salas <carlos.salas@suse.com>
e66056a to
f6f92ee
Compare
|
PR needs rebase. DetailsInstructions for interacting with me using PR comments are available here. If you have questions or suggestions related to my behavior, please file an issue against the kubernetes-sigs/prow repository. |
|
The Kubernetes project currently lacks enough contributors to adequately respond to all PRs. This bot triages PRs according to the following rules:
You can:
Please send feedback to sig-contributor-experience at kubernetes/community. /lifecycle stale |
/kind feature
What this PR does / why we need it:
As discussed in #1506 (comment) there's no proper context in place for scope methods and using
context.TODO()is not a valid solution as it's only expected to be used temporarily, for testing or in non-production projects. Effectively this is simply a workaround for passing a nil value to functions that require a context object but it just won't ever timeout.This PR tries to implement proper context to scope methods. I think I updated all of them, but feel free to call me out on any missing occurrences of
context.TODO().Which issue(s) this PR fixes:
Fixes #1573
Special notes for your reviewer:
No changes are applied to testing files where
context.TODO()is still used and should be considered a valid solution for simpler context management.TODOs:
Release note: