Skip to content

Commit

Permalink
Attempt to work around RuntimeError: UNEXPECTED COMMIT - THIS WILL BR…
Browse files Browse the repository at this point in the history
…EAK HA LOCKS
  • Loading branch information
tatiana committed Dec 20, 2024
1 parent 41a9293 commit 47fb46c
Showing 1 changed file with 5 additions and 1 deletion.
6 changes: 5 additions & 1 deletion cosmos/listeners/dag_run_listener.py
Original file line number Diff line number Diff line change
Expand Up @@ -47,8 +47,12 @@ def uses_cosmos(dag: DAG) -> bool:
return bool(is_cosmos_dag(dag) or total_cosmos_task_groups(dag) or total_cosmos_tasks(dag))


from airflow.utils.session import provide_session


@provide_session
@hookimpl
def on_dag_run_success(dag_run: DagRun, msg: str) -> None:
def on_dag_run_success(dag_run: DagRun, msg: str, session=None) -> None:

logger.info(f"dir: {dir(dag_run.dag)}")
logger.info("The on_dag_run_success was called")
Expand Down

0 comments on commit 47fb46c

Please sign in to comment.