Skip to content

[ISSUE] spark.conf.get raises Exception #1112

@Julian-J-S

Description

@Julian-J-S

Description
spark.conf.get raises instead of returning None or a default value according to the documentation.

Reproduction

from databricks.sdk.runtime import spark

spark.conf.get("xxxxx")  # -> Error instead of `None`
spark.conf.get("xxxxx", "my_default")  # -> Error instead of "my_default"

Expected behavior
According to the docs it should NOT raise but either return None or the provided default value.
Happens locally with databricks sdk but also in the databricks workspace in a notebook.

Debug Logs

AnalysisException: [CONFIG_NOT_AVAILABLE] Configuration xxxxx is not available. SQLSTATE: 42K0I

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions