greatexpectationslabs / ge_tutorials

Learn how to add data validation and documentation to a data pipeline built with dbt and Airflow.
167 stars 84 forks source link

Add example custom expectation (using v3 api) #21

Closed jdimatteo closed 3 years ago

jdimatteo commented 3 years ago

Adding example following v3 api documentation How to create custom Expectations and How to Create Renderers for Custom Expectations.

The example can be run with run_checkpoint_with_custom_expectation.py from the directory getting_started_tutorial_final_v3_api, e.g.

getting_started_tutorial_final_v3_api$ python run_checkpoint_with_custom_expectation.py 

This generates data docs like the following: image

Note that the second expectation "values must always be greater than..." is the custom expectation.

jdimatteo commented 3 years ago

Hi @spbail can you please review this? @jcampbell merged some references to this example with https://github.com/great-expectations/great_expectations/pull/2847 and it would be good to merge so the Great Expecations documentation links to this works

jcampbell commented 3 years ago

@jdimatteo --> I'm happy to merge here. Thanks again!

jdimatteo commented 3 years ago

Thanks for the PR review!