Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fix: avoid global mutation in BigQueryOptions.client_endpoints_override #1280

Open
wants to merge 2 commits into
base: main
Choose a base branch
from
Open
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
6 changes: 5 additions & 1 deletion bigframes/_config/bigquery_options.py
Original file line number Diff line number Diff line change
Expand Up @@ -91,7 +91,7 @@ def __init__(
skip_bq_connection_check: bool = False,
*,
ordering_mode: Literal["strict", "partial"] = "strict",
client_endpoints_override: dict = {},
client_endpoints_override: Optional[dict] = None,
):
self._credentials = credentials
self._project = project
Expand All @@ -104,6 +104,10 @@ def __init__(
self._session_started = False
# Determines the ordering strictness for the session.
self._ordering_mode = _validate_ordering_mode(ordering_mode)

if client_endpoints_override is None:
client_endpoints_override = {}

self._client_endpoints_override = client_endpoints_override

@property
Expand Down
Loading