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

FIle not found. #2

Open
add-on-dev opened this issue Apr 5, 2024 · 1 comment
Open

FIle not found. #2

add-on-dev opened this issue Apr 5, 2024 · 1 comment
Assignees

Comments

@add-on-dev
Copy link

I would love to understand more about the "file not found" issue. What in practical sense do I need to do to make this work. The situation is I have a published Editor Add-On, which I'm updating with ReDriveApp. What would be the additional required process for my users in order to make the old files usable?

Also very basic question. I am working on the new version of the Add-On in the different project. It was Test Deployed with full drive scope. What do I need to do to make ReDriveApp work? It seems like whatever file ID i'm trying to get - it sees none of them on my Drive.

Thanks

@davegleeda
Copy link

"The situation is I have a published Editor Add-On, which I'm updating with ReDriveApp. What would be the additional required process for my users in order to make the old files usable?"

User's would need to select the files with the Drive file picker. Be sure your app's App ID (GCP project number) is passed when constructing the picker: https://developers.google.com/drive/picker/guides/sample

"Also very basic question. I am working on the new version of the Add-On in the different project. It was Test Deployed with full drive scope. What do I need to do to make ReDriveApp work? It seems like whatever file ID i'm trying to get - it sees none of them on my Drive."

It should work as-is on files it creates after you switch to the /drive.file scope and start using ReDriveApp. For files created prior, you'll need to have them selected via Drive File Picker (see above).

Basically for one of my Add-ons, after I migrated to /drive.file and ReDriveApp, I added code to detect if my Add-on could not open a file from Drive that it normally should have been able to. In those cases, I send the end-user an email (via Mail app) notifying them of the issue, and directing them to a help page on my Add-on's website instructing them on what to do (i.e. create or select a new input file, or use the Drive file Picker to re-select the old one).

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

No branches or pull requests

3 participants