An open community 
of Macintosh users,
for Macintosh users.

FineTunedMac Dashboard widget now available! Download Here

Previous Thread
Next Thread
Print Thread
Volunteers needed :)
#25043 02/16/13 02:00 AM
Joined: Aug 2009
Likes: 15
OP Online

Joined: Aug 2009
Likes: 15
I've regularly visit this bookmarked Weather Underground page and this one.

Beginning about two weeks ago, I began experiencing some really wonky behavior from both pages: Instead of counting down from c. 350 to zero, recycling, and counting down again as they've always done when they're animated, they now stick at zero and do a really weird "stuttering" thing.

Running OS X 10.6.8, Safari 5.1.7, and Firefox 18.0.2...
  • They do it invariably in Safari
    • with Extensions enabled,
    • with Extensions disabled,
    • with Java enabled,
    • with Java disabled,
    • and after clearing cache and cookies.
  • They do it, but only almost invariably, in a pristine Firefox.
  • They do it in my boot account.
  • They do it in my test account.
  • The issue has survived a clean reinstall of both OS X and Safari.
  • The Weather Underground tech can't reproduce it. frown
Will a few of you kind people please do some testing and let me know if you experience similar behavior and with what software configurations?

Many thanks. smile


The new Great Equalizer is the SEND button.

In Memory of Harv: Those who can make you believe absurdities can make you commit atrocities. ~Voltaire
Re: Volunteers needed :)
artie505 #25045 02/16/13 03:30 AM
Joined: Aug 2009
Likes: 1
Moderator
Offline
Moderator

Joined: Aug 2009
Likes: 1
What's your CPU load when that stuttering is going on?


alternaut moderator
Re: Volunteers needed :)
artie505 #25046 02/16/13 04:10 AM
Joined: Aug 2009
Likes: 1
Moderator
Offline
Moderator

Joined: Aug 2009
Likes: 1
OK, let me not keep you in suspense for too long: this looks like some JavaScript issue to me, probably independent of Mac model or browser*. FWIW, I see exactly the same thing as you do, with the CPU maxing out as soon as the countdown reaches zero. When I now disable JavaScript in Safari's prefs, the animation immediately resumes its normal sequence and the CPU load drops below max. Running OS X 10.5. 8 and Safari 5.0.6 on a PPC iMac iSight (temporarily no Intel Macs at hand to test).

*) I'd bet the WU tech is not testing with a Mac. The affected WU functionality was probably caused by changes to the various animation pages around the time you started to notice this. Oh, and if you test the JavaScript effect, make sure to turn it back ON if you want to post the result here... smirk


alternaut moderator
Re: Volunteers needed :)
alternaut #25047 02/16/13 11:36 AM
Joined: Aug 2009
Likes: 15
OP Online

Joined: Aug 2009
Likes: 15
Thanks for the quick, helpful response. smile

First, my bad for forgetting to mention CPU load, which does not max out on my deuced Mac(hina), but does run at about 35%/core...enough to get my fans working overtime.

I also forgot to mention that both Safari's and Safari Web Content's RAM usage go through the roof.

I've now tried disabling JavaScript and gotten essentially the same results you got.

This is interesting: (In Safari)
  • I enable JavaScript.
  • When the timer hits zero and the stuttering starts I disable JavaScript.
  • The animation resumes its normal sequence, but the timer remains at zero.
  • I enable JavaScript and the stuttering resumes, apparently because the timer is stuck at zero.
  • I disable JavaScript and reload the page, and the animation is as expected and the timer is gone.
True confession time: I've read any number of posts that explain Java and JavaScript, but it's all gone in one eye and out the other, so will you please link me to the thread or post you consider definitive on the subject so I can finally (maybe) absorb the info?

Thanks.

Edit: I just let the animations run with JavaScript disabled, and without the timers, the sequences never updated/advanced from their starting times.

Last edited by artie505; 02/16/13 12:25 PM.

The new Great Equalizer is the SEND button.

In Memory of Harv: Those who can make you believe absurdities can make you commit atrocities. ~Voltaire
Re: Volunteers needed :)
artie505 #25048 02/16/13 02:10 PM
Joined: Aug 2009
Likes: 1
Moderator
Offline
Moderator

Joined: Aug 2009
Likes: 1
Originally Posted By: artie505
- ...CPU load, which does not max out on my deuced Mac(hina), but does run at about 35%/core...enough to get my fans working overtime.
I also forgot to mention that both Safari's and Safari Web Content's RAM usage go through the roof.

