cardinalitypuzzles / cardboard

Dashboard for managing puzzles and tracking status during a puzzle hunt
MIT License
31 stars 21 forks source link

transfer ownership now requires consent #616

Closed asdfryan closed 1 year ago

asdfryan commented 2 years ago

ERROR: Consent is required to transfer ownership of a file to another user.

Google Cloud has made it so that when transferring file ownership between users who are not part of the same organization, the transfer requires the new owner to accept the invitation.

Since this requires the new owner to accept the invitation, the transfer cannot be done programmatically via API, so this method fails for users who don't belong to the same organization.

We need the ownership transfer to make scripts work.

rawxfish commented 2 years ago

A work around is to pre-make ~200 sheets before the hunt and make sure ownership is properly transferred. This just adds an additional click per sheet to MITMH 2022, when we had to pre-make the sheets to get the formulas to work.

It might be worth automating what we did last year and writing a script for someone to make 50 copies of sheet template under their own account, transfer ownership to team account, and accepting the transfer invite from 200 times. Fixing the error seems to be possible by replacing transferOwnership=true with role=writer and pendingOwner=true (see https://stackoverflow.com/questions/71749779/consent-is-required-to-transfer-ownership-of-a-file-to-another-user-google-driv)