I’m making a custom node to convert images generated by an image generation node to WebP and compress them for use on web. If there are better ways to go about this, I’m all ears, I’m not married to this custom node approach.
But I’ve written it and debugged it a number of ways and it can’t seem to correctly get the file from Google Drive Reader. I get a “File not Found” error no matter what I do. Here’s a run link: Gumloop | Automation Builder
and a screenshot of the current part of the flow that is very simple:
Hey! There are a couple of good ways to approach this, and it looks like you’re very close.
First, the likely cause of the “File not found” error is the input definition on your custom node. If the node is expecting a string, it won’t correctly receive the file coming from the Google Drive Reader. Make sure the input is declared with data_type: "File" instead of "string". That mismatch can cause the behavior you’re seeing.
If this node has gotten a bit messy from debugging, it can be easier to start fresh. Creating a new custom node and letting Gummie generate the initial version often avoids subtle schema or wiring issues. Once it’s generated, you can adapt it specifically for your image-to-WebP use case and test it end-to-end.
One important thing to keep in mind is that custom nodes can’t directly output files – only strings. So once you convert the image to WebP, you’ll need another way to get it back into the flow. Common approaches are returning the image as base64 and decoding it later, or uploading the file inside the custom node and returning a reference or URL.
If you go the upload route, you’ll need to upload the WebP back into Gumloop (or another host). After creating the custom node, make sure you upload the node file to Gumloop, then grab the Upload File API endpoint from your credentials. You can give this documentation to Gummie so it knows how to upload the converted image programmatically. If you already use a public or temporary file-hosting service, that works too.
Finally, if you’d rather not handle image conversion logic yourself at all, you can also use a third-party image conversion API like CloudConvert or TinyPNG. Providing Gummie with that API’s documentation and key lets it build a custom node specifically for WebP conversion and compression without you having to manage the image processing logic directly.
In Gumloop, the “file not found” error is almost always caused by a wrong type. If you set the input type of your custom node to `string`, the Google Drive Reader will pass a File object instead of a path, so nothing will resolve on disk. Don’t worry about the temp file setup; just set the input `data_type` to `File`.
Also, don’t forget that custom nodes can only send strings and not files. Because of this, you’ll need to either return base64 or upload the file inside the node and return a reference after you’re done. This should work as long as you align the File input and don’t treat it like a title.