- ...will you please link me to the thread or post you consider definitive on the subject so I can finally (maybe) absorb the info?

Interesting. FWIW, once the timer runs out the PPC iMac CPU maxes out or nearly so (perhaps unsurprisingly), while the (moderate) RAM usage remains pretty much the same. Once they reach zero, the countdown on the animation pages remains there after re-enabling JavaScript, just as you noticed. They get reset by a page refresh. As the 'stuttering' of the animation appears to be associated with the timer, that'd be a place to start looking for code mischief.

I don't have a 'definitive' Java vs. JavaScript link at hand, but the homonymous HTML Goodies page you linked to in the Flash Bashing Express thread works well enough. tongue


alternaut moderator
Re: Volunteers needed :)
artie505 #25050 02/16/13 02:52 PM
Joined: Aug 2009
Likes: 16
Moderator
Online
Moderator

Joined: Aug 2009
Likes: 16
The definitive answer on Java and Javascript is they are totally and completely unrelated to one another. Java was developed as a cross platform programming language by Sun Microsystems. Javascript was developed by Mozilla (formerly Netscape) as an internal scripting system for browsers. The only similarity between Java and Javascript are the four letters J, A, V, A. and a very rudimentary similarity in syntax.


If we knew what it was we were doing, it wouldn't be called research, would it?

— Albert Einstein
Re: Volunteers needed :)
alternaut #25052 02/16/13 06:33 PM
Joined: Aug 2009
Likes: 15
OP Online

Joined: Aug 2009
Likes: 15
Thanks for the link, which I'd never have located on my own. tongue

Edit: By the way, why did you guess that the tech may not have been testing with a Mac?

Last edited by artie505; 02/16/13 06:48 PM.

The new Great Equalizer is the SEND button.

In Memory of Harv: Those who can make you believe absurdities can make you commit atrocities. ~Voltaire
Re: Volunteers needed :)
joemikeb #25053 02/16/13 06:46 PM
Joined: Aug 2009
Likes: 15
OP Online

Joined: Aug 2009
Likes: 15
Thanks. smile

That much I had already absorbed, and what I'd like to do now is try to understand how to recognize the difference between Java and JavaScript, so to that end I'll try to absorb alternaut's linked doc.

This thread, and a bunch of documentation work and back and forth correspondence with "Wunder William," could have been avoided had I had the knowledge for which I'm now looking and tried disabling JavaScript, rather than Java, at the outset.


The new Great Equalizer is the SEND button.

In Memory of Harv: Those who can make you believe absurdities can make you commit atrocities. ~Voltaire
Re: Volunteers needed :)
artie505 #25054 02/16/13 11:37 PM
Joined: Aug 2009
Likes: 16
Moderator
Online
Moderator

Joined: Aug 2009
Likes: 16
The quick and easy way to tell if a page is using Javascript or Java is to look at the HTML code for the page. If you find a line of code, probably in the header that says something like
Quote:
<SCRIPT LANGUAGE="javascript">
then the page uses the Javascript dialect of ECMAScript. (There are a number of dialects of ECMAScript but Javascript is by far the most common. The ECMAScript/Javascript interpreter is embedded in the browser although all supposedly comply with a version of the ECMAScript standard there can be slight variations from browser to browser.

If you find a statement such as
Quote:
<APPLET CODE="urname.class" WIDTH="250" HEIGHT="22"> </APPLET>
then the page is using Java. If the page is using Java then you must have the Oracle Java Virtual Machine installed on the computer. It is the JVM that actually executes the Java code and that is independent of which browser you are using.

Just in case you think this makes the determination easy, the actual script(s) or applet(s) may not be in the code of the page you are using rather in another page that is called by the host page. It is also possible, although not common, for a page to have both javascript(s) and java applet(s).

One final note. At one time Java applets were far more common than they are today. In today's world you are more likely to find Java servlets running on servers than you are to find Java applets. The main exception to this being online games. On the other hand, it is the unusual page that does not make some use of Javascript scripts.


If we knew what it was we were doing, it wouldn't be called research, would it?

— Albert Einstein
Re: Volunteers needed :)
joemikeb #25057 02/17/13 07:14 AM
Joined: Aug 2009
Likes: 15
OP Online

Joined: Aug 2009
Likes: 15
Thanks for that; I'm sure I'll get some mileage from it.

This is interesting: I spaced out for a moment while experimenting with your instructions, forgot that control-click calls up "View Source," and found this, which appears to be pertinent, in Safari's menu bar, but I've got no idea what its actual functionality is; it doesn't appear to do anything when enabled either before loading the maps or after they begin stuttering.

Any ideas?


The new Great Equalizer is the SEND button.

In Memory of Harv: Those who can make you believe absurdities can make you commit atrocities. ~Voltaire
Re: Volunteers needed :)
artie505 #25064 02/17/13 10:02 PM
Joined: Aug 2009
Likes: 16
Moderator
Online
Moderator

Joined: Aug 2009
Likes: 16
This Apple Knowledge Base article explains the function of all the items in Safari's Developer menu. To save you from wading through all the menu items, the pertinent entry is quoted below:

Originally Posted By: Apple Knowledge Base article PH5057
The Runaway JavaScript Timer interrupts the execution of very slow scripts, so you can regain control of Safari. Disabling it is useful for some types of automated testing.


If we knew what it was we were doing, it wouldn't be called research, would it?

— Albert Einstein
Re: Volunteers needed :)
joemikeb #25066 02/18/13 12:18 AM
Joined: Aug 2009
Likes: 15
OP Online

Joined: Aug 2009
Likes: 15
Thanks for the link and excerpt.

(Is my perception skewed, or does "Runaway JavaScript Timer" imply something diametrically opposed to "very slow scripts?")


The new Great Equalizer is the SEND button.

In Memory of Harv: Those who can make you believe absurdities can make you commit atrocities. ~Voltaire
Re: Volunteers needed :)
artie505 #25071 02/18/13 03:24 PM
Joined: Aug 2009
Likes: 16
Moderator
Online
Moderator

Joined: Aug 2009
Likes: 16
It makes sense to me, it is all a matter of relativity. You are the one who has to decide if your perception is skewed.


If we knew what it was we were doing, it wouldn't be called research, would it?

— Albert Einstein
Re: Volunteers needed :)
artie505 #25072 02/18/13 07:25 PM
Joined: Aug 2009
Likes: 1
Offline

Joined: Aug 2009
Likes: 1
A "runaway" program (like a runaway JavaScript) is a program that starts executing and then keeps on absorbing CPU time without ever producing results, accepting user input, or ending--its code execution runs away with no way to stop it. A runaway program will cause the computer to slow down.

The runaway JavaScript timer is a timer that starts whenever a JavaScript starts. It ends when the JavaScript requests user input, stops running, or otherwise makes itself behave nicely. If a JavaScript runs away, the timer will keep ticking down until it reaches 0, when it forcibly stops the runaway JavaScript.


Photo gallery, all about me, and more: www.xeromag.com/franklin.html
Re: Volunteers needed :)
tacit #25074 02/18/13 07:46 PM
Joined: Aug 2009
Likes: 15
OP Online

Joined: Aug 2009
Likes: 15
Thanks very much for explaining that.

My confusion was rooted in the fact that my issue was more or less a "runaway JavaScript timer."


The new Great Equalizer is the SEND button.

In Memory of Harv: Those who can make you believe absurdities can make you commit atrocities. ~Voltaire
Re: Volunteers needed :)
artie505 #25124 02/23/13 12:05 AM
Joined: Aug 2009
Likes: 15
OP Online

Joined: Aug 2009
Likes: 15
Well, we're getting somewhere.

The Wunderground tech gave me a free "no ads" upgrade, because he had a feeling that something in the ads was at the root of my issue...causing a memory leak, and the issue has, in fact, been resolved (with the side benefit of fewer trackers smile ).

I suspect that the tech could not replicate my issue because while his legacy installation is running OS X 10.6.x it is also running Safari 4.0.3, which differs radically from Safari 5.x. I've tried to get him to upgrade his Safari installation (in a clone, at the least), and I'm waiting to see what happens.

Edit: I forgot to mention that the ads were apparently at the root of my issue despite the fact that I had AdBlock blocking them. confused

Last edited by artie505; 02/23/13 12:18 AM.

The new Great Equalizer is the SEND button.

In Memory of Harv: Those who can make you believe absurdities can make you commit atrocities. ~Voltaire

Moderated by  alternaut, dianne, MacManiac 

Link Copied to Clipboard
Powered by UBB.threads™ PHP Forum Software 7.7.4
(Release build 20200307)
Responsive Width:

PHP: 7.4.33 Page Time: 0.032s Queries: 46 (0.024s) Memory: 0.6596 MB (Peak: 0.7794 MB) Data Comp: Zlib Server Time: 2024-03-28 19:47:28 UTC
Valid HTML 5 and Valid CSS