Clojurians
#cider
<
2016-03-19
>

This page is not created by, affiliated with, or supported by Slack Technologies, Inc.

reefersleep07:03:07

@benedek: I tried lein upgrade but was told that I would have to delete my 2.6.1 batfile, which I take means that I'm already on the newest version

reefersleep08:03:59

I still can't lein jack-in, after reinstalling Spacemacs, updating Spacemacs, updating packages, putting meaningful stuff in ~/.lein/profiles.clj, emptying the same... Can't lein upgrade further...

reefersleep08:03:27

Still get the same stacktrace (whose buffer annoyingly vanishes if I try to navigate to it to copy)

reefersleep08:03:35

I'm on (emacs-24.5.1) (spacemacs-0.105.14)

benedek08:03:36

try to clean your profiles.clj. based on the info you posted you use cider/clj-refactor versions which don't need tampering with profiles.clj anymore

benedek08:03:26

And most likely you have a problem because of a transient dependency from profiles.clj - guessing here ofc

reefersleep08:03:01

@benedek: right now, my profiles.clj is {:repl {:plugins [ ] :dependencies [ ]}}

reefersleep08:03:27

And I get the same result 😕

benedek08:03:45

what does lein --version tell you?

reefersleep08:03:45

@benedek: Leiningen 2.6.1 on Java 1.8.0_65 Java HotSpot(TM) 64-Bit Server VM

benedek09:03:05

this looks ok

reefersleep09:03:03

yeah :simple_smile: It's very puzzling.

benedek09:03:53

what does lein deps :tree say?

benedek09:03:15

Also try to reproduce with a newly created empty project

reefersleep10:03:30

lein deps :tree says:

reefersleep10:03:53

c:\dev\clojure\projects\linden>lein deps :tree
warn
 [clojure-complete "0.2.3" :scope "test" :exclusions [[org.clojure/clojure]]]
 [org.clojure/clojure "1.8.0"]
 [org.clojure/tools.nrepl "0.2.6" :scope "test" :exclusions [[org.clojure/clojure]]]

reefersleep10:03:31

A fresh project generated with lein new <name> has the same error.

thiagofm10:03:16

@reefersleep: I fear that the problem could be with windows. I actually don't know how does it work in windows, but it's just a guess

thiagofm10:03:56

I'm pretty sure I can do a clean install of spacemacs in OSX and configure cider afterwards(by following the 2 steps we discussed yesterday)

thiagofm10:03:14

@reefersleep: also, is it lein jack-in? Not like SPC : cider jack in ?

plexus10:03:31

looking at the README there's talk about "var tracing" and "namespace tracing", but it doesn't explain what that means...

plexus10:03:46

can anyone explain what that does or what you would use it for?

reefersleep11:03:40

@thiagofm: To be clear, my clean reinstall of spacemacs consisted of backing up my .spacemacs, deleting .emacs.d, cloning the master branch of spacemacs into .emacs.d, then starting up emacs and letting spacemacs download everything

reefersleep11:03:09

I'm talking about cider-jack-in (SPC m s i)

reefersleep11:03:49

@thiagofm: Everything was working fine until I started messing about with profiles.clj yesterday :simple_smile:

thiagofm11:03:24

If you do a clean install, add the clojure package to .spacemacs, do the two steps config and then restart emacs and try to do cider-jack-in it doesn't work?

reefersleep11:03:17

I can give it a clean go and see :simple_smile: Why do I need the clojure package, though - doesn't spacemacs automatically download this upon SPC m s i?

thiagofm11:03:43

s/package/layer

thiagofm11:03:07

Add the clojure "layer" to .spacemacs

reefersleep11:03:27

Pasted in from my backed up .spacemacs

thiagofm11:03:41

I would do stuff 100% from scratch in that case

thiagofm11:03:05

Because perhaps it could be a problem on your .spacemacs, you never know, so it's good to narrow down things a bit

reefersleep11:03:17

I'll give it a go.

reefersleep11:03:31

@thiagofm: Same result. (When you talk about the two steps config, you are referring to adding

{:repl {:plugins [[cider/cider-nrepl "0.10.0-SNAPSHOT"]
                  [refactor-nrepl "2.0.0-SNAPSHOT"]]
        :dependencies [[alembic "0.3.2"]
                       [org.clojure/tools.nrepl "0.2.12"]]}}
to profiles.clj and then doing SPC msi, right?)

reefersleep11:03:10

The only manipulation I did unto .spacemacs was to add the clojure layer.

malabarba12:03:40

@plexus it's a general Clojure thing. It prints all calls to the function on the repl.

reefersleep12:03:01

Actually, it was in an attempt to get to know cider-debug that I managed to bodge up my REPL. I was interested in trying out tracing as well. What timing :simple_smile:

plexus12:03:29

@malabarba: thanks!

reefersleep12:03:23

@malabarba: Thank you for your work :simple_smile: Do you think I should open an issue regarding my problem - and if so, where do you think it belongs? It seems like a spacemacs issue, but it might actually belong with cider or cider-nrepl...

malabarba12:03:18

File it under cider, with all of the information you have so far. Also Make sure you're using a clean profiles.clj.

reefersleep13:03:37

Thanks @malabarba :simple_smile:

reefersleep13:03:09

I've tried with both a clean and tainted profiles.clj, for the record 👌

reefersleep13:03:55

I followed the advice in the Troubleshooting part of the Cider README and activated toggle-debug-on-error, and managed to catch something meaningful

reefersleep13:03:03

could not start nrepl server: clojure.lang.Compiler$CompilerException: java.io.FileNotFoundException: Could not locate mranderson047/toolsnamespace/v03v0_alpha3/clojure/tools/namespace/parse__init.class or mranderson047/toolsnamespace/v0v3v0_alpha3/clojure/tools/namespace/parse.clj on classpath: , compiling:(refactor_nrepl/core.clj:1:1)

reefersleep13:03:32

It doesn't help me in a google search, but I think I saw some trouble with mranderson mentioned somewhere. Does anyone recognise this?

reefersleep13:03:29

The "Troubleshooting" section also mentions looking in the *Messages* buffer or the *nrepl-messages* buffer. I can't find these. Does anyone know how to reach them?

thiagofm14:03:27

@reefersleep: should be on SPC p b or C-x b

thiagofm14:03:15

Looks like a problem with clojure/java/classpath

thiagofm14:03:30

which I have absolutely no idea how to fix 😆

reefersleep14:03:26

:simple_smile:

reefersleep14:03:57

@thiagofm: SPC b b <name_of_buffer>

reefersleep14:03:07

Works for me :simple_smile:

reefersleep14:03:18

So I have the whole stacktrace. But it's not very interesting.

thiagofm14:03:35

Perhaps rm -rf . and curse java? Not sure if I can help more

thiagofm14:03:55

Do you also have the same error when you run lein repl from the terminal?

reefersleep14:03:40

nope, lein repl is healthy

thiagofm14:03:18

Do you have nrepl in your project as a dep?

reefersleep14:03:08

I've tried with a clean lein new, too

thiagofm14:03:29

I wonder if that helps

thiagofm14:03:53

Hm, I have a project that should work, if you wanna try: https://github.com/thiagofm/haxlife

thiagofm14:03:07

You have to press , s I

thiagofm14:03:16

cider-jack-in-clojurescript

thiagofm14:03:30

It's weird, you probably have exactly the same config as me

thiagofm14:03:39

in a different OS

reefersleep14:03:07

I hit the same exception

reefersleep14:03:15

After downloading some deps

reefersleep14:03:16

Looks like exactly the same error, but I have

c:\dev\clojure\projects\haxlife>lein --version
Leiningen 2.6.1 on Java 1.8.0_65 Java HotSpot(TM) 64-Bit Server VM

