You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I understand the motivations for why Literate evaluates things in a temporary non-Main module, but it makes simple things like this file fail:
using Distributed
@everywhere x =1# this evals in Main on all workers#-
x # this accesses the temporary non-Main module Literate creates
which would work in a real notebook. You'd need @everywhere @eval $(@__MODULE__) x = 1 but thats really painful if your notebook has lots of @everywheres, and it can get hairier for other constructs. Generally Distributed stuff that works in a notebook or script won't work in Literate.
Could Literate have an option (off by default) to just execute in Main? Or some other solution?
The text was updated successfully, but these errors were encountered:
I understand the motivations for why Literate evaluates things in a temporary non-Main module, but it makes simple things like this file fail:
which would work in a real notebook. You'd need
@everywhere @eval $(@__MODULE__) x = 1
but thats really painful if your notebook has lots of@everywhere
s, and it can get hairier for other constructs. Generally Distributed stuff that works in a notebook or script won't work in Literate.Could Literate have an option (off by default) to just execute in Main? Or some other solution?
The text was updated successfully, but these errors were encountered: