https://dagster.io/ logo
#ask-community
Title
# ask-community
v

vinesh nukala

06/15/2023, 7:37 PM
Hello, is there any way to run arbitrary code when a sensor run fails? Suppose for example I have the following sensor code:
Copy code
@sensor(job=test_job)
def test_sensor(default_status=DefaultSensorStatus.RUNNING):
    raise RuntimeError ("test_error")
    return RunRequest(run_config=run_config)
Given the raise error the sensor will never succeeded, is there any way to run code to say alert a user that their sensor is failing, without modifying the actually code run under the sensor function?
v

vinesh nukala

06/15/2023, 7:54 PM
Thanks!
2 Views