How useful is $SynchronousEvaluation? Example SessionSubmit @ Print @$SynchronousEvaluation


Will print False even though ref/SessionSubmit/Details last point:

The task is run preemptively, both when the system is waiting for input and during other evaluations.

And ref/$SynchronousEvaluation/Details 3rd point: synchronous evaluation is the same as a preemptive evaluation. Question • I expected True. Is this a bug or is it a documentation inconsistency (see below). Further thoughts Following notes are only loosely connected to the main question so one does not need to read further. Next point in$SynchronousEvaluation says:

Synchronous evaluations halt the system while being evaluated.

This is not true for scheduled tasks, you can move the slider during the pause:

Slider[1]
SessionSubmit @ Pause[10]


While you can't move it during this pause:

Slider[1]
Dynamic @ Pause[10]


I guess the bottom line is that there is a difference between a preemptive evaluation in general and a preemptive evaluation coming from the preemptive link. And that difference needs more documentation space.

• you should reexamine that last example. Moving the slider thumb generated by Slider[1] will never go to the kernel (the FE doesn't need to update anything). Dynamic[Pause[10]] needs to go to the kernel, so therefore the FE blocks while it waiting for the result. – ihojnicki Jun 27 '19 at 14:53
• @ihojnicki Sorry for not being clear, I understand what happens. My point is that documentation says 'scheduled tasks are preemptive' && 'preemptive evaluations halt the system' while it should be 'preemptive link evaluations halt the system' because as an example with SessionSubmit shows, scheduled, preemptive pause does not block the slider as opposed to the dynamic preemptive pause. The question what to expect from $SynchronousUpdating remains too. – Kuba Jun 27 '19 at 16:04 • The docs are written with a Dynamic bias, but it really is a property of preemptive evaluations in the kernel. What if there were two ScheduledTasks? And I cannot comment on$SynchronousEvaluation. – ihojnicki Jun 27 '19 at 21:40