Databricks (Legacy CLI Library)

0.2 · abandoned · verified Fri Apr 10

This is an outdated Python library for interacting with Databricks, primarily as a command-line interface. Its last release was in 2017 (version 0.2), and it has been superseded by the `databricks-cli` and more recently the `databricks-sdk` for programmatic API access. Users seeking modern Databricks integration should use the `databricks-sdk` or `databricks-sql-connector` libraries.

Warnings

Install

Quickstart

The `databricks` library (v0.2) is primarily a command-line utility, and its direct programmatic Python API is not well-documented or intended for modern use. The quickstart above provides examples for the recommended modern alternatives: `databricks-sdk` and `databricks-sql-connector`.

# This package (databricks==0.2) is a very old command-line utility.
# Direct programmatic Python usage is not well documented or supported.
#
# For modern Databricks API interactions, use databricks-sdk:
# from databricks.sdk import WorkspaceClient
# w = WorkspaceClient()
# for c in w.clusters.list():
#     print(c.cluster_name)
#
# For Databricks SQL connectivity, use databricks-sql-connector:
# from databricks.sql import connect
# with connect(server_hostname=os.environ.get('DATABRICKS_SERVER_HOSTNAME'),
#              http_path=os.environ.get('DATABRICKS_HTTP_PATH'),
#              access_token=os.environ.get('DATABRICKS_TOKEN')) as connection:
#     with connection.cursor() as cursor:
#         cursor.execute('SELECT 1')
#         print(cursor.fetchall())

view raw JSON →