Fork me on GitHub
#cider
<
2018-05-17
>
mikerod00:05:50

They seem perfectly differentiated to me. One has a / and the other has a - 😜

iwannaseethelight05:05:02

hey folks, i’m trying to get this project to work with cider: https://github.com/rogerallen/hello_lwjgl

iwannaseethelight05:05:46

if you clone and do a lein run it works fine, but if you do a M-x cider-jack-in i get this error:

iwannaseethelight05:05:11

at any rate, when I take a look at *Messages*, M-x cider-jack-in seems to be ignoring -XstartOnFirstThread in project.clj

iwannaseethelight05:05:17

any leads? thanks in advance!

iwannaseethelight05:05:26

A more general question seems to be - why is M-x cider-jack-in ignoring this: -XstartOnFirstThread

bozhidar06:05:01

@sashton Yeah, actually I do. Soon cider-nrepl will become orchard-nrepl. This both saves the naming issue and more importantly underlies the fact that cider-nrepl is hardly specific to CIDER. I’d like to see more tool authors involved in all the foundational libraries.

bozhidar06:05:51

@iwannaseethelight What do you mean by CIDER ignores it? It will happily run whatever you tell it to run as command line arguments.

iwannaseethelight06:05:10

hey @bozhidar - love the project!

iwannaseethelight06:05:36

I can stick a bunch of things into jvm-opts in project.clj and they show up in *Messages* when booting up the repl via cider-jack-in, but if you specify the -XstartOnFirstThread option it does not show up in *Messages* - I guess that doesn’t necessarily mean it’s not getting picked up, but trying to start that lwjgl project fails and says to specify the same option

iwannaseethelight06:05:57

just not sure why

iwannaseethelight06:05:29

in that project btw, they have a different approach where they boot up an nrepl server in their game itself and then cider-connect to it

bozhidar06:05:00

I see. In general CIDER is not involved at all in starting the REPL - it just lein/boot/whatever you choose to invoke, that’s why I meant CIDER can’t really ignore anything of this type.

joost-diepenmaat11:05:00

I’m trying to do cider-jack-in (with and wihout a project) and it fails to start with error in process sentinel: Could not start nREPL server: Exception in thread "main" java.io.FileNotFoundException: Could not locate cider/nrepl/middleware/util/misc__init.class or cider/nrepl/middleware/util/misc.clj on classpath., compiling:(refactor_nrepl/middleware.clj:1:1)

joost-diepenmaat11:05:35

For both lein based projects, and clj outside of a project. This is with the latest stable CIDER>

joost-diepenmaat11:05:12

I gather that refactor-nrepl has issues, so I would be glad to just turn that off if that fixes the problem but I cannot find out how!

joost-diepenmaat12:05:00

hmm. turning off “Cider Inject Dependencies At Jack In” does not seem to help

joost-diepenmaat12:05:15

Starting nREPL server via clojure -e '(require (quote cider-nrepl.main)) (cider-nrepl.main/init ["refactor-nrepl.middleware/wrap-refactor", "com.billpiel.sayid.nrepl-middleware/wrap-sayid", "cider.nrepl/cider-middleware"])'...
error in process sentinel: nrepl-server-sentinel: Could not start nREPL server: Exception in thread "main" java.io.FileNotFoundException: Could not locate cider_nrepl/main__init.class or cider_nrepl/main.clj on classpath. Please check that namespaces with dashes use underscores in the Clojure file name.

joost-diepenmaat12:05:44

so it starts up differently but still errors

joost-diepenmaat12:05:50

previously it was

joost-diepenmaat12:05:52

Starting nREPL server via clojure -Sdeps '{:deps {org.clojure/tools.nrepl {:mvn/version "0.2.13"} refactor-nrepl {:mvn/version "2.3.1"} com.billpiel/sayid {:mvn/version "0.0.16"} cider/cider-nrepl {:mvn/version "0.17.0"}}}' -e '(require (quote cider-nrepl.main)) (cider-nrepl.main/init ["refactor-nrepl.middleware/wrap-refactor", "com.billpiel.sayid.nrepl-middleware/wrap-sayid", "cider.nrepl/cider-middleware"])'...
error in process sentinel: nrepl-server-sentinel: Could not start nREPL server: Exception in thread "main" java.io.FileNotFoundException: Could not locate cider/nrepl/middleware/util/misc__init.class or cider/nrepl/middleware/util/misc.clj on classpath., compiling:(refactor_nrepl/middleware.clj:1:1)

