Browse Source

Fix python operators: Also return a `DoraStatus` for non-input events

tags/v0.2.0-candidate
Philipp Oppermann 3 years ago
parent
commit
acf4a1dc52
Failed to extract signature
2 changed files with 2 additions and 0 deletions
  1. +1
    -0
      examples/python-operator-dataflow/object_detection.py
  2. +1
    -0
      examples/python-operator-dataflow/plot.py

+ 1
- 0
examples/python-operator-dataflow/object_detection.py View File

@@ -29,6 +29,7 @@ class Operator:
) -> DoraStatus:
if dora_event["type"] == "INPUT":
return self.on_input(dora_event, send_output)
return DoraStatus.CONTINUE

def on_input(
self,


+ 1
- 0
examples/python-operator-dataflow/plot.py View File

@@ -33,6 +33,7 @@ class Operator:
) -> DoraStatus:
if dora_event["type"] == "INPUT":
return self.on_input(dora_event, send_output)
return DoraStatus.CONTINUE

def on_input(
self,


Loading…
Cancel
Save