I also notice that the problem goes away if you leave the AnimationFrame
subscription on. (Combined with the code change I suggested above, the
program still behaves the same).

subs model = AnimationFrame.diffs Tick

so it seems like the bug might be related to turning the subscription on
and off.

On Thu, May 26, 2016 at 5:30 PM, Nick H <[email protected]> wrote:

> Hmm, it's not just unresponsive, it is crashing. In Firefox it crashes
> with this console output:
>
> 17:24:41.933 TypeError: process.root is null
> step() index.html:2342
> work() index.html:2458
> 1 index.html:2342:7
>
> Chrome crashes at the same lines for the same reason.
>
> I couldn't find a relevant issue on Github. Maybe this should be opened?
>
> On Thu, May 26, 2016 at 4:37 PM, Fernando Alegre <
> [email protected]> wrote:
>
>> Nick: Changing the code as you suggested does not fix it. There is a race
>> condition that is going on at some level below, either on the Elm runtime
>> or the browser code.
>>
>> Please try it, and you see that even with your suggestion, the program
>> will become unresponsive after clicking a dozen times or so. This looks
>> serious.
>>
>>
>>
>> On Thursday, May 26, 2016 at 9:57:46 AM UTC-5, Fernando Alegre wrote:
>>
>>> I may have found a possible race condition in Elm. It is illustrated
>>> here: <script src="
>>> https://gist.github.com/alphalambda/448099e95858b0ffc91fd41fdb1b437a.js
>>> "></script>
>>>
>>> If you click several times on the Pause/Resume button, it becomes
>>> unresponsive after a while.
>>>
>>> I am using Google Chrome, so it may be a race condition in Chrome's
>>> event handler. I am not sure. Any hints?
>>>
>>> Thanks
>>>
>>> --
>> You received this message because you are subscribed to the Google Groups
>> "Elm Discuss" group.
>> To unsubscribe from this group and stop receiving emails from it, send an
>> email to [email protected].
>> For more options, visit https://groups.google.com/d/optout.
>>
>
>

-- 
You received this message because you are subscribed to the Google Groups "Elm 
Discuss" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to [email protected].
For more options, visit https://groups.google.com/d/optout.

Reply via email to