scr-oath commented on issue #30229:
URL: https://github.com/apache/airflow/issues/30229#issuecomment-1665895969

   FWIW, I tried this simple sensor code - this use case is similar to how 
oozie workflows/coordinators can wait for data to exist for their schdeule… 
   
   I was surprised to see that context is not injected into `@task.sensor` is 
this by design or a separate issue that should be filed?
   
   ```python
   @dag(
       schedule='@daily',
       start_date=pendulum.datetime(2023, 1, 1, tz="UTC"),
       tags=['triggering', 'datasets']
   )
   def ds_consumer():
       @task.sensor(poke_interval=60, timeout=86400, mode='reschedule')
       def wait_for_upstream(ds=None) -> PokeReturnValue:
           assert ds is not None
           # ... Hits the assertion ^
   ```


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]

Reply via email to