Hi Everyone,
I am using the branch n8n AI and was developing a flow based on one template utilizing Google Drive
I connected my service account to the appropriate shared folder and I can see my documents no problems with that, but when I ran the node it crashed with this error
ERROR: Cannot read properties of undefined (reading ‘pipe’)
Hi @Rad, I am so sorry you’re having trouble. I don’t have a service account ready yet but just gave this a go through OAuth2 just now, where the below workflow is running fine using the latest ai-beta image as of now:
Can you confirm if you’re also seeing this problem on your end when using OAuth2? If so, can you share your exact workflow please?
If this is working when using OAuth2, but fails with a service account even after pulling the latest ai-beta image and after sharing your folder/files with your service account, can you give me a quick shout so I can create a new service account for testing on my end?
Hi @MutedJam Thank you so much for getting back to me.
I was indeed connecting with Service Account (didnt’t work) I created a new credential based on OAuth and it did work perfectly
thank you so much
Rad
Hi @MutedJam ! Is possible use the OAuth2, but because the conection is out of my control (I need to get more privileges on company that I work), I prefer service connection…
Hi @Pedro_Cernausan, thanks so much for clarifying. I have tested the service account authentication with the File → Download operation of the Google Drive node and did indeed encounter unexpected behaviour here. I have added these problems to our internal bug tracker for a closer look and a fix.
Unfortunately it’s broken for me as well. I do not have a workaround at the moment apart from using OAuth2, but we will of course update this thread once a fix for the service account functionality is available.
Just to add, I have also put in a PR to fix this which is currently being reviewed once that is complete it will be merged and available in a future release.
Hi guys, I am facing the similar issue. I am trying to get certain files from google drive into my workflow using service account.
I am shared the folder with the service account email.
Is it a bug or I am making any mistake?
TypeError: Cannot read properties of undefined (reading 'pipe')
at /usr/local/lib/node_modules/n8n/node_modules/n8n-core/dist/BinaryData/utils.js:43:18
at new Promise (<anonymous>)
at toBuffer (/usr/local/lib/node_modules/n8n/node_modules/n8n-core/dist/BinaryData/utils.js:39:12)
at BinaryDataService.toBuffer (/usr/local/lib/node_modules/n8n/node_modules/n8n-core/dist/BinaryData/BinaryData.service.js:101:37)
at BinaryDataService.store (/usr/local/lib/node_modules/n8n/node_modules/n8n-core/dist/BinaryData/BinaryData.service.js:85:39)
at setBinaryDataBuffer (/usr/local/lib/node_modules/n8n/node_modules/n8n-core/dist/NodeExecuteFunctions.js:713:73)
at prepareBinaryData (/usr/local/lib/node_modules/n8n/node_modules/n8n-core/dist/NodeExecuteFunctions.js:818:12)
at Object.prepareBinaryData (/usr/local/lib/node_modules/n8n/node_modules/n8n-core/dist/NodeExecuteFunctions.js:1830:66)
at Object.execute (/usr/local/lib/node_modules/n8n/node_modules/n8n-nodes-base/dist/nodes/Google/Drive/v2/actions/file/download.operation.js:213:64)
at processTicksAndRejections (node:internal/process/task_queues:95:5)