Closed jmckitrick closed 9 years ago
FWIW I gave this a shot with piggieback installing from master and using my weasel fork https://github.com/swannodette/weasel. I could connect and do basic eval though most of the nice new stuff in 0.0-3123 doesn't seem to work.
If I drop piggieback and use lein trampoline run -m clojure.main
to start my Weasel session, everything seems to work OK (though you'll get some innocuous errors).
I've installed snapshots before, but how do I install directly from your fork?
Jonathon McKitrick
On Tue, Mar 17, 2015 at 11:36 PM, David Nolen notifications@github.com wrote:
FWIW I gave this a shot with piggieback installing from master and using my weasel fork https://github.com/swannodette/weasel. I could connect and do basic eval though most of the nice new stuff in 0.0-3123 doesn't seem to work.
If I drop piggieback and use lein trampoline run -m clojure.main to start my Weasel session, everything seems to work OK (though you'll get some innocuous errors).
Reply to this email directly or view it on GitHub https://github.com/tomjakubowski/weasel/issues/57#issuecomment-82724877.
@j-mckitrick you need to clone the repo and run lein install
inside it. This will install it into your local .m2
repository.
@j-mckitrick I've merged David's PR so you can do a lein install
from a clone of this repository and get his changes.
(I will also cut a release soon, I promise)
I just tried, to no available. I'm not sure what else to try at this point. Is there any other diagnostic info I can get to?
Jonathon McKitrick
On Wed, Mar 18, 2015 at 5:11 PM, Tom Jakubowski notifications@github.com wrote:
(I will also cut a release soon, I promise)
Reply to this email directly or view it on GitHub https://github.com/tomjakubowski/weasel/issues/57#issuecomment-83178327.
To no avail*
Jonathon McKitrick
On Wed, Mar 18, 2015 at 7:59 PM, Jonathon McKitrick jmckitrick@gmail.com wrote:
I just tried, to no available. I'm not sure what else to try at this point. Is there any other diagnostic info I can get to?
Jonathon McKitrick
On Wed, Mar 18, 2015 at 5:11 PM, Tom Jakubowski notifications@github.com wrote:
(I will also cut a release soon, I promise)
Reply to this email directly or view it on GitHub https://github.com/tomjakubowski/weasel/issues/57#issuecomment-83178327 .
I actually spent about 3 hours last night trying to get piggieback to work. No such luck. Without piggieback Weasel works fine. With piggieback I can start the REPL but most of the new REPL features do not work. I don't think we're going to get much progress on this without more help/input from @cemerick at this point.
Well, I won't try to spend much time fighting with it, then.
I assume this should all work with httpkit instead of jetty, correct?
Jonathon McKitrick
On Wed, Mar 18, 2015 at 8:01 PM, David Nolen notifications@github.com wrote:
I actually spent about 3 hours last night trying to get piggieback to work. No such luck. Without piggieback Weasel works fine. With piggieback I can start the REPL but most of the new REPL features do not work. I don't think we're going to get much progress on this without more help/input from @cemerick https://github.com/cemerick at this point.
Reply to this email directly or view it on GitHub https://github.com/tomjakubowski/weasel/issues/57#issuecomment-83228667.
@swannodette do you mean that you're seeing the same error? Or that you were looking for REPLs started via piggieback to behave as those provided by ClojureScript itself? That won't happen until someone reformulates nREPL support for ClojureScript REPLs using the new bits it provides.
I'll be doing it at some point, but it's not a blocker for me personally at the moment, so not a top priority.
Whoops, my bad, thought I was commenting on cemerick/piggieback#48. :-P
@cemerick sorry, not the same error. In order to avoid @j-mckitrick's specific problem all that needs to happen is that piggieback needs to supply the :output-dir
REPL option. I can push my various fixes to my fork tomorrow. I think with some further guidance from you we can make piggieback work reasonably well until something better lands. I don't use piggieback or weasel, but I'd be happy to see people have a near term solution for Cider, Cursive, etc. with more recent versions of ClojureScript.
@swannodette , how do you develop with clojurescript then? I mean, the REPL is fine for exploring and debugging etc, but what about actually editing and navigating source code?
On Wednesday, March 18, 2015, David Nolen notifications@github.com wrote:
@cemerick https://github.com/cemerick sorry, not the same error. In order to avoid @j-mckitrick https://github.com/j-mckitrick's specific problem all that needs to happen is that piggieback needs to supply the :output-dir REPL option. I can push my various fixes to my fork tomorrow. I think with some further guidance from you we can make piggieback work reasonably well until something better lands. I don't use piggieback or weasel, but I'd be happy to see people have a near term solution for Cider, Cursive, etc. with more recent versions of ClojureScript.
Reply to this email directly or view it on GitHub https://github.com/tomjakubowski/weasel/issues/57#issuecomment-83244928.
Jonathon McKitrick
@cemerick @tomjakubowski Weasel and piggieback should work with httpkit, not just jetty, correct?
@j-mckitrick Weasel should work with httpkit, modulo horrifying version mismatch bugs because Weasel itself uses httpkit for the WebSocket server.
@tomjakubowski Here's what I'm seeing now, with piggieback 0.2.0 and weasel 0.6.0:
mckitrick@jmckitrick-mbp.local ~/Code/pts % rlwrap lein trampoline run -m clojure.main feature/weasel-repl ? 16:36:05 Clojure 1.6.0 user=> (require 'weasel.repl.websocket) nil user=> (cemerick.piggieback/cljs-repl :repl-env (weasel.repl.websocket/repl-env :ip "0.0.0.0" :port 9001)) IllegalArgumentException No value supplied for key: weasel.repl.websocket.WebsocketEnv@49ac47e0 clojure.lang.PersistentHashMap.create (PersistentHashMap.java:77) user=>
@j-mckitrick Drop the :repl-env
. And, trampoline likely will not work.
@cemerick
I just tried that, and now we're back to can't change/establish root binding of cljs-repl-env with set....
On Wed, Apr 8, 2015 at 4:47 PM Chas Emerick notifications@github.com wrote:
@j-mckitrick https://github.com/j-mckitrick Drop the :repl-env. And, trampoline likely will not work.
Reply to this email directly or view it on GitHub https://github.com/tomjakubowski/weasel/issues/57#issuecomment-91032662.
@cemerick @tomjakubowski I think I found the issue... though weasel is fine with the latest stable clojurescript, it looks like piggieback requires bleeding edge. Hopefully that solves the issue.
Glad to hear it!
I'm running 0.0-3123.
Here's my server-side setup:
(ns pts.dev (:require [cemerick.piggieback :as piggieback] [weasel.repl.websocket :as weasel]))
(println "Loaded dev")
(defn browser-repl [] ;;(require 'weasel.repl.websocket) (piggieback/cljs-repl :repl-env (weasel/repl-env :ip "0.0.0.0" :port 9001)))
on the client side:
(defn browser-repl [](if-not %28ws-repl/alive?%29 %28println))))
Here's the error I see in the Firefox console: "Result nil" main.js:21579:0 "goog.require could not find: cljs.core" main.js:19687:6
Error: goog.require could not find: cljs.core main.js:19689:10 TypeError: client.home is undefined home:39:5 "Opened Websocket REPL connection" main.js:75106:10 "goog.require could not find: cljs.core"