How to resolve "requested entity not found" error when adding multiple rows to a Google Sheet with Pipedream integration?

This topic was automatically generated from Slack. You can find the original thread here.

Hello everyone - I’m working with the Pipedream google sheets integration and am running into this:

I’ve created a new sheet in a previous step, and now I want to add multiple rows to that sheet

I have the sheetID from the create a new sheet step, but when I reference it in the create multiple rows step like the first screen shot I get a “requested entity not found” error

When I copy the value of the sheetID and put that in, it works just fine.

I know what I’m messing up here is really simple, but I can’t see it! I need to be able to inject the ID from a previous step as the sheet I want to create rows in will change.

could be possible that it’s similar to this bug found last year in the add a row action: Bug in Add Row to Google Sheets, spreadsheet ID not working

Hi Stetson - Thanks for reaching out. Happy to help!

Could you take a look at the Input tab at the bottom of the step after you’ve tested it? It should show you the rendered data after the JS evaluation

That might help show if there’s an issue with the path to the step export or if the data isn’t what you expect it to be

sure thing, I’d thought to try that as well, but because when I reference the returned sheet id I get an error, I can’t really see what the input values are. Here I tried to force it by entering “Sheet 1” in the Sheet name field

here’s when I copy the sheetID as a value and paste it in — works

and here’s where I reference the return value and then manually enter “Sheet 1” for the sheet name

throws and error, and the input looks almost the same. but using the {{steps.create_spreadsheet.$return_value.spreadsheetId}} for the sheetID doesn’t seem to pull in the sheets that live inside that google sheet so that I can select one

Yes, the async options might not work with JS evaluation.

I wonder if the Sheet Name prop is the culprit.

On your working example with a user defined Google Sheet, after you successfully test does the Detailed/Code mode show a specific Sheet Name ID instead of the title?

doesn’t show an id, but does look slightly different.

Here are exact steps so get it to function

  1. copy sheetID as value, not path from create sheet action step
  2. paste sheetID into add multiple rows step
  3. then I get dropdown with the sheets in that google sheet for the sheet name
  4. select sheet, run action - works
    If I try and reference the path instead of hard coding the value for the sheetID, I can’t select a sheet name at all

Thanks for the help , definitely appreciated

do async dependent props work with JS evaluation? I don’t think so.

I think this Sheet Name prop references an ID behind the scenes.

Idk, sheet names don’t appear to have any special internal ID: pipedream/google_sheets.app.mjs at a2b64bf32ab56af9ce6698a683322e34a62860c4 · PipedreamHQ/pipedream · GitHub

yeah I couldn’t find that sheets inside a google sheet have their own id

so you think it may be that evaluating the expression for getting the id from the previous step…… the {{steps.create_spreadsheet.$return_value.spreadsheetId}} part isn’t happening early enough to allow pipedream to reach out to google with that sheetID and get the sheet names from the google sheet?

which is why it throw the “requested entity not found” error. It makes the request to sheets without an ID if an expression is used?

{{steps.create_spreadsheet.$return_value.spreadsheetId}} part isn’t happening early enough to allow pipedream to reach out to google with that sheetID and get the sheet names from the google sheet?
Correct, I don’t believe the JS evaluation is happening while you’re defining the configuration for that step.

I don’t believe the Sheet Name async prop is able to query Google Sheets for Sheet Names because the JS evaluation output isn’t available at the time of configuration.

But, if the Sheet Name title is one in the same, then it doesn’t matter. At execution time the correct value is passed

I definitely encourage you to make a bug report of this on our public Github tracker: Sign in to GitHub · GitHub

will do. Thanks for the help!