WebKit Bugzilla
New
Browse
Log In
×
Sign in with GitHub
or
Remember my login
Create Account
·
Forgot Password
Forgotten password account recovery
RESOLVED FIXED
Bug 61473
REGRESSION (
r67163
): twitter.com doesn't load properly the first time
https://bugs.webkit.org/show_bug.cgi?id=61473
Summary
REGRESSION (r67163): twitter.com doesn't load properly the first time
Andy Estes
Reported
2011-05-25 15:06:55 PDT
In some cases, twitter.com fails to load the timeline with a cold cache. The black toolbar loads, but a JavaScript error prevents the rest of the page from loading. The error is typically something like: TypeError: 'undefined' is not an object (evaluating 'twttr.anywhere.api') See the attached screenshot to see what the page looks like when this happens. The problem seems to be specific to a subset of twitter accounts and usually goes away if you reload the page. Since I am able to see this error, I'll work on a reduction.
Attachments
Add attachment
proposed patch, testcase, etc.
Andy Estes
Comment 1
2011-05-25 15:07:15 PDT
<
rdar://problem/9491632
>
Andy Estes
Comment 2
2011-05-25 15:08:51 PDT
This is a regression due to <
http://trac.webkit.org/changeset/67163
>
Andy Estes
Comment 3
2011-05-25 15:22:35 PDT
There is a JavaScript function in the main document called initAPI() that calls twttr.anywhere.api.initialize(). twttr.anywhere.api is defined in an external resource that is included earlier in the main document using: <script type="text/javascript" async="" src="
https://si1.twimg.com/a/1306171173/javascripts/api.bundle.js
"></script> Since the script tag has the async attribute, it can load after initAPI() executes. Sounds like a race condition.
Adam Barth
Comment 4
2011-05-25 15:26:03 PDT
Sounds like we should evangelize them to not use async and rely on script ordering!
Theresa O'Connor
Comment 5
2011-05-25 16:46:54 PDT
I've evang'ed; they already knew about this, and have a fix on the way.
Andy Estes
Comment 6
2011-05-25 17:05:29 PDT
(In reply to
comment #5
)
> I've evang'ed; they already knew about this, and have a fix on the way.
That's great! Do you have any sense of timeframe so we know when to verify the fix?
Theresa O'Connor
Comment 7
2011-05-25 20:19:37 PDT
I'll ask.
Elliott Sprehn
Comment 8
2012-06-21 15:24:14 PDT
They don't even include the referenced script anymore and it appears they're using async more carefully.
Note
You need to
log in
before you can comment on or make changes to this bug.
Top of Page
Format For Printing
XML
Clone This Bug