A set of native Airflow operators for Anomalo
These operators were created and tested with
- Python 3.8-3.10
- Airflow 2.3+
- Anomalo python client 0.0.7
pip install apache-airflow-providers-anomalo
You can validate that it is correctly installed by running airflow providers list
on the command line and seeing if apache-airflow-providers-anomalo
is a listed providers package.
From the airflow UI, go to Admin > Connections and hit the +
button at the top to add a new connection.
From the "Connection Type" drop down, select "Anomalo".
Then fill in the fields for "Connection Id" (anomalo-default
is the default connection id), "Host", and "API Secret Token".
-
Obtain Anomalo table name from GUI. For example would be
public-bq.covid19_nyt.us_counties
-
This package includes 3 different operators. You can find documentation for them on the operator code itself.
- Run checks Operator:
airflow.providers.anomalo.operators.anomalo.AnomaloRunCheckOperator
- Job Sensor
airflow.providers.anomalo.sensors.anomalo.AnomaloJobCompleteSensor
- Validate table checks:
airflow.providers.anomalo.operators.anomalo.AnomaloPassFailOperator
- Run checks Operator:
-
See
example_anomalo.py
for usage example
To release a new version to PyPi, you will need to
- Configure your pypi token by running:
poetry config pypi-token.pypi [token here]
The token can be found in the AWS secrets manager - Bump the version number in pyproject.toml. Make sure that this change is committed.
- run
poetry publish --build