Skip to content

Commit

Permalink
Merge pull request #2157 from rafrafek/patch-1
Browse files Browse the repository at this point in the history
Avoid shadowing important built-ins in the example code
  • Loading branch information
k8s-ci-robot authored Nov 27, 2024
2 parents 3ae5fbb + ee5b9e2 commit 98a5be8
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions kubernetes/base/watch/watch.py
Original file line number Diff line number Diff line change
Expand Up @@ -152,8 +152,8 @@ def stream(self, func, *args, **kwargs):
v1 = kubernetes.client.CoreV1Api()
watch = kubernetes.watch.Watch()
for e in watch.stream(v1.list_namespace, resource_version=1127):
type = e['type']
object = e['object'] # object is one of type return_type
type_ = e['type']
object_ = e['object'] # object is one of type return_type
raw_object = e['raw_object'] # raw_object is a dict
...
if should_stop:
Expand Down

0 comments on commit 98a5be8

Please sign in to comment.