This content is also available at learn.palantir.com ↗ and is presented here for accessibility purposes.
You will need to add references to a designated library in order to use the expectations framework in your code.
flight_alerts_logic
code repository in your /Datasource Project: Flight Alerts
folder.yourName/feature/primary_key_check
.transforms-expectations
appears in the installed list. If it is not, search for it and add it using the workflow you learned in the previous tutorial Monitoring Data Pipeline Health.flight_alerts_clean.py
transform file in the code editor.transforms.api
to include a new, case-sensitive item: Check
.transform.api
imports, add a new import statement: from transforms import expectations as E
. Once complete, your import statements in this transform file should resemble the block below:from pyspark.sql import functions as F
from transforms.api import transform_df, Input, Output, Check
from transforms import expectations as E
Review this introductory article to review relevant terms essential to successful use of the Data Expectations framework. There is no need to follow the links under the Learn More heading for now.