Created
January 31, 2024 18:55
-
-
Save cra/2ecaef94121bcb9b41d71ade0d233c5e to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import pendulum | |
from airflow.decorators import dag | |
from airflow.operators.empty import EmptyOperator | |
from airflow.providers.postgres.operators.postgres import PostgresOperator | |
@dag(schedule_interval=None, start_date=pendulum.datetime(2020, 11, 1), catchup=False) | |
def piggy_peter_psqlop_dag(): | |
start = EmptyOperator(task_id='start') | |
end = EmptyOperator(task_id='end', trigger_rule='none_failed') | |
task = PostgresOperator( | |
task_id='piu_piu', | |
postgres_conn_id='ekaterina_shrimpsizepostgres', | |
sql='sql/wtf.sql', | |
) | |
start >> task >> end | |
_ = piggy_peter_psqlop_dag() |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
env:
вывод от PostgresOperator в XCom самой таски

в логах вот так выглядит:
