airflow/models/dag.py
def next_dagrun_info(
        self,
        last_automated_dagrun: Union[None, datetime, DataInterval],
        *,
        restricted: bool = True,
    ) -> Optional[DagRunInfo]:
        """Get information about the next DagRun of this dag after ``date_last_automated_dagrun``.

        This calculates what time interval the next DagRun should operate on
        (its execution date), and when it can be scheduled, , according to the
        dag's timetable, start_date, end_date, etc. This doesn't check max
        active run or any other "max_active_tasks" type limits, but only
        performs calculations based on the various date and interval fields of
        this dag and its tasks.

        :param date_last_automated_dagrun: The ``max(execution_date)`` of
            existing "automated" DagRuns for this dag (scheduled or backfill,
            but not manual).
        :param restricted: If set to *False* (default is *True*), ignore
            ``start_date``, ``end_date``, and ``catchup`` specified on the DAG
            or tasks.
        :return: DagRunInfo of the next dagrun, or None if a dagrun is not
            going to be scheduled.
        """
        # Never schedule a subdag. It will be scheduled by its parent dag.
        if self.is_subdag:
            return None
        if isinstance(last_automated_dagrun, datetime):
            warnings.warn(
                "Passing a datetime to DAG.next_dagrun_info is deprecated. Use a DataInterval instead.",
                DeprecationWarning,
                stacklevel=2,
            )
            data_interval = self.infer_automated_data_interval(
                timezone.coerce_datetime(last_automated_dagrun)
            )
        else:
            data_interval = last_automated_dagrun
        if restricted:
            restriction = self._time_restriction
        else:
            restriction = TimeRestriction(earliest=None, latest=None, catchup=True)
        try:
            info = self.timetable.next_dagrun_info(
                last_automated_data_interval=data_interval,
                restriction=restriction,
            )
        except Exception:
            self.log.exception(
                "Failed to fetch run info after data interval %s for DAG %r",
                data_interval,
                self.dag_id,
            )
            info = None
        return info
Get information about the next DagRun of this dag after ``date_last_automated_dagrun``.

        This calculates what time interval the next DagRun should operate on
        (its execution date), and when it can be scheduled, , according to the
        dag's timetable, start_date, end_date, etc. This doesn't check max
        active run or any other "max_active_tasks" type limits, but only
        performs calculations based on the various date and interval fields of
        this dag and its tasks.

        :param date_last_automated_dagrun: The ``max(execution_date)`` of
            existing "automated" DagRuns for this dag (scheduled or backfill,
            but not manual).
        :param restricted: If set to *False* (default is *True*), ignore
            ``start_date``, ``end_date``, and ``catchup`` specified on the DAG
            or tasks.
        :return: DagRunInfo of the next dagrun, or None if a dagrun is not
            going to be scheduled.
        
Get information about the next DagRun of this dag after ``date_last_automated_dagrun``.
This calculates what time interval the next DagRun should operate on
(its execution date), and when it can be scheduled, , according to the
dag's timetable, start_date, end_date, etc. This doesn't check max
active run or any other "max_active_tasks" type limits, but only
performs calculations based on the various date and interval fields of
this dag and its tasks.
Get information about the next DagRun of this dag after ` ` date_last_automated_dagrun ` ` . This calculates what time interval the next DagRun should operate on ( its execution date ) and when it can be scheduled according to the dag ' s timetable start_date end_date etc . This doesn ' t check max active run or any other " max_active_tasks " type limits but only performs calculations based on the various date and interval fields of this dag and its tasks .
def next_dagrun_info(
        self,
        last_automated_dagrun: Union[None, datetime, DataInterval],
        *,
        restricted: bool = True,
    ) -> Optional[DagRunInfo]:
        if self.is_subdag:
            return None
        if isinstance(last_automated_dagrun, datetime):
            warnings.warn(
                "Passing a datetime to DAG.next_dagrun_info is deprecated. Use a DataInterval instead.",
                DeprecationWarning,
                stacklevel=2,
            )
            data_interval = self.infer_automated_data_interval(
                timezone.coerce_datetime(last_automated_dagrun)
            )
        else:
            data_interval = last_automated_dagrun
        if restricted:
            restriction = self._time_restriction
        else:
            restriction = TimeRestriction(earliest=None, latest=None, catchup=True)
        try:
            info = self.timetable.next_dagrun_info(
                last_automated_data_interval=data_interval,
                restriction=restriction,
            )
        except Exception:
            self.log.exception(
                "Failed to fetch run info after data interval %s for DAG %r",
                data_interval,
                self.dag_id,
            )
            info = None
        return info
def next_dagrun_info ( self , last_automated_dagrun : Union [ None , datetime , DataInterval ] , * , restricted : bool = True , ) -> Optional [ DagRunInfo ] : if self . is_subdag : return None if isinstance ( last_automated_dagrun , datetime ) : warnings . warn ( "Passing a datetime to DAG.next_dagrun_info is deprecated. Use a DataInterval instead." , DeprecationWarning , stacklevel = 2 , ) data_interval = self . infer_automated_data_interval ( timezone . coerce_datetime ( last_automated_dagrun ) ) else : data_interval = last_automated_dagrun if restricted : restriction = self . _time_restriction else : restriction = TimeRestriction ( earliest = None , latest = None , catchup = True ) try : info = self . timetable . next_dagrun_info ( last_automated_data_interval = data_interval , restriction = restriction , ) except Exception : self . log . exception ( "Failed to fetch run info after data interval %s for DAG %r" , data_interval , self . dag_id , ) info = None return info
Get information about the next DagRun of this dag after ``date_last_automated_dagrun``.
Get information about the next DagRun of this dag after ` ` date_last_automated_dagrun ` ` .
"""Get information about the next DagRun of this dag after ``date_last_automated_dagrun``.

        This calculates what time interval the next DagRun should operate on
        (its execution date), and when it can be scheduled, , according to the
        dag's timetable, start_date, end_date, etc. This doesn't check max
        active run or any other "max_active_tasks" type limits, but only
        performs calculations based on the various date and interval fields of
        this dag and its tasks.

        :param date_last_automated_dagrun: The ``max(execution_date)`` of
            existing "automated" DagRuns for this dag (scheduled or backfill,
            but not manual).
        :param restricted: If set to *False* (default is *True*), ignore
            ``start_date``, ``end_date``, and ``catchup`` specified on the DAG
            or tasks.
        :return: DagRunInfo of the next dagrun, or None if a dagrun is not
            going to be scheduled.
        """ # Never schedule a subdag. It will be scheduled by its parent dag.
DagRunInfo of the next dagrun, or None if a dagrun is not
going to be scheduled.
DagRunInfo of the next dagrun or None if a dagrun is not going to be scheduled .
self
last_automated_dagrun
Union[None, datetime, DataInterval]
restricted
bool
If set to *False* (default is *True*), ignore
``start_date``, ``end_date``, and ``catchup`` specified on the DAG
or tasks.
If set to * False * ( default is * True * ) ignore ` ` start_date ` ` ` ` end_date ` ` and ` ` catchup ` ` specified on the DAG or tasks .
date_last_automated_dagrun
The ``max(execution_date)`` of
existing "automated" DagRuns for this dag (scheduled or backfill,
but not manual).
The ` ` max ( execution_date ) ` ` of existing " automated " DagRuns for this dag ( scheduled or backfill but not manual ) .