-
Notifications
You must be signed in to change notification settings - Fork 31
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
NPE in repl-client-js #22
Comments
Hrm, I'm not sure how that could ever happen. Is the affected project public so I can take a look? |
unfortunately no, but my workflow was to run the following: (def repl-env
(reset! cemerick.austin.repls/browser-repl-env
(cemerick.austin/repl-env)))
(cemerick.austin.repls/cljs-repl repl-env) Then disconnect with (cemerick.austin.repls/cljs-repl repl-env) |
I think you mean If you do that, then REP Loop will stop, which causes the environment to be teared down. In Austin, this translates into the session being dissoc'ed from the global map. This explains the NPE, though of course it's a horrible (lack of) error message! There's not a lot that Austin can (or should, I think) do differently here (error messages aside). Re: workflow, why are you quitting and then attempting to "reconnect"? Is it so you can move back and forth between Clojure and ClojureScript? If so, I'd suggest having dedicated REPL sessions; one for Clojure, and perhaps many for each ClojureScript runtime. Your nREPL client should have a "clone session" operation that will allow you to create the latter from the former at any time without creating multiple connections to the nREPL backend… |
It's the latter - I was trying to get back to the main repl and reboot, since I was getting SocketClosedException (or something phonetically similar, working from memory) on certain page reloads when the browser repl tried to reconnect. I'll try cloning my nrepl (now cider, I guess?) session and report back if I can repeat any recreations of that bug. Thanks, Chas! Austin is fantastic. I pushed my first Clojurescript code out to master yesterday; Austin makes the repl experience really delightful. This is a feeling I've been chasing for some time. |
Sounds unfriendly. If you can replicate the exception, I'd love to look at it. If you ever do want to get a fresh REPL, you have to quit, create and Glad you've found it useful so far, despite the sharp edges. I'll get a better error message in there for the post-quit reconnection failure shortly. |
Great, good to know. So the repl-environment is hosed once someone disconnects... makes sense, and a good error message should clear that up. I'll add some docs to my internal project. |
@sritchie Did you end up verifying that your emacs config was somehow provoking your Austin troubles? |
No, even a slim config ended up flaming out. Bumping Xmx delayed the issue, but it still arrived.— On Wed, Feb 12, 2014 at 5:24 AM, Chas Emerick [email protected]
|
Closing this; the original issue is now embodied in #51. |
This happens on a page reload every so often, and I can't recover:
The text was updated successfully, but these errors were encountered: