Google Sheets "on update" trigger fails Workflow activation

I have a Google Sheets Trigger node by itself in the workflow (i.e. no other nodes). When I activate the workflow, I get an error, but only if “Trigger On” has a value of “Row Updated” or “Row Added or Row Updated”. If I set it to just “Row Added”, then it works. The error when I try to activate:

Workflow could not be activated:
There was a problem activating the workflow: "Cannot read properties of undefined (reading 'application/vnd.openxmlformats-officedocument.spreadsheetml.sheet')"

I have tried different combinations of “From List”/”By URL”/”By ID” values for the “Document” and “Sheets” fields, but the results are always the same.

Is this a bug? And if not, is anyone able to point me in the direction of what I’m doing wrong?

Setup information

  • self-hosted
  • n8n version - 1.106.3

Hello @nothsa .

Try to add the node after the trigger and check if it resolves the activation error. You can use the code node and just use return $input.all();

This is a workaround not fix.

I tried to reproduce it on self hosted, 1.106.3 using only the trigger in the workflow with
”Row Added or Row Updated”. It worked fine for me.

it worked fine for me when row added:

Mine runs fine too if I hit “execute” on it. Did you try save and “activate” the workflow? Does it activate without an error?

Maybe this is a permissions issue? This is a sheet that is shared with the Service Account used in the credentials. The SA has maximum (i.e. “Edit”) permissions, but maybe it has to be the owner? Or there is an additional Google API permission that needs to be added?

Thanks for the troubleshooting, folks!

I figured out the issue (for my situation, at least). If the Sheet is in a Google “Shared Drive”, the user accessing the Sheet must have “Manager”-level access to the Drive (even if they already have “Edit” access to the Sheet)