Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[meta-issue] State of examples #137

Open
10 of 11 tasks
randyzwitch opened this issue Apr 12, 2016 · 9 comments
Open
10 of 11 tasks

[meta-issue] State of examples #137

randyzwitch opened this issue Apr 12, 2016 · 9 comments

Comments

@randyzwitch
Copy link
Contributor

Running on 0.4.6 on OSX, I found the following:

So not bad, can fix up latex.jl and mc.jl pretty quickly I'd think. Minesweeper doesn't lay out grid for me, it makes everything as rows (though the rows are interactive to spaces away from a mine)

@shashi
Copy link
Member

shashi commented Apr 13, 2016

Randy thanks for making this!

minesweeper.jl, is related to #122

@shashi
Copy link
Member

shashi commented Apr 13, 2016

I should add that I intended the current examples to be replaced by #67 . I haven't worked on it in a while

@randyzwitch
Copy link
Contributor Author

Was going to hassle you about that, it's got merge conflicts ;)

On Apr 13, 2016, at 10:31 AM, Shashi Gowda [email protected] wrote:

I should add that I intended the current examples to be replaced by #67 . I haven't worked on it in a while


You are receiving this because you authored the thread.
Reply to this email directly or view it on GitHub

@shashi
Copy link
Member

shashi commented Apr 13, 2016

There you go, I moved the non-doc commits which were causing the conflict to a new drawer-panel branch

@shashi
Copy link
Member

shashi commented Apr 13, 2016

(I'm merging master and fixing things up now)

@shashi
Copy link
Member

shashi commented Apr 13, 2016

Okay I have updated content.jl and graphics.jl which are the files that currently exist. You can hit ctrl+enter on any code cell to execute it.

@zznop
Copy link

zznop commented Apr 26, 2016

@shashi @randyzwitch any idea what is causing mc.jl to not work correctly? I have an app that uses a similar abstraction that exhibits the same behaviour. Sometimes the button fires and sometimes not. I noticed that it started acting this way around the time Reactive.jl v0.3 was tagged which deprecated Input() and lift() - not sure if there's any relation. I've tar'd up the last METADATA.jl that mc.jl worked with and it appears Reactive.jl was at version 0.2.4.

This issue seems hard to pin down because it appears the button fires, but it gets held up once it hits the Reactive function calls - and if you refresh - sometimes the simulation will execute. Perhaps there was a breaking change from Reactive 0.2.4 to 0.3.0 (or maybe it's a Compose or Interact issue). It's almost as if Julia is still compiling the app while the UI is already being rendered. Sometimes if you wait after clicking the button for 30+ seconds I've seen it execute.

@zznop
Copy link

zznop commented Apr 26, 2016

For what it's worth:
the issue seems to be around line 54:

result = map(sampleon(btn, N); typ=Any, init=nothing) do n
    # doesn't reach this point when the simulation doesn't fire
    # despite the browser dev tools showing that the button is detected as clicked
    println("fire!")
    run_simulate(n, running, current_approx)
end

Although again - it's a Heisenbug in that if you refresh repeatedly the simulation runs on occasion - which leads me to believe it's something with compilation

@shashi
Copy link
Member

shashi commented Apr 27, 2016

Reactive 0.3+ uses channels, so the updates are asynchronous - so if you do a push! and immediately start doing some computation, Reactive does not get any time to continue with the update propagation. I think we need to address this in Reactive somehow.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

3 participants