yevsh commented on issue #17395:
URL: https://github.com/apache/airflow/issues/17395#issuecomment-893348259


   very simple python that I just created.
   And placed it in dags folder.
   
   ```
   
   from airflow import DAG
   from datetime import timedelta
   from airflow.utils.dates import days_ago
   from dateutil.relativedelta import *
   from datetime import datetime
   from airflow.models import BaseOperator
   from airflow.utils.decorators import apply_defaults
   
   
   class Test(BaseOperator):
       @apply_defaults
       def __init__(
           self,
           *args, **kwargs):
   
           super(Test, self).__init__(*args, **kwargs)
   
   
       def execute(self, context):
           self.log.info("Running")
   
   
   default_args = {
       'owner': 'airflow',
       'depends_on_past': False,
       'max_active_runs': 1,
       'retries': 0,
       'retry_delay': timedelta(0, 3000),
       'is_paused_upon_creation': False
   
   }
   
   
   dag = DAG(
       'TEST900',
       default_args=default_args,
       schedule_interval=relativedelta(hours=+1),
       start_date= datetime(2021,1,3),
       catchup=False,
       is_paused_upon_creation=False,
   )
   
   t1 = Test(
       task_id='Prd',
   )
   
   
   t1
   ```


-- 
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