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

test: do GCF cleanup in both presubmit and e2e tests #423

Merged
merged 8 commits into from
Mar 19, 2024
Merged

Conversation

shobsi
Copy link
Contributor

@shobsi shobsi commented Mar 8, 2024

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 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 internal issue 328515697 🦕

@shobsi shobsi requested review from a team as code owners March 8, 2024 01:45
@shobsi shobsi requested a review from junyazhang March 8, 2024 01:45
@product-auto-label product-auto-label bot added size: l Pull request size is large. api: bigquery Issues related to the googleapis/python-bigquery-dataframes API. labels Mar 8, 2024
@shobsi shobsi added the kokoro:force-run Add this label to force Kokoro to re-run the tests. label Mar 8, 2024
@bigframes-bot bigframes-bot removed the kokoro:force-run Add this label to force Kokoro to re-run the tests. label Mar 8, 2024
@shobsi shobsi requested a review from tswast March 12, 2024 01:52
from tests.system.utils import convert_pandas_dtypes
from tests.system.utils import (
convert_pandas_dtypes,
delete_cloud_function,
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Same here. Import the "utils" package/module, not the individual functions.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Done, thanks.

@@ -21,6 +21,7 @@
import typing
from typing import Dict, Optional

from google.api_core.exceptions import NotFound, ResourceExhausted
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Nit: Use import statements for packages and modules only, not for individual types, classes, or functions.

https://google.github.io/styleguide/pyguide.html#22-imports

The only exception is with the typing package.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Done, thanks.

tests/system/conftest.py Show resolved Hide resolved
import numpy as np
import pandas as pd
import pyarrow as pa # type: ignore
import pytest

from bigframes.functions.remote_function import get_remote_function_locations
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Same here. Import packages/modules, not functions.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Done, thanks!

@tswast tswast merged commit 5dd9e6e into main Mar 19, 2024
15 checks passed
@tswast tswast deleted the shobs-gcf-cleanup branch March 19, 2024 14:11
TrevorBergeron pushed a commit that referenced this pull request Mar 20, 2024
* test: do GCF cleanup in both presubmit and e2e tests

* use functions client from session

* address review comments

---------

Co-authored-by: Tim Sweña (Swast) <[email protected]>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
api: bigquery Issues related to the googleapis/python-bigquery-dataframes API. size: l Pull request size is large.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants