Thanks for all the details Ellsass. We're working on some infrastructure changes and it's possible that there are moments where the layers of caches might not be in sync. We'll continue looking into this.
I would recommend sticking with the same app, or a collection of apps, when you encounter the problem instead of deleting and re-registering an application. Taylor Singletary Developer Advocate, Twitter http://twitter.com/episod On Wed, May 19, 2010 at 5:47 AM, Ellsass <cpa...@gmail.com> wrote: > 1. Yes, I'm sure. > > 2. On one occasion I requested new API keys, and on another occasion > (as mentioned above) I deleted the app and re-registered it from > scratch. Here are the three scenarios: > > A. Get new API key. App works fine for a while (a few [10?] page loads > over perhaps 5-10 minutes), before getting the error. If I wait a > while (an hour, maybe) it will work again, but only for a few page > loads/10 minutes. (A page load = 3 API calls: statuses/home_timeline, > statuses/mentions, and account/verify_credentials.) > > B. Delete app, re-register from scratch. Same as above: app works fine > for a while (a few page loads or about 10 minutes), then the error, > then after waiting a while it will work again for a short time. > > C. Do neither of the above (keep the same API key). Same results as > above. > > As I said before, I hadn't made any changes to my API calls for a day > or two prior to the error. (I was working on the HTML/JS/CSS, so I was > making API requests, but certainly <150 per hour.) Once the errors > began, the only API-related changes I tried were to request 100 > statuses from statuses/home_timeline instead of 200. > > I'm not sure if this factors in, but the app isn't publicly available > (I'm blocking access to the directory with .htaccess) and it's hard- > coded to use my Twitter screen name (the same one the app is > registered under). > The only other thing I observed was that often the page would work > fine on my PC (Firefox), but as soon as I tried loading it on my > iPhone it would fail (and then fail on the PC as well). I didn't do > any careful experimentation to determine whether this was repeatable > or just a coincidence, but it's something I noticed in hindsight. > > And again, everything has been working just fine for over 36 hours > now. Not a single hiccup. > > > > On May 18, 7:02 pm, Taylor Singletary <taylorsinglet...@twitter.com> > wrote: > > Thanks, Ellsass. > > > > A few more questions to better help us identify the issue: > > - You're sure you're using the same consumer key and secret for these > > requests and not switching between different API keys and possibly > > mis-matching access tokens with the wrong consumer key? > > - Have you been making any changes to your application record on > > twitter.com or dev.twitter.com before or during these requests? > > > > Thanks! > > > > Taylor Singletary > > Developer Advocate, Twitterhttp://twitter.com/episod > > > > On Tue, May 18, 2010 at 3:27 PM, Ellsass <cpa...@gmail.com> wrote: > > > Today (5/18) I haven't gotten the error at all. It was happening > > > occasionally on 5/16 and very often on 5/17 during the daytime and > > > evening, eastern US. > > > > > My request, in PHP (I've modified EpiTwitter slightly to deal in XML > > > rather than JSON): > > > > > $twitterObj = new EpiTwitter($consumer_key, $consumer_secret, > > > $_COOKIE['oauth_token'], $_COOKIE['oauth_token_secret']); > > > $twitterInfo = $twitterObj- > > > >get_statusesHome_timeline(array("count"=>"$numTweets")); > > > > > and then the contents of $twitterInfo->responseText is this: > > > > > <?xml version="1.0" encoding="UTF-8"?> > > > <hash> > > > <request>/statuses/home_timeline.xml?count=100</request> > > > <error>Invalid application</error> > > > </hash> > > > > > On May 18, 9:55 am, Taylor Singletary <taylorsinglet...@twitter.com> > > > wrote: > > > > This sounds strange. Can you share the return XML you get when it > says > > > > "invalid application?" > > > > > > Taylor Singletary > > > > Developer Advocate, Twitterhttp://twitter.com/episod > > > > > > On Mon, May 17, 2010 at 3:56 PM, Ellsass <cpa...@gmail.com> wrote: > > > > > When attempting to retrieve a timeline (or mentions, etc) I am > getting > > > > > the response "Invalid application" in the XML. I am using Oauth > (with > > > > > EpiTwitter). It just started today, and occasionally I will be able > to > > > > > retrieve the timeline with no problems. I am not hitting my rate > limit > > > > > (I am the only one using the app) and there are no messages on > > > > > dev.twitter.com. If I delete and re-register the app it will work > a > > > > > few times, then die again, going back to working intermittently. > > > > > > > Any idea what could be causing this? I haven't changed any of my > API- > > > > > calling code for a few days. >