diff --git a/python_modules/dagster-ext/dagster_ext/__init__.py b/python_modules/dagster-ext/dagster_ext/__init__.py index 38366a039aeaf..323c3877e90a4 100644 --- a/python_modules/dagster-ext/dagster_ext/__init__.py +++ b/python_modules/dagster-ext/dagster_ext/__init__.py @@ -39,6 +39,9 @@ # ##### PROTOCOL # ######################## +# This represents the version of the protocol, rather than the version of the package. It must be +# manually updated whenever there are changes to the protocol. +PROTOCOL_VERSION = "0.1" ExtExtras = Mapping[str, Any] ExtParams = Mapping[str, Any] @@ -64,6 +67,7 @@ def _param_name_to_env_key(key: str) -> str: class ExtMessage(TypedDict): + __dagster_ext_version: str method: str params: Optional[Mapping[str, Any]] @@ -677,7 +681,7 @@ def __init__( self._materialized_assets: set[str] = set() def _write_message(self, method: str, params: Optional[Mapping[str, Any]] = None) -> None: - message = ExtMessage(method=method, params=params) + message = ExtMessage(__dagster_ext_version=PROTOCOL_VERSION, method=method, params=params) self._message_channel.write_message(message) # ########################