diff --git a/docs/content/api/modules.json.gz b/docs/content/api/modules.json.gz index f7cd2bb8e3951..4cd3a4eefdce4 100644 Binary files a/docs/content/api/modules.json.gz and b/docs/content/api/modules.json.gz differ diff --git a/docs/content/api/searchindex.json.gz b/docs/content/api/searchindex.json.gz index d1ac67478eabf..cfb62ce78b37d 100644 Binary files a/docs/content/api/searchindex.json.gz and b/docs/content/api/searchindex.json.gz differ diff --git a/docs/content/api/sections.json.gz b/docs/content/api/sections.json.gz index 342c36a274fd3..88bb67976f532 100644 Binary files a/docs/content/api/sections.json.gz and b/docs/content/api/sections.json.gz differ diff --git a/docs/content/integrations/sigma.mdx b/docs/content/integrations/sigma.mdx index c7e6d5e239ba0..1a0dd25a0d749 100644 --- a/docs/content/integrations/sigma.mdx +++ b/docs/content/integrations/sigma.mdx @@ -102,7 +102,7 @@ from dagster_sigma import ( DagsterSigmaTranslator, SigmaBaseUrl, SigmaOrganization, - SigmaWorkbook, + SigmaWorkbookTranslatorData, load_sigma_asset_specs, ) @@ -117,7 +117,7 @@ sigma_organization = SigmaOrganization( # A translator class lets us customize properties of the built Sigma assets, such as the owners or asset key class MyCustomSigmaTranslator(DagsterSigmaTranslator): - def get_asset_spec(self, data: SigmaWorkbook) -> dg.AssetSpec: + def get_asset_spec(self, data: SigmaWorkbookTranslatorData) -> dg.AssetSpec: # We create the default asset spec using super() default_spec = super().get_asset_spec(data) # we customize the team owner tag for all Sigma assets @@ -125,7 +125,7 @@ class MyCustomSigmaTranslator(DagsterSigmaTranslator): sigma_specs = load_sigma_asset_specs( - sigma_organization, dagster_sigma_translator=MyCustomSigmaTranslator + sigma_organization, dagster_sigma_translator=MyCustomSigmaTranslator() ) defs = dg.Definitions(assets=[*sigma_specs], resources={"sigma": sigma_organization}) ``` diff --git a/examples/docs_snippets/docs_snippets/integrations/sigma/customize-sigma-asset-defs.py b/examples/docs_snippets/docs_snippets/integrations/sigma/customize-sigma-asset-defs.py index c33fcdbce0df0..594fb3fc4cdd9 100644 --- a/examples/docs_snippets/docs_snippets/integrations/sigma/customize-sigma-asset-defs.py +++ b/examples/docs_snippets/docs_snippets/integrations/sigma/customize-sigma-asset-defs.py @@ -2,7 +2,7 @@ DagsterSigmaTranslator, SigmaBaseUrl, SigmaOrganization, - SigmaWorkbook, + SigmaWorkbookTranslatorData, load_sigma_asset_specs, ) @@ -17,14 +17,14 @@ # A translator class lets us customize properties of the built Sigma assets, such as the owners or asset key class MyCustomSigmaTranslator(DagsterSigmaTranslator): - def get_asset_spec(self, data: SigmaWorkbook) -> dg.AssetSpec: + def get_asset_spec(self, data: SigmaWorkbookTranslatorData) -> dg.AssetSpec: # We create the default asset spec using super() - default_spec = super().get_asset_spec(data) # type: ignore + default_spec = super().get_asset_spec(data) # we customize the team owner tag for all Sigma assets return default_spec.replace_attributes(owners=["team:my_team"]) sigma_specs = load_sigma_asset_specs( - sigma_organization, dagster_sigma_translator=MyCustomSigmaTranslator + sigma_organization, dagster_sigma_translator=MyCustomSigmaTranslator() ) defs = dg.Definitions(assets=[*sigma_specs], resources={"sigma": sigma_organization}) diff --git a/python_modules/libraries/dagster-sigma/dagster_sigma/__init__.py b/python_modules/libraries/dagster-sigma/dagster_sigma/__init__.py index 944e51de4e4c2..456c5b7b0bb9b 100644 --- a/python_modules/libraries/dagster-sigma/dagster_sigma/__init__.py +++ b/python_modules/libraries/dagster-sigma/dagster_sigma/__init__.py @@ -12,7 +12,9 @@ from dagster_sigma.translator import ( DagsterSigmaTranslator as DagsterSigmaTranslator, SigmaDataset as SigmaDataset, + SigmaDatasetTranslatorData as SigmaDatasetTranslatorData, SigmaWorkbook as SigmaWorkbook, + SigmaWorkbookTranslatorData as SigmaWorkbookTranslatorData, ) from dagster_sigma.version import __version__