Skip to content

test: change service account to oauth client#1568

Open
xoiga123 wants to merge 1 commit intoburnash:masterfrom
xoiga123:conftest
Open

test: change service account to oauth client#1568
xoiga123 wants to merge 1 commit intoburnash:masterfrom
xoiga123:conftest

Conversation

@xoiga123
Copy link
Copy Markdown

I got hit with

The user's Drive storage quota has been exceeded

when trying to test with a service account created from my gmail.com account. Apparently service accounts have 0 Drive storage space available, and I couldn't do any test with client.create(name), since that requires creating a sheet in the service account's Drive.

I tried some workarounds to no avail:

  1. Share a folder with the service account with Editor permission and do client.create(name, folder_id=...), still fails.
  2. Enable domain-wide-delegation so that the service account can impersonate my gmail.com account, fails because I cannot login to admin.google.com with a gmail.com account.

Unless I'm seriously misunderstanding something, the only way for a regular gmail.com user to add new tests now is by authenticating with OAuth instead so that test sheets can be created.

@alifeee
Copy link
Copy Markdown
Collaborator

alifeee commented Oct 14, 2025

sorry, I do not have much time to review PRs right now. I hope that is okay :] — I am discussing gspread maintenance with @lavigne958.

@antoineeripret
Copy link
Copy Markdown
Collaborator

Hey @xoiga123,

Can you open an issue and provide more details on your workflow?

I have the following code ...

gc = gspread.service_account(filename=os.environ["GOOGLE_APPLICATION_CREDENTIALS"])
spreadsheet = gc.create(title)

... and I'm not getting any error.

Can you add more details in an issue to understand what might be happening?

Thanks !

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 this pull request may close these issues.

4 participants