airflow.providers.ftp.sensors.ftp

Module Contents

Classes

FTPSensor

Waits for a file or directory to be present on FTP.

FTPSSensor

Waits for a file or directory to be present on FTP over SSL.

class airflow.providers.ftp.sensors.ftp.FTPSensor(*, path, ftp_conn_id='ftp_default', fail_on_transient_errors=True, **kwargs)[source]

Bases: airflow.sensors.base.BaseSensorOperator

Waits for a file or directory to be present on FTP.

Parameters
  • path (str) – Remote file or directory path

  • fail_on_transient_errors (bool) – Fail on all errors, including 4xx transient errors. Default True.

  • ftp_conn_id (str) – The ftp connection id reference to run the sensor against.

template_fields: Sequence[str] = ('path',)[source]

Errors that are transient in nature, and where action can be retried

transient_errors = [421, 425, 426, 434, 450, 451, 452][source]
error_code_pattern[source]
poke(context)[source]

Override when deriving this class.

class airflow.providers.ftp.sensors.ftp.FTPSSensor(*, path, ftp_conn_id='ftp_default', fail_on_transient_errors=True, **kwargs)[source]

Bases: FTPSensor

Waits for a file or directory to be present on FTP over SSL.

Was this entry helpful?