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

Google Drive Trigger not working when syncing through a desktop app #9772

Open
mrcrdwd opened this issue Jun 16, 2024 · 2 comments
Open

Google Drive Trigger not working when syncing through a desktop app #9772

mrcrdwd opened this issue Jun 16, 2024 · 2 comments

Comments

@mrcrdwd
Copy link

mrcrdwd commented Jun 16, 2024

Bug Description

When syncing / uploading files to Google Drive the createdTime and modifiedTime are preserved from the local filesystem. The problem is that the poll function in the Google Drive Trigger checks for these dates to determine whether or not new files have been added. I did a quick check if there is a different file property that does get updated to the current date but couldn't find one.

When uploading files through the web interface to Google Drive the createdTime is set to the current moment so the trigger does work correctly in that case.

To Reproduce

  1. Download the Google Drive app (on OSX)
  2. Create a synced folder (set to streaming)
  3. Add a file to the synced folder

Expected behavior

The n8n Google Drive Trigger should also fire when files are uploaded via a desktop app.

Operating System

Ubuntu 22.04.4 LTS

n8n Version

1.45.1

Node.js Version

v20.5.1

Database

SQLite (default)

Execution mode

main (default)

@mrcrdwd
Copy link
Author

mrcrdwd commented Jun 16, 2024

Apparently, there's a whole thread around how the Google Drive sync clients (don't) handle creation and modification dates.

A simple, though not very elegant workaround, is to rename a file on the local disk once it has been synced. That changes the modification date. Mind you that renaming the file first, before syncing, doesn't change the modification date. At least not on OSX.

The other workaround, as described above, is to upload the file through the web interface.

@Joffcom
Copy link
Member

Joffcom commented Aug 5, 2024

Hey @mrcrdwd,

Looking at this I am not sure if there is actually anything we can do without indexing the entire contents of the google drive to look for something new which wouldn't be ideal.

I will do some digging to see if I can find anything else for this but it could be that we are not able to fix this.

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

2 participants