Skip to content

Commit

Permalink
c
Browse files Browse the repository at this point in the history
  • Loading branch information
nameexhaustion committed Jan 31, 2025
1 parent 61b6e1d commit dcc2d34
Showing 1 changed file with 4 additions and 2 deletions.
6 changes: 4 additions & 2 deletions py-polars/polars/catalog.py
Original file line number Diff line number Diff line change
Expand Up @@ -469,12 +469,14 @@ def _get_databricks_token(cls) -> str:


class CatalogCredentialProvider:
def __init__(self, catalog: Catalog, table_id: str, *, write: bool):
"""Retrieves credentials from the Unity catalog temporary credentials API."""

def __init__(self, catalog: Catalog, table_id: str, *, write: bool) -> None:
self.catalog = catalog
self.table_id = table_id
self.write = write

def __call__(self) -> CredentialProviderFunctionReturn:
def __call__(self) -> CredentialProviderFunctionReturn: # noqa: D102
creds, _, expiry = self.catalog._get_table_credentials(
self.table_id, write=self.write
)
Expand Down

0 comments on commit dcc2d34

Please sign in to comment.