bozhidar12:05:24

@joost-diepenmaat You need to disable the injection of the refactor-nrepl (as mentioned in the troubleshooting page).

bozhidar12:05:54

You’re using some version of clj-refactor.el that’s not compatible with CIDER. I think the only version that work OK is their current master.

joost-diepenmaat12:05:57

If turned off the wrong knob

bozhidar12:05:33

(setq cljr-inject-dependencies-at-jack-in nil)

joost-diepenmaat12:05:46

should use cljr-inject-dependencies-at-jack-in instead of cider-inject-dependencies-at-jack-in

bozhidar12:05:45

You definitely want CIDER to inject its own deps.

joost-diepenmaat12:05:24

yeah doing that fixed the problem

bozhidar12:05:37

You’re welcome! cider

ramblurr15:05:11

when I call cider-eval-buffer after jacking in to a cljs repl I get the message user-error: ‘cider-eval-buffer’ needs a ClojureScript REPL. \n If you don’t know what that means, you probably need to jack-in (‘, "’).

ramblurr15:05:26

i have the repl buffer open.. and it seems to work

ramblurr15:05:20

total emacs+cider noob here so I could be doing something wrong

ramblurr15:05:01

if i jack-in again, it warns me that a repl buffer already exists

ramblurr15:05:53

i think the repl that opened is a clojure repl not a cljs repl..

dpsutton16:05:53

are you trying to work with clojurescript or clojure?

ramblurr16:05:42

Ok.. new data, found this error in one of the repl buffers: ClassNotFoundException cemerick.piggieback java.net.URLClassLoader.findClass (URLClassLoader.java:381)

jumar07:05:56

@ramblurr just a wild guess: you may want to check your java version and try 1.8 if you run with 1.9 or 1.10

ramblurr08:05:21

thanks for the tip. I was already using 1.8. However this morning I came back to this issue and found a small typo in my project.clj... the typo didn't cause any build errors, but correcting it resolved this issue.

ramblurr08:05:52

So cider + cljs repl is working now 🎆

ramblurr16:05:02

But I do have piggieback in my deps list

ramblurr16:05:59

😕 the cider/emacs vids made this look much easier heh

ramblurr16:05:11

i obviously have something screwed up

bozhidar16:05:06

@ramblurr Make sure you’re using cider/piggieback not the older cemerick/piggieback.

bozhidar16:05:16

(in your project dependencies I mean)

bozhidar16:05:44

Hmm, actually I see in your error you’re using an older version of CIDER that requires that older package.

bozhidar16:05:53

Aren’t you on CIDER 0.17?

fedreg18:05:44

Hi all, quick debugger question…. The debugger works great on libraries that I’m pulling in as dependencies. I call cider-debug-defun-at-point and it works beautifully. However, how do I now turn debugging off on that function?? If I’m debugging an expression in my own project I just evaluate it to turn off the debugger. But not sure how to do that on an external namespace…. Hope that makes sense! Any help would be greatly appreciated.

ramblurr19:05:55

@bozhidar confirmed i am using cider/piggieback and I'm using spacemacs.. need to check the cider version it uses

tanzoniteblack20:05:45

@fedreg calling cider-eval-defun-at-point will re-compile that function without the debugger

tanzoniteblack20:05:12

(though cider-eval-buffer should still work even in read-only mode?)

fedreg20:05:27

@tanzoniteblack Thx! Neither of those work for me…. If it works for you tho it must be something in my local setup. I can dig deeper. Wasn’t sure if there was some other func that I was not seeing

tanzoniteblack20:05:52

let me double check, I told you that working off memory

tanzoniteblack20:05:28

yep, that's working for me running CIDER 0.17.0 (Andalucía) with cider loading the cider-nrepl into lein for me (i.e. I'm not manually specifying the additional libraries anywhere)

fedreg20:05:39

Alright, I’ll debug locally. At least now I know that I should be able to turn off the debugger on read-only file. Appreciate the help!