reefersleep14:03:32

But maybe I should attempt to reopen the issue

reefersleep14:03:36

? :simple_smile:

thiagofm14:03:21

❯ lein -v Leiningen 2.5.3 on Java 1.8.0_72 Java HotSpot(TM) 64-Bit Server VM

thiagofm14:03:30

also downgrade your lein version and try again

reefersleep14:03:46

Get the same output with SPC m s i after switching to 2.5.3

fommil14:03:51

is there a key command to compile my code and see linter warnings? or does clojure not work that way?

reefersleep15:03:12

@fommil: I don't think it "normally" works that way, although there are many ways to work with Clojure. My way is to open a REPL, write code in my clj/cljs/cljc file (whichever I'm working on), experiment in the REPL, refine code in the file, then, when I have something that I think works, start loading the file's ns into the REPL so that I have access to all defns and defs from the REPL. Then I can experiment with the stuff I have in the file.

reefersleep15:03:22

I have not used any linting functionality that I know of.

reefersleep15:03:07

I use Spacemacs and Leiningen. When I want to run my project as a whole, I use the appropriate Leiningen or Java command.

fommil16:03:48

I have a dark theme (darcula) and when I get a stacktrace or test failure the default faces are all dark text on a white background. Is there a built in dark theme for this or am I going to have to create my own faces?

reefersleep16:03:52

@fommil: I believe that there are non-darcula dark themes which are more suitable, but I haven't seen them myself :simple_smile: At least there's Borealis, which Colin Flemming, writer of Cursive, recommends: https://github.com/Misophistful/borealis-cursive-theme

reefersleep16:03:14

(I assume you're using Cursive)

fommil16:03:55

@reefersleep: I don't want a new theme, I want cider to stop using its own light theme defaults for stacktraces

fommil16:03:58

no I'm using Emacs

reefersleep18:03:30

@fommil: Then I have no experience that could help you :simple_smile:

reefersleep18:03:41

@thiagofm @benedek omg, I solved the problem. And it was really, really stupid. I, myself, have found a bug in Leiningen for Windows, reported it and submitted a pull request that leaves comments in lein.bat and README.md warning that you should not have a LEINJAR environment variable as well as a different reference for Leiningen on PATH_, as this might mess things up. And here I am, with a LEIN_JAR environment variable still set.

reefersleep18:03:13

Guess I didn't clean up after experimenting while sorting out the Leiningen issue with HyPiRiOn.

reefersleep18:03:26

Removed the LEIN_JAR, and now everything is good. Damn!

reefersleep18:03:55

@malabarba: We'll skip that issue at Cider, then. 😄

benedek18:03:39

Haha nice one!

thiagofm19:03:28

@reefersleep: I TOLD YOU, WINDOWS!!!!

thiagofm19:03:40

@reefersleep: it's great that you finally found the solution, you've been in quite a battle, I remember your struggle from yesterday. A real clojure warrior!

malabarba21:03:49

@fommil cider doesn't force light themes anywhere. In fact, I use a dark theme and never noticed that issue.

malabarba21:03:44

@reefersleep congrats on tracking down that bug. You deserve a prize. :simple_smile:

malabarba21:03:41

@fommil its possible you have some face customisations saved in your custom file. It's also possible you have more than one active theme, and they're conflicting. It's also possible the theme you're using is a little buggy with those faces (though it's unlikely).

reefersleep21:03:10

@thiagofm: Yeah, woooo :parrot::picard-facepalm::rage1::metal::upside_down_parrot:

reefersleep21:03:52

@malabarba: Put my mark on Leiningen, I think that's a pretty cool prize!'

reefersleep22:03:26

So, after all this malarkey, I finally got to test out cider-debug, like I wanted to... Damn sweet, that!

reefersleep22:03:36

I should have known about this long ago!

malabarba23:03:09

😉 🍻 🍻