{"id":20897,"library":"acryl-datahub-actions","title":"DataHub Actions","description":"An action framework for reacting to real-time changes in DataHub, including entity change events and metadata change sync. Current version is 1.5.0.14, but the GitHub releases lag behind; the main git version is v0.2.1. The library is actively maintained by Acryl Data.","status":"active","version":"1.5.0.14","language":"python","source_language":"en","source_url":"https://github.com/acryldata/datahub-actions","tags":["datahub","actions","event-driven","metadata","acryl"],"install":[{"cmd":"pip install acryl-datahub-actions","lang":"bash","label":"default"},{"cmd":"pip install 'acryl-datahub-actions[all]'","lang":"bash","label":"with all extras"}],"dependencies":[{"reason":"Core DataHub SDK; required for event types","package":"acryl-datahub","optional":false},{"reason":"Kafka consumer for event ingestion","package":"confluent-kafka","optional":false},{"reason":"Retry logic; missing in v0.1.8","package":"tenacity","optional":false}],"imports":[{"note":"Deep nested import; avoid using top-level imports","wrong":"","symbol":"MetadataChangeSyncAction","correct":"from datahub_actions.action.metadata_change_sync.metadata_change_sync_action import MetadataChangeSyncAction"},{"note":"Action base class is not exported from package root; must import from submodule","wrong":"from datahub_actions import Action","symbol":"Action","correct":"from datahub_actions.action.action import Action"},{"note":"Correct import from pipeline module","wrong":"","symbol":"Pipeline","correct":"from datahub_actions.pipeline import Pipeline"}],"quickstart":{"code":"from datahub_actions.pipeline import Pipeline\nfrom datahub_actions.source.datahub_source import DatahubSource\nfrom datahub_actions.sink.datahub_sink import DatahubSink\nimport os\n\n# Configure a simple pipeline that logs events\npipeline = Pipeline(\n    source=DatahubSource(\n        host=os.environ.get('DATAHUB_GMS_HOST', 'http://localhost:8080'),\n        token=os.environ.get('DATAHUB_GMS_TOKEN', '')\n    ),\n    sink=DatahubSink(\n        host=os.environ.get('DATAHUB_GMS_HOST', 'http://localhost:8080'),\n        token=os.environ.get('DATAHUB_GMS_TOKEN', '')\n    ),\n    actions=[]\n)\npipeline.run()","lang":"python","description":"Minimal pipeline connecting DataHub source to DataHub sink with no actions."},"warnings":[{"fix":"Upgrade to v0.1.10 or later, or manually install tenacity: pip install tenacity","message":"The v0.1.8 release has a known issue: missing tenacity dependency causing UnboundVariable exceptions.","severity":"deprecated","affected_versions":"0.1.8"},{"fix":"Use from datahub_actions.action.action import Action instead of from datahub_actions import Action","message":"The v0.2.0 release restructured imports; Action base class moved from top-level to submodule.","severity":"breaking","affected_versions":">=0.2.0"},{"fix":"Inspect the package's submodules for correct paths, e.g., datahub_actions.action.metadata_change_sync.","message":"Many action classes require deep nested import paths; not exported from package root.","severity":"gotcha","affected_versions":">=0.1.0"},{"fix":"Use DatahubSource and DatahubSink (from datahub_actions.source and .sink).","message":"The old pattern using DatahubRestSink and DatahubRestSource is deprecated in favor of DatahubSink/DatahubSource.","severity":"deprecated","affected_versions":">=0.2.0"}],"env_vars":null,"last_verified":"2026-04-27T00:00:00.000Z","next_check":"2026-07-26T00:00:00.000Z","problems":[{"fix":"pip install acryl-datahub-actions","cause":"Package not installed or installed with different name.","error":"ModuleNotFoundError: No module named 'datahub_actions'"},{"fix":"from datahub_actions.action.action import Action","cause":"Action class not exposed at package root as of v0.2.0+.","error":"ImportError: cannot import name 'Action' from 'datahub_actions'"},{"fix":"Set the missing variable or upgrade to >=v0.1.10. For v0.1.8, also install tenacity.","cause":"Environment variable not defined in action config, and tenacity retry may be missing in v0.1.8.","error":"UnboundVariable: The environment variable 'MY_VAR' is not set."},{"fix":"pip install tenacity or upgrade to v0.1.10+","cause":"Missing dependency in v0.1.7/v0.1.8.","error":"ModuleNotFoundError: No module named 'tenacity'"}],"ecosystem":"pypi","meta_description":null,"install_score":null,"install_tag":null,"quickstart_score":null,"quickstart_tag":null}