Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -104,14 +104,14 @@ class CatalogDeclarativeDataSource(Base):
parameters: Optional[list[CatalogParameter]] = None
decoded_parameters: Optional[list[CatalogParameter]] = None
permissions: list[CatalogDeclarativeDataSourcePermission] = attr.field(factory=list)
client_id: Optional[str] = None

def to_test_request(
self,
password: Optional[str] = None,
token: Optional[str] = None,
private_key: Optional[str] = None,
private_key_passphrase: Optional[str] = None,
client_id: Optional[str] = None,
client_secret: Optional[str] = None,
) -> TestDefinitionRequest:
kwargs: dict[str, Any] = {"schema": self.schema}
Expand All @@ -125,8 +125,6 @@ def to_test_request(
kwargs["private_key"] = private_key
if private_key_passphrase is not None:
kwargs["private_key_passphrase"] = private_key
if client_id is not None:
kwargs["client_id"] = client_id
if client_secret is not None:
kwargs["client_secret"] = client_secret
return TestDefinitionRequest(type=self.type, url=self.url, **kwargs)
Expand All @@ -147,7 +145,6 @@ def to_api(
token: Optional[str] = None,
private_key: Optional[str] = None,
private_key_passphrase: Optional[str] = None,
client_id: Optional[str] = None,
client_secret: Optional[str] = None,
) -> DeclarativeDataSource:
dictionary = self._get_snake_dict()
Expand All @@ -159,8 +156,6 @@ def to_api(
dictionary["private_key"] = private_key
if private_key_passphrase is not None:
dictionary["private_key_passphrase"] = private_key_passphrase
if client_id is not None:
dictionary["client_id"] = client_id
if client_secret is not None:
dictionary["client_secret"] = client_secret
return self.client_class().from_dict(dictionary)
Expand Down
Loading