diff --git a/.gitignore b/.gitignore new file mode 100644 index 0000000..bee8a64 --- /dev/null +++ b/.gitignore @@ -0,0 +1 @@ +__pycache__ diff --git a/etcd_wrapper.py b/etcd_wrapper.py index 4620e84..7c86771 100644 --- a/etcd_wrapper.py +++ b/etcd_wrapper.py @@ -45,4 +45,8 @@ class Etcd3Wrapper(object): def watch_prefix(self, *args, value_in_json=False, **kwargs): r, _ = self.client.watch_prefix(*args, **kwargs) for event in r: - yield EtcdEntry(event, event.value, value_in_json=value_in_json) + # if e.value is None don't propagate its value + if event.value is None: + continue + event = EtcdEntry(event, event.value, value_in_json=value_in_json) + yield event \ No newline at end of file