databricks-sdk-py icon indicating copy to clipboard operation
databricks-sdk-py copied to clipboard

[ISSUE] Newly required cfg parameter in ApiClient no longer matches Databricks documentation

Open jdavidheiser opened this issue 7 months ago • 0 comments

Description The docs at https://docs.databricks.com/aws/en/files/workspace instruct users to call client = ApiClient() because older versions of the SDK created a default config. In https://github.com/databricks/databricks-sdk-py/pull/785, a required cfg parameter was added, so ApiClient no longer correctly assumes a default configuration when running in a notebook (like WorkspaceClient does).

Reproduction Try to run the notebook in the linked Databricks docs. It will fail with

TypeError: ApiClient.__init__() missing 1 required positional argument: 'cfg'

Expected behavior Calling ApiClient from a notebook should automatically do the correct thing.

Is it a regression? Yes

Debug Logs NA

Other Information DBR 16.1, SDK version 0.54

Additional context NA

jdavidheiser avatar May 24 '25 13:05 jdavidheiser