erquhart
erquhart•10mo ago

Custom query fails, no recovery option in UI

I tried a custom query, just ran the default .take(10) from the current table, didn't make any edits. It errored, but there is no indication of what the error was in the custom query panel or in the logs. There's also no controls visible to do anything further, the run function button is now missing (see screenshot)
No description
27 Replies
erquhart
erquhartOP•10mo ago
Looks like the missing run function button is a separate bug - if you expand the custom query panel and then collapse, the button disappears below the fold.
Michal Srb
Michal Srb•10mo ago
Deployment name?
erquhart
erquhartOP•10mo ago
Happening in all envs on a couple of different projects, here's a dev env: curious-lark-383 I have an old version of my app and a newer project that I migrated to a couple months ago to get around the import/export issues with older projects. Both have the issue. But another project created in between those two doesn't have it, and new projects don't have it. So it's something specific to my app.
Michal Srb
Michal Srb•10mo ago
Do you have Bytes stored in the table you're trying to query?
erquhart
erquhartOP•10mo ago
No I've tried the default query on a very simple table with a few records, same Added a test table and convex is automatically adding it to my schema and deploying, that's wild Seems to be stuck though
erquhart
erquhartOP•10mo ago
No description
Michal Srb
Michal Srb•10mo ago
If you can figure out what's special about the deployments where the custom query fails that would really help
erquhart
erquhartOP•10mo ago
Trying Any idea why it's stuck validating? I can't see any logs or anything for that on my end RE: the root issue, the screenshot up top shows "Error" - there's nothing for that in your logs? looks like a 500
{
"code": "InternalServerError",
"message": "Your request couldn't be completed. Try again later."
}
{
"code": "InternalServerError",
"message": "Your request couldn't be completed. Try again later."
}
Michal Srb
Michal Srb•10mo ago
Where are you deploying from?
erquhart
erquhartOP•10mo ago
I didn't deploy, the validation spinner is in the UI, presumably because I added a table through the UI (for testing) It added a schema entry for the table I added and started redeploying
Michal Srb
Michal Srb•10mo ago
Via npx convex dev?
erquhart
erquhartOP•10mo ago
No I'm not running anything This is all through UI interactions in the convex dashboard 1. added a table through the UI 2. added a document with a string field 3. observed the generated schema in the dashboard showed an entry for the new table 4. observed the new schema being validated message I went ahead and: 1. deleted the table through the UI, as custom query showed inline errors due to the table not being in the schema 2. added the table into my schema locally and deployed to dev 3. added a document to the table in the UI 4. observed that the "A new schema is being validated after a code push..." continues to show, even after a successful deploy 5. attempted default custom query against the new table and it stsill returns the same 500
Michal Srb
Michal Srb•10mo ago
Can you share details of the 500 from the Network tab?
erquhart
erquhartOP•10mo ago
I shared the payload above, anything else specifically? The request has an admin key, I can dm you the request body
{
"code": "InternalServerError",
"message": "Your request couldn't be completed. Try again later."
}
{
"code": "InternalServerError",
"message": "Your request couldn't be completed. Try again later."
}
Michal Srb
Michal Srb•10mo ago
Can you try to reload your dashboard (for the schema validation being stuck issue)
erquhart
erquhartOP•10mo ago
Did that a bunch Did again for good measure Note: this is just a bug report, completely non-blocking for me
sshader
sshader•10mo ago
Just to make sure I understand -- sounds like there's 2 bug reports here. (1) being stuck on the "new schema is being validated" spinner in the dashboard after pushing code (2) custom test query failing for unclear reasons And both of these happen on curious-lark-383 (and also some other projects) For (2), we do see an error on our side but need to do some more investigation to figure out what exactly is happening there.
erquhart
erquhartOP•10mo ago
Correct - it is not clear whether these two issues are related as I only happened to notice 1 while troubleshooting 2. Actually, just checked an unrelated project and it also has issue 1, and I haven't made a change to that project in months. Might just be a UI or state bug. If you click Show Schema in a project and scroll to the bottom you may see it in your projects too It looks like it specifically shows on my projects that have schemas defined in code, those that don't do not have this behavior.
sshader
sshader•10mo ago
Aha yeah I also see (1) in my projects with schema!
erquhart
erquhartOP•10mo ago
hooray for easy repros 🎉
sshader
sshader•10mo ago
Yep (1) seems to just be an inverted boolean in the dashboard UI code and will be fixed shortly
erquhart
erquhartOP•10mo ago
ari
ari•10mo ago
^ I'll be working on that one today too 🙂 thx for reporting these issues
presley
presley•10mo ago
@erquhart when you get a chance can you try the custom query again? We weren't able to reproduce the issue ourselves so curious if you still can or has resolved. We have added some additional logging and instrumentation to help us narrow it down if it happens again.
erquhart
erquhartOP•10mo ago
@presley Still failing, same 500 but it did print an error message in the UI this time:
Encountered an error running this function. Please try again or contact support.
Encountered an error running this function. Please try again or contact support.
It also tried to send a payload to sentry, but got a 413 payload too large, in case you were hoping to get insights from that. I copied the payload if you want me to DM it to you. The payload appears to include an array of all DOM objects in the dashboard, hence the payload too large error.
sshader
sshader•9mo ago
Ok we believe we've identified the issue on our side! Will keep you posted on a fix I believe this should be fixed now! (let us know if that's not the case)
erquhart
erquhartOP•9mo ago
Works! Thank you 🙂

Did you find this page helpful?