-
-
Notifications
You must be signed in to change notification settings - Fork 75
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
body!
stopped working (Julia 1.0, linux)
#154
Comments
Is there a way that I can try to reload |
Hey, let's try to start with some debugging information. What version of julia are you using? Also, ideally, can you share what packages you have installed? If you're using a julia version >= 0.7, i think the easiest way to that is to cat your
|
Ah, okay, actually, I have a guess about what might be going on. I'm not sure why this would have been working for you previously, other than chance, but my guess is that you're seeing this problem due to the asynchronous nature of those functions. In the current release version of Blink, both of those methods are asynchronous, meaning that they return immediately, rather than blocking until the entire process is finished. So if you run those two statements too close together, back-to-back, they will fail in exactly the manner you've just described: using Blink
w = Window(); sleep(5.0); # In practice, probably just 1 or 2 seconds will be okay here, but better safe than sorry.
body!(w, "test"); sleep(1.0); # Probably only need 0.5 seconds or so.. That should fix your problem! However, of course, it's silly that those are async. In the master branch, there's already an option to make |
Hey @NHDaly Thanks!
The only things in my
You can see my manifest here: Manifest.toml.txt
Yeah, I definitely have tried letting it sit for a long time
gives the same negative result. Another potential useful piece of information is that the body of the window after loading it is just
|
Also:
which seems to mean that it can't evaluate any js. |
Yeah, I can repro this -- |
(I just restarted a Travis build for master)
…On Sat, Sep 22, 2018, 3:22 PM Sebastian Pfitzner ***@***.***> wrote:
Yeah, I can repro this -- main.html is never loaded for me either.
—
You are receiving this because you were mentioned.
Reply to this email directly, view it on GitHub
<#154 (comment)>,
or mute the thread
<https://github.com/notifications/unsubscribe-auth/ABgkEYv_8FRB1mnYFc2Mb0QYjBCFmxTFks5udo3kgaJpZM4W1JIS>
.
|
Hmm, okay, it definitely seems like the latest release of HTTP.jl broke us! :) I'm glad I've tracked it down. I can see that just reverting HTTP.jl to the previous release fixes our test: (tmp) pkg> add HTTP#v0.6.15
Updating git-repo `https://github.com/JuliaWeb/HTTP.jl.git`
Resolving package versions...
┌ Warning: julia version requirement for package HTTP not satisfied
└ @ Pkg.Operations /Users/osx/buildbot/slave/package_osx64/build/usr/share/julia/stdlib/v0.7/Pkg/src/Operations.jl:173
Updating `Project.toml`
[cd3eb016] ~ HTTP v0.7.0+ #d388371 (https://github.com/JuliaWeb/HTTP.jl.git) ⇒ v0.7.0+ #382b6c3 (https://github.com/JuliaWeb/HTTP.jl.git)
Updating `Manifest.toml`
[cd3eb016] ~ HTTP v0.7.0+ #d388371 (https://github.com/JuliaWeb/HTTP.jl.git) ⇒ v0.7.0+ #382b6c3 (https://github.com/JuliaWeb/HTTP.jl.git)
julia0.7> using Blink
julia0.7> w = Window();
julia0.7> body!(w, "test"); # This works That release was supposed to be about adding v0.7 support, so i guess some things might have changed. The changelog doesn't imply we need to do anything different, so maybe it's a bug on their end... |
I've been having issues in the last couple of days with the web ecosystem that were resolved by updating WebSockets.jl to master or v1.0.1. Perhaps you could try that? |
Mmm thanks Robin, I think you're right. I tried updating WebSockets, but that downgraded HTTP, which didn't let me test your theory: (tmp) pkg> add WebSockets#v1.0.1
Updating registry at `~/.julia/registries/General`
Updating git-repo `https://github.com/JuliaRegistries/General.git`
Updating git-repo `https://github.com/JuliaWeb/WebSockets.jl.git`
Resolving package versions...
Updating `Project.toml`
[cd3eb016] ↓ HTTP v0.7.0 ⇒ v0.6.14
[104b5d7c] + WebSockets v1.0.2+ #ce0a16d (https://github.com/JuliaWeb/WebSockets.jl.git)
Updating `Manifest.toml`
[cd3eb016] ↓ HTTP v0.7.0 ⇒ v0.6.14
[104b5d7c] ↑ WebSockets v1.0.0 ⇒ v1.0.2+ #ce0a16d (https://github.com/JuliaWeb/WebSockets.jl.git) So then I (tmp) pkg> status
Status `Project.toml`
[ad839575] Blink v0.8.0+ [`~/.julia/dev/Blink`]
[132d396a] HTTP v0.7.0 [`~/.julia/dev/HTTP`]
[104b5d7c] WebSockets v1.0.2+ #ce0a16d (https://github.com/JuliaWeb/WebSockets.jl.git)
julia0.7> using Blink
julia0.7> w = Window();
julia0.7> body!(w, "test"); # This works So it seems that we need a newer WebSockets if we're going to be using the newer HTTP. Does anyone understand what's controlling the installation of the various versions? Clearly it's not our REQUIRE file, since that's still asking for How can we tell Julia we'd like v1.0.1+ pretty please? |
Pretty sure you can just put
into REQUIRE, since that's a lower bound. |
Ah, thanks, that's the part I was missing. 😄 Okay cool, so I've made that change in this commit: NHDaly@fa9af71 and pushed it to this branch: https://github.com/NHDaly/Blink.jl/tree/WebSocketsDependency. This does indeed fix the bug. On a clean project, it causes (tmp) pkg> status
Status `Project.toml`
(tmp) pkg> add https://github.com/NHDaly/Blink.jl#fa9af71dc
Cloning git-repo `https://github.com/NHDaly/Blink.jl`
Updating git-repo `https://github.com/NHDaly/Blink.jl`
Resolving package versions...
Updating `Project.toml`
[ad839575] + Blink v0.8.0+ #fa9af71 (https://github.com/NHDaly/Blink.jl)
Updating `Manifest.toml`
[bf4720bc] + AssetRegistry v0.1.0
[9e28174c] + BinDeps v0.8.10
[b99e7846] + BinaryProvider v0.5.0
[ad839575] + Blink v0.8.0+ #fa9af71 (https://github.com/NHDaly/Blink.jl)
[34da2185] + Compat v1.1.0
[864edb3b] + DataStructures v0.13.0
[de31a74c] + FunctionalCollections v0.4.0
[cd3eb016] + HTTP v0.6.14
[9fb69e20] + Hiccup v0.2.2
[83e8ac13] + IniFile v0.5.0
[97c1335a] + JSExpr v0.3.1
[682c06a0] + JSON v0.19.0
[50d2b5c4] + Lazy v0.13.1
[1914dd2f] + MacroTools v0.4.4
[739be429] + MbedTLS v0.6.2
[ffc61752] + Mustache v0.5.2
[a975b10e] + Mux v0.5.3
[510215fc] + Observables v0.2.2
[bac558e1] + OrderedCollections v1.0.1
[fa939f87] + Pidfile v1.1.0
[189a3867] + Reexport v0.2.0
[ae029012] + Requires v0.5.2
[30578b45] + URIParser v0.4.0
[0f1e0344] + WebIO v0.3.4
[104b5d7c] + WebSockets v1.0.2
[cc8bc4a8] + Widgets v0.4.2
[2a0f44e3] + Base64
[ade2ca70] + Dates
[8bb1440f] + DelimitedFiles
[8ba89e20] + Distributed
[7b1f6079] + FileWatching
[b77e0a4c] + InteractiveUtils
[76f85450] + LibGit2
[8f399da3] + Libdl
[37e2e46d] + LinearAlgebra
[56ddb016] + Logging
[d6f4376e] + Markdown
[a63ad114] + Mmap
[44cfe95a] + Pkg
[de0858da] + Printf
[3fa0cd96] + REPL
[9a3f8284] + Random
[ea8e919c] + SHA
[9e88b42a] + Serialization
[1a1011a3] + SharedArrays
[6462fe0b] + Sockets
[2f01184e] + SparseArrays
[10745b16] + Statistics
[8dfed614] + Test
[cf7118a7] + UUIDs
[4ec0a83e] + Unicode
Building Blink → `~/.julia/packages/Blink/VrROa/deps/build.log`
(tmp) pkg> What's the next step for this repo? I can send a PR to merge that into master, but should we also cherry-pick it in to the current release? I based that commit off of Blink v0.8.0, so it would be a clean merge if we want to do just a single bug-fix type version bump to |
The other simple option is just to merge into master and then cut a new release, but idk if people feel that master is ready for that? I'm not super familiar with the release process here! :) |
Okay, yeah, I think that would be okay. # check that <!DOCTYPE html> was declared
-@test startswith(Blink.maintp.tokens[1][2], "<!DOCTYPE html>\n")
+@test startswith(Blink.maintp.tokens[1].value, "<!DOCTYPE html>\n") (tmp) pkg> add Blink#master
Updating registry at `~/.julia/registries/General`
Updating git-repo `https://github.com/JuliaRegistries/General.git`
Cloning git-repo `https://github.com/JunoLab/Blink.jl.git`
Updating git-repo `https://github.com/JunoLab/Blink.jl.git`
Resolving package versions...
Installed DataStructures ─ v0.14.0
Updating `Project.toml`
[ad839575] + Blink v0.8.0+ #master (https://github.com/JunoLab/Blink.jl.git)
Updating `Manifest.toml`
[bf4720bc] + AssetRegistry v0.1.0
[9e28174c] + BinDeps v0.8.10
[b99e7846] + BinaryProvider v0.5.0
[ad839575] + Blink v0.8.0+ #master (https://github.com/JunoLab/Blink.jl.git)
[34da2185] + Compat v1.1.0
[864edb3b] + DataStructures v0.14.0
[de31a74c] + FunctionalCollections v0.4.0
[cd3eb016] + HTTP v0.6.14 # <--------------------
[9fb69e20] + Hiccup v0.2.2
[83e8ac13] + IniFile v0.5.0
[97c1335a] + JSExpr v0.3.1
[682c06a0] + JSON v0.19.0
[50d2b5c4] + Lazy v0.13.1
[1914dd2f] + MacroTools v0.4.4
[739be429] + MbedTLS v0.6.2
[ffc61752] + Mustache v0.5.2
[a975b10e] + Mux v0.5.3
[510215fc] + Observables v0.2.2
[bac558e1] + OrderedCollections v1.0.1
[fa939f87] + Pidfile v1.1.0
[189a3867] + Reexport v0.2.0
[ae029012] + Requires v0.5.2
[30578b45] + URIParser v0.4.0
[0f1e0344] + WebIO v0.3.4
[104b5d7c] + WebSockets v1.0.2 # <--------------------
... So I guess, I don't really understand why it's pulling So I'll go ahead and merge that into master, and then I'll just go ahead and cut another tag, |
(#155 merged; |
Alright, the tag has been merged into METADATA. I've verified locally that this is all fixed! :) I'm going to close this now. @zsunberg If you can, please |
Hi @NHDaly , Thank you so much for fixing this! Works great now! |
:D I'm glad! :) |
Sorry I didn't respond earlier--there's definitely something fishy going on with the version compatibilities of WebSockets and HTTP, but I haven't dug into what it might be. But bounding the WebSockets version seems like a perfectly good solution, and I'm glad it's all working now. |
I'm pretty sure I've found the root cause: JuliaWeb/WebSockets.jl#119 |
Stopped working for me. The javascript console displays the error:
Uncaught ReferenceError: Blink is not defined
I have gathered from other issues that this means it is not correctly loading some javascript during initialization. However there is no other indication of what is going wrong except an "Electron Security Warning".In an effort to fix this, I deleted everything in my
.julia
folder (exceptdev
, which does not have Blink in it) and reinstalled. However the result is the same after this. Is there something else that I need to delete to completely start over from scratch?Please assist as this is very important for another tool that I am writing: https://github.com/JuliaPOMDP/POMDPs.jl!
Thank you!
The text was updated successfully, but these errors were encountered: