Logo
Explore Help
Register Sign In
yujunjun/datahub
2
0
Fork 0
You've already forked datahub
mirror of https://github.com/datahub-project/datahub.git synced 2025-07-04 07:34:44 +00:00
Code Issues Packages Projects Releases Wiki Activity
datahub/metadata-ingestion/examples/library/run_assertion.py

21 lines
498 B
Python
Raw Permalink Normal View History

docs(): Adding API docs for incidents, operations, and assertions (#10522) Co-authored-by: John Joyce <john@Johns-MacBook-Pro.local> Co-authored-by: John Joyce <john@ip-10-0-0-48.us-west-2.compute.internal> Co-authored-by: John Joyce <john@Johns-MBP-432.lan> Co-authored-by: John Joyce <john@ip-192-168-1-200.us-west-2.compute.internal> Co-authored-by: John Joyce <john@Johns-MBP.lan>
2024-06-06 14:05:44 -07:00
import logging
from datahub.ingestion.graph.client import DatahubClientConfig, DataHubGraph
log = logging.getLogger(__name__)
graph = DataHubGraph(
config=DatahubClientConfig(
server="http://localhost:8080",
)
)
assertion_urn = "urn:li:assertion:6e3f9e09-1483-40f9-b9cd-30e5f182694a"
# Run the assertion
assertion_result = graph.run_assertion(urn=assertion_urn, save_result=True)
log.info(
dev: remove black in favor of ruff for formatting (#12378)
2025-01-18 15:06:20 +05:30
f"Assertion result (SUCCESS / FAILURE / ERROR): {assertion_result.get('type')}"
docs(): Adding API docs for incidents, operations, and assertions (#10522) Co-authored-by: John Joyce <john@Johns-MacBook-Pro.local> Co-authored-by: John Joyce <john@ip-10-0-0-48.us-west-2.compute.internal> Co-authored-by: John Joyce <john@Johns-MBP-432.lan> Co-authored-by: John Joyce <john@ip-192-168-1-200.us-west-2.compute.internal> Co-authored-by: John Joyce <john@Johns-MBP.lan>
2024-06-06 14:05:44 -07:00
)
Reference in New Issue Copy Permalink
Powered by Gitea Version: 1.23.5 Page: 319ms Template: 5ms
English
Bahasa Indonesia Deutsch English Español Français Gaeilge Italiano Latviešu Magyar nyelv Nederlands Polski Português de Portugal Português do Brasil Suomi Svenska Türkçe Čeština Ελληνικά Български Русский Українська فارسی മലയാളം 日本語 简体中文 繁體中文(台灣) 繁體中文(香港) 한국어
Licenses API