Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Appearance settings
This repository was archived by the owner on May 7, 2026. It is now read-only.

Commit 4489687

Browse filesBrowse files
authored
fix: Update max_instances default to reflect actual value (#2302)
The default maximum instances for cloud functions is 100, not 0. Updated the `expected_max_instances` in the `parametrize` decorator to 100 for the 'no-set' and 'set-None' test cases to accurately reflect the runtime behavior. Thank you for opening a Pull Request! Before submitting your PR, there are a few things you can do to make sure it goes smoothly: - [ ] Make sure to open an issue as a [bug/issue](https://github.com/googleapis/python-bigquery-dataframes/issues/new/choose) before writing your code! That way we can discuss the change, evaluate designs, and agree on the general idea - [ ] Ensure the tests and linter pass - [ ] Code coverage does not decrease (if any source code was changed) - [ ] Appropriate docs were updated (if necessary) Fixes b/465212379 🦕
1 parent aae1b04 commit 4489687
Copy full SHA for 4489687

1 file changed

+3-4Lines changed: 3 additions & 4 deletions

File tree

Expand file treeCollapse file tree
Open diff view settings
Filter options
Expand file treeCollapse file tree
Open diff view settings
Collapse file

‎tests/system/large/functions/test_remote_function.py‎

Copy file name to clipboardExpand all lines: tests/system/large/functions/test_remote_function.py
+3-4Lines changed: 3 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1651,13 +1651,12 @@ def square(x):
16511651
return x * x
16521652

16531653

1654-
# Note: Zero represents default, which is 100 instances actually, which is why the remote function still works
1655-
# in the df.apply() call here
1654+
# The default value of 100 is used if the maximum instances value is not set.
16561655
@pytest.mark.parametrize(
16571656
("max_instances_args", "expected_max_instances"),
16581657
[
1659-
pytest.param({}, 0, id="no-set"),
1660-
pytest.param({"cloud_function_max_instances": None}, 0, id="set-None"),
1658+
pytest.param({}, 100, id="no-set"),
1659+
pytest.param({"cloud_function_max_instances": None}, 100, id="set-None"),
16611660
pytest.param({"cloud_function_max_instances": 1000}, 1000, id="set-explicit"),
16621661
],
16631662
)

0 commit comments

Comments
0 (0)
Morty Proxy This is a proxified and sanitized view of the page, visit original site.