Are there any example of how to use Flytekit.Senso...
# ask-the-community
Are there any example of how to use Flytekit.Sensor ?
Copy code
from flytekit.sensor.file_sensor import FileSensor
from flytekit import task, workflow

sensor = FileSensor(name="test_sensor")
def t1():

def wf():
    sensor(path="/tmp/123") >> t1()

if __name__ == "__main__":
This is the example about The Sensor extend BaseSensor. I have read the git i saw about SensorEngine Which registed to Agent. Is this different than base_sensor
Yes it is different
You can print the value in sensor engine, and you will know how it works.
Workflow[flytesnacks:development:<|>] failed. RuntimeExecutionError: max number of system retry attempts [11/10] exhausted. Last known status message: failed at Node[n0]. RuntimeExecutionError: failed during plugin execution, caused by: failed to execute handle for plugin [container]: [BadTaskSpecification] invalid TaskSpecification, unable to determine Pod configuration
I catch this error when I run your above file test sensor script on remote. For some results, the sensor on remote can attempts muximum 10 times, not infinity. I am dev on flyte demo sandbox enviroment( flyte demo start). How to fix this
or maybe 10 attemps for another bugs
maybe it's about config map cc @Kevin Su
I’m writing to the doc, sorry
did you deploy an agent in your cluster?