Skip to content

CLN: avoid use of service account keys in to_gbq and read_gbq tests #43214

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

Closed
tswast opened this issue Aug 25, 2021 · 2 comments · Fixed by #43231
Closed

CLN: avoid use of service account keys in to_gbq and read_gbq tests #43214

tswast opened this issue Aug 25, 2021 · 2 comments · Fixed by #43231
Assignees

Comments

@tswast
Copy link
Contributor

tswast commented Aug 25, 2021

The GCP project we (are? were?) using to test the to_gbq and read_gbq is scheduled to get a policy applied to it that prevents the use of service account key files. https://cloud.google.com/resource-manager/docs/organization-policy/restricting-service-accounts#disable_service_account_key_creation

In anticipation of this change:

  1. Are the to_gbq and read_gbq tests still running in the CI for this project? It's been a while since I've last looked and I've forgotten where they would be running.

  2. If they are running somewhere and we want to continue running them, we need to do something about this upcoming restriction.
    a. Ideally we'd migrate these tests to a service that doesn't require a GCP service account key file to connect to BigQuery. Cloud Build could be a good candidate, as it has a service account associated with it that doesn't require a key file. I could help migrate these tests if that's what we choose to do.
    b. We continue to use a key file, but it'd have to be a project not associated with Google. This may be more difficult to get billing figured out (not that the tests actually cost that much to run, but there's overhead in getting the billing accounts setup plus whomever sets them up is a bit at risk if someone abuses the credentials)

I'd appreciate your thoughts so that we can continue to ensure these methods work well.

@tswast
Copy link
Contributor Author

tswast commented Aug 25, 2021

Looking at the commit history, I see these tests were run on Travis (#36443). I also see we've migrated away from Travis (#41738).

Perhaps that means these tests are no longer run?

Oh, and I thought of a option (2c) -- We can make sure that on the pandas-gbq repo, we are testing against nightly builds of pandas using the pandas.to_gbq and pandas.read_gbq interface, just as is done in this test suite. Or perhaps even checkout the tests from this repo to run there as an integration test?

@tswast tswast changed the title CLN: Need to avoid use of service account keys in to_gbq and read_gbq tests CLN: avoid use of service account keys in to_gbq and read_gbq tests Aug 25, 2021
@jreback
Copy link
Contributor

jreback commented Aug 25, 2021

pretty sure we are no longer running these tests - if these exists we should remove

ideally run against pandas dev nightly

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants