bugs

Forum > Bugs > showroom
Reply To Thread (login)
matvei [156]
2013-02-22 21:32:13
[11 years, 62 days ago]

timer sticking at times with other people?


 
Myriad [337]
2013-02-22 21:34:05
[11 years, 62 days ago]

I get that very occasionally, but I find that refreshing the page fixes it.


 
matvei [156]
2013-02-22 21:34:51
[11 years, 62 days ago]

well i refresh it then after few seconds it sticks again.


 
Trio [311]
2013-02-22 21:35:11
[11 years, 62 days ago]

Same, refresh works, not too bothersome.


 
matvei [156]
2013-02-22 21:35:53
[11 years, 62 days ago]

yea but i have to keep refreshing every 1 to 2 seconds D: rithy sad Lol


 
matvei [156]
2013-02-22 21:37:21
[11 years, 62 days ago]

even the seconds timer on the site time is sticking Dx does my browser hate me now?


 
Trio [311]
2013-02-22 21:38:25
[11 years, 62 days ago]

Lol, sucks man.


 
matvei [156]
2013-02-22 21:39:14
[11 years, 62 days ago]

bots hates rithy now XD


 
Leader2 [136]
2013-02-23 12:57:49
[11 years, 61 days ago]

i have to refresh every 2 seconds wtf man


 
Kupo [105]
2013-02-23 14:11:57
[11 years, 61 days ago]

still doing it for me :/


 
Ender [1]
Administrator
2013-02-26 01:03:49
[11 years, 59 days ago]

Huh, that's really strange, I see this too. The countdown goes down 1 second, but then doesn't progress any further. The javascript code that controls this hasn't been changed in quite some time, so I'm not sure offhand what's going on here, but I'll take a look.


 
Gpof2 [130]
2013-02-26 05:22:40
[11 years, 59 days ago]

inb4noharddrivespaceagain


 
TheCause [346]
2013-02-26 05:27:54
[11 years, 59 days ago]

i actually only have this on chrome, firefox is fine


 
Trio [312]
2013-02-26 19:41:54
[11 years, 58 days ago]

It's only happened to me twice: after 3rd mouse clicking to open the showroom in a new tab.


 
Seraph02 [31]
2013-03-01 11:40:01
[11 years, 55 days ago]

happens on my chrome, firefox works fine


 
Ender [1]
Administrator
2013-03-05 22:45:42
[11 years, 51 days ago]

Well this was a nasty little bug. It's squashed now, but read on for what I believe happened if you're interested.

I'm using an ancient version of jQuery which appears to have a bug where it bogusly calls passes "true" to clearInterval(). This function normally takes an integer argument returned by setInterval() to stop that particular interval. Thanks to JavaScript's weak typing, passing "true" to clearInterval() appears to be equivalent to passing it "1". This in turn has the effect of stopping the interval for anything that happened to be assigned that id. Different browsers start at different values for setInterval(), but they all increment by 1 with each successive call. IE starts at a random number, Firefox starts at 2, and Chrome starts at 1 (this explains why this only happened in Chrome).

So yeah, that was a really obscure bug. Why this only became a problem recently is still a mystery to me. Perhaps Chrome only recently started issuing setInterval() ids starting at 1, who knows.

The real fix is to not use such an outdated JavaScript library, but upgrading to the most recent jQuery would probably involve quite a bit of effort. For a quick fix, I'm now setting up a dummy interval in the JavaScript bootstrap code so that id 1 gets consumed immediately. Ugly, but it works.


 
Riae [72]
2013-03-06 20:17:51
[11 years, 50 days ago]

as long as it works. thanks ender.

-rithy


 
Forum > Bugs > showroom
Reply To Thread (login)