-
Notifications
You must be signed in to change notification settings - Fork 443
Handling errors #20
Comments
I'm currently getting a 400: Bad Request error pointing to line 184 in tabletop.js (here's my code: lisawilliams/tabletop-js@13a630d) Line 184 reads: document.getElementsByTagName('script')[0].parentNode.appendChild(script); I'm also pretty excited about Tabletop & can't wait to get it running! |
I fixed error handling in my own project a while back, but did not submit a pull request since it broke the current code. I used Node.js style continuation for the callback -- |
I'd love to hear how you figured out there was an error loading coming back from Google - AFAIK with script tag injection you've got limited support for onerror and a lot of folks end up having to just use timeouts. |
I thought so too, but I was pleasantly surprised when I added an event to the script tag object (not the tag itself, but the JS object) for errors. I tested it in Chrome, FF, IE9,8,7 and all work, at least for a "400 Bad request" error, so I just went with it. While I was at it, I also added an error callback for requesting a sheet with an invalid name. Check out my fork of it (sorry, it's an older version). https://github.com/catdad/tabletop |
That's great! I'll take a look when I get a chance, it sounds like it's going to save a lot of folks a lot of headaches. |
Hey, is there any way to use timeouts with tabletop? I have a user experiencing a console error when I do a Tabletop.init (no idea why, getting an |
There's been a real big issue happening the past week where published Google Spreadsheets are intermittently being redirected to a login page. It's going to require a fix on Google's end, but I'll see if I can put something together later today to help with that specific scenario... |
Ah, so I'm not crazy! That's good. Well I appreciate your help! |
I've been experiencing it too (and thought it was something I was doing wrong). Thanks so much for anything you can come up with to help! |
Just to keep everyone in the loop, I've figured out how to reproduce it, it's definitely a Google bug, and I've put up a post on their product forums at http://productforums.google.com/forum/#!category-topic/docs/documents/0pneogfgzN0 Since the issue requires you to have previously signed into a Google account and had your session expire, using Flatware https://github.com/jsoma/flatware (or some other sort of proxying/caching mechanism) should solve the problem. If you pull the most recent Tabletop there's proxy support as well as a Flatware example. Sorry to have hijacked the issue for this! |
Hi @jsoma - thanks for all this great work. It would probably help a lot of people if you put the forums link above in the README section about this issue. Also, you say that Google "don't have a fix planned until September 30th". |
Dropping the post link to the post into the README is a great idea! And the Google ticket is an internal one that I've only heard of secondhand, so I unfortunately can't link out to it. |
We now have error callbacks, along with Promise support. I think this kind of somewhat hopefully addresses this. |
Would be awesome to get a callback to handle error responses from Google. Today I was getting 324 (ERR_EMPTY_RESPONSE: Server closed the connection without sending any data) and 429 (unknown).
I <3 Tabletop
The text was updated successfully, but these errors were encountered: