Data review#
A data review runs a published checklist against a run. Each place a check fails becomes an event for an engineer to review.
For checking live data as it arrives, see Trigger alerts.
Connect the client#
This guide assumes you have installed the client and setup your API keys.
from nominal.core import NominalClient
client = NominalClient.from_profile("default")
Run checklists against runs#
data_review_builder() returns a DataReviewBuilder.
Add one execute_checklist() per run and checklist pair, then start them all with initiate():
builder = client.data_review_builder()
builder.execute_checklist("<RUN_RID>", "<CHECKLIST_RID>", commit="<COMMIT_SHA>") # pin a version
builder.execute_checklist("<OTHER_RUN_RID>", "<CHECKLIST_RID>") # latest version
builder.add_integration("<INTEGRATION_RID>") # optional: notify when checks fail
for review in builder.initiate():
print(review.nominal_url, len(review.get_events()))
Copy checklist RIDs and commit SHAs from the Checklists page.
For a run with several assets, pass asset= to choose the one to review.
initiate waits for the reviews to finish by default, but doesn’t wait for notifications.
Pass wait_for_completion=False to return immediately, then call poll_for_completion() on each review.
Notifications support Slack, Opsgenie and webhook integrations.
Read results later#
review = client.get_data_review("<DATA_REVIEW_RID>")
events = review.get_events()
search_data_reviews() and search_data_reviews() find reviews by run or asset.
To review the results in the UI, see Data review.