File tree Expand file tree Collapse file tree
packages/gooddata-sdk/src/gooddata_sdk/catalog
workspace/declarative_model/workspace/analytics_model Expand file tree Collapse file tree Original file line number Diff line number Diff line change 33
44from attrs import define , field
55from gooddata_api_client .model .declarative_notification_channel import DeclarativeNotificationChannel
6+ from gooddata_api_client .model .notification_channel_destination import NotificationChannelDestination
67from gooddata_api_client .model .webhook import Webhook
78
89from gooddata_sdk .catalog .base import Base
910
11+ # The generator collapses the `type` enums of NotificationChannelDestination's oneOf children
12+ # into the last child's single value (IN_PLATFORM), so valid destinations of the other types
13+ # fail client-side validation on both serialization and response parsing. Restore the full set.
14+ NotificationChannelDestination .allowed_values [("type" ,)].update (
15+ {
16+ "WEBHOOK" : "WEBHOOK" ,
17+ "SMTP" : "SMTP" ,
18+ "DEFAULT_SMTP" : "DEFAULT_SMTP" ,
19+ "IN_PLATFORM" : "IN_PLATFORM" ,
20+ }
21+ )
22+
1023# TODO: there is an issue with generated client which causes these two classes to fail
1124# type in gooddata_api_client/model/declarative_notification_channel_destination.py contains only WEBHOOK as valid value
1225# @define(kw_only=True)
Original file line number Diff line number Diff line change 22
33from attrs import define
44from gooddata_api_client .model .declarative_export_definition import DeclarativeExportDefinition
5- from gooddata_api_client .model .declarative_export_definition_request_payload import (
6- DeclarativeExportDefinitionRequestPayload ,
7- )
5+ from gooddata_api_client .model .export_request import ExportRequest
86
97from gooddata_sdk import ExportCustomOverride , ExportSettings
108from gooddata_sdk .catalog .base import Base
@@ -25,8 +23,8 @@ class CatalogDeclarativeExportDefinitionRequestPayload(Base):
2523 dashboard_id : str | None = None
2624
2725 @staticmethod
28- def client_class () -> type [DeclarativeExportDefinitionRequestPayload ]:
29- return DeclarativeExportDefinitionRequestPayload
26+ def client_class () -> type [ExportRequest ]:
27+ return ExportRequest
3028
3129
3230@define (kw_only = True )
You can’t perform that action at this time.
0 commit comments