Page 1 of 1

High cpu usage- play.typeracer.com(google-analytics blocked)

Posted: Mon Aug 22, 2011 3:35 pm
by abhijithmadhav
Problem: Abnormal high cpu usage when play.typeracer.com is loaded with google-analytics.com blocked with the following message flashed by the site,
Warning! Something unexpected just happened. You may need to Refresh the browser page if TypeRacer stops working.
URL : http://play.typeracer.com/

NoScript Version: 2.1.2.6

Firefox version: 6.0

Operating system: ubuntu 11.04

Error console messages:

Code: Select all

Error: ERROR addons.manager: Exception calling provider startup: [Exception... "Component returned failure code: 0x80520015 (NS_ERROR_FILE_ACCESS_DENIED) [nsIFile.directoryEntries]"  nsresult: "0x80520015 (NS_ERROR_FILE_ACCESS_DENIED)"  location: "JS frame :: resource:///modules/XPIProvider.jsm :: recursiveLastModifiedTime :: line 1207"  data: no]
Source File: resource:///modules/XPIProvider.jsm
Line: 1207
Warning: XUL box for _moz_generated_content_after element contained an inline #text child, forcing all its children to be wrapped in a block.
Source File: chrome://browser/content/browser.xul
Line: 0
Warning: Expected declaration but found '!'.  Skipped to next declaration.
Source File: http://play.typeracer.com/TRcombined_cca4a8a5d28104ca8be7203e98a6365f.cache.css
Line: 51
Warning: Error in parsing value for 'filter'.  Declaration dropped.
Source File: http://play.typeracer.com/TRcombined_cca4a8a5d28104ca8be7203e98a6365f.cache.css
Line: 91
Warning: Unknown property 'user-select'.  Declaration dropped.
Source File: http://play.typeracer.com/gwt-dnd.css
Line: 10
Warning: Unknown property 'zoom'.  Declaration dropped.
Source File: http://play.typeracer.com/gwt-dnd.css
Line: 16
Warning: Unknown property 'zoom'.  Declaration dropped.
Source File: http://play.typeracer.com/gwt-dnd.css
Line: 20
Warning: Unknown property 'zoom'.  Declaration dropped.
Source File: http://play.typeracer.com/gwt-dnd.css
Line: 26
Warning: Error in parsing value for 'filter'.  Declaration dropped.
Source File: http://play.typeracer.com/gwt-dnd.css
Line: 41
Note: CPU usage returns to normal and warning message from play.typeracer.com disappears once google-analytics.com is unblocked.

Re: High cpu usage- play.typeracer.com(google-analytics bloc

Posted: Mon Aug 22, 2011 8:03 pm
by al_9x
The Google analytics surrogate needs to catch more, set noscript.surrogate.ga.replacement to

Code: Select all

(function(){var _0=function(){return _0;};_0.__noSuchMethod__=_0;with(window)urchinTracker=_0,_gaq={__noSuchMethod__:_0,push:_0,_link:function(h){if(h)location.href=h},_linkByPost:function(){return true},_getLinkerUrl:function(u){return u},_trackEvent:_0},_gat={_getTracker:function(){return _gaq}}})()
Perhaps it should be updated to use proxies, Giorgio?

Re: High cpu usage- play.typeracer.com(google-analytics bloc

Posted: Mon Aug 22, 2011 8:46 pm
by Giorgio Maone
al_9x wrote: Perhaps it should be updated to use proxies, Giorgio?
Unfortunately we're still supporting Fx 3.x, which has no proxies.

Of course NS 3.x, when it gets its Surrogates porting, will take advantage of proxies everywhere.

Re: High cpu usage- play.typeracer.com(google-analytics bloc

Posted: Tue Aug 23, 2011 5:28 pm
by Giorgio Maone

Re: High cpu usage- play.typeracer.com(google-analytics bloc

Posted: Wed Aug 24, 2011 12:32 am
by abhijithmadhav
Giorgio Maone wrote:Please check latest development build 2.1.2.7rc3, thanks.
Thanks. This works.

-Abhijith

Re: High cpu usage- play.typeracer.com(google-analytics bloc

Posted: Wed Aug 24, 2011 8:15 pm
by al_9x
_gat needs another method, _createTracker, I guess it might as well be __noSuchMethod__.

Code: Select all

(function(){var _0=function(){return _0;};_0.__noSuchMethod__=_0;with(window)urchinTracker=_0,_gaq={__noSuchMethod__:_0,push:_0,_link:function(h){if(h)location.href=h},_linkByPost:function(){return true},_getLinkerUrl:function(u){return u},_trackEvent:_0},_gat={__noSuchMethod__:function(){return _gaq}}})()