This page is not created by, affiliated with, or supported by Slack Technologies, Inc.
2019-02-11
Channels
- # adventofcode (8)
- # announcements (1)
- # arachne (23)
- # beginners (146)
- # boot (4)
- # calva (2)
- # cider (48)
- # cljs-dev (17)
- # clojure (214)
- # clojure-austin (2)
- # clojure-berlin (1)
- # clojure-europe (9)
- # clojure-italy (5)
- # clojure-nl (2)
- # clojure-sanfrancisco (2)
- # clojure-spec (124)
- # clojure-uk (67)
- # clojured (3)
- # clojurescript (95)
- # community-development (7)
- # cursive (68)
- # data-science (1)
- # datomic (80)
- # emacs (19)
- # figwheel (3)
- # figwheel-main (5)
- # fulcro (61)
- # javascript (2)
- # kaocha (1)
- # off-topic (25)
- # pathom (21)
- # pedestal (1)
- # perun (4)
- # reitit (11)
- # ring-swagger (2)
- # shadow-cljs (55)
- # spacemacs (4)
- # sql (8)
- # test-check (16)
- # tools-deps (2)
- # vim (13)
- # yada (4)
@vincent.cantin There is a plan to investigate it, yes. There are some interesting implications, because REBL has the GUI in the actual REPL process, whereas with Cursive the GUI is in an external process (IntelliJ itself). I still don’t know what the full implications of that are, so no promises.
@kenny I’m testing the git lib missing SHA fix. However I can’t reproduce what you’re seeing - for me, if the SHA is invalid, then when I refresh the project the Build toolwindow pops up with a pretty clear message. Is there some other circumstance when that’s less visible?
@kenny I’ve investigated this, and I can’t see a way to fix it. Errors are deliberately suppressed for auto-import refreshes, presumably because errors are common while you’re editing build files. I can’t see a way to modify that behaviour.
The best workaround I can suggest is to manually refresh after changing SHAs, which does show the error.
Oh right, you wouldn't want to message the user while they are editing it. I hit this case all the time though -- I accidentally copy a SHA from the wrong repo or forgot to push a SHA -- and the results are confusing. Perhaps a better solution would be if you try and start a REPL after the refresh and the build failed, alert the user.
No it does not tell me. This is what I do: 1. Start with a valid git SHA 2. Change the SHA to an invalid one 3. Hit save & wait for the auto import to finish 4. Hit REPL play button 5. No error
Right. I’m not sure at which point there Cursive could realistically detect and show an error.
Even printing a message in the actual REPL that the classpath is "stale" or does not match the classpath in deps.edn
But hold on - when you start the REPL in step 4, do you still get the previous classpath?
Once you’ve updated deps.edn, if you run a REPL from a Run Config that uses that deps.edn it should definitely use the new one.
@kenny I can’t reproduce that. Here’s what I’m doing: 1. Create a deps project with a git dep with a valid SHA. Then sync it etc. 2. Running a REPL with this works fine. 3. Modify SHA to be invalid, press save, check in Build toolwindow that message appears. 4. Run REPL again, and I get an error Error creating Run Parameters, and a message in the Run toolwindow about the SHA.
I just fixed a bug where the message about the SHA in step 4 occasionally wouldn’t be shown, but under normal circumstances it would.
Let me try this with the current published version, in case the version I’m running has something fixed that’s affecting this.
Hi, I'm trying to create a deps.edn project and got the error 'Cannot execute: Clojure command not configured'. I installed Clojure using brew on mac and the clojure command is in my PATH. Is there another PATH I have to set up in IntelliJ?
Nevermind, I went to the 'Clojure Deps' settings, made a change to use 'toolds.deps' and then back to 'CLI' tools and I didn't get the error anymore.
Nevermind, I went to the 'Clojure Deps' settings, made a change to use 'toolds.deps' and then back to 'CLI' tools and I didn't get the error anymore.
Hi there
Hi - I sent something to the mailing list, but I wonder if this would be a better place for it: is it possible the Organize Imports
function will ever work. I would love Cursive to clean up my :requires
and :imports
I'm gonna extract the clean-ns
op from https://github.com/clojure-emacs/refactor-nrepl for easy, editor-agnostic usage pretty soon.
Keep an eye on #announcements ... maybe in a couple weeks?
I always wondered why "refactors" were tied to a specific editor, rather than being a framework that any editor could plug into
luckily refactor-nrepl is agnostic. but IIRC it still needs to talk over the nrepl protocol. I want to make it easier - just one fn call away from your repl
Hi, I wonder if anybody had any trouble with Cursive v1.8.1-eap2-2018.3, tools.deps and Clojure 1.10.0.?
perhaps you could explain what trouble you’re seeing?
clj -A:main
runs just fine from the shell. (using clojure 1.9.0 in deps)
However from Cursive, I do get:
Exception in thread “main” java.io.FileNotFoundException: -m red-robin.main (No such file or directory) when using
from within Cursivedoes your deps.edn :paths
match the root of your source?
I wonder if this is related to have clojure 1.9.0 in tools.deps, but also having clojure 1.10 installed by brew :thinking_face: I even tried to downgrade clojure to 1.9.0 but could not using brew.
any brew installation should work with any Clojure version
Using brew, I can only install 1.10. Could not figure out how to install 1.9 after 1.10 was released.
My project currently does not run on 1.10
Call to clojure.core/ns did not conform to spec.
But I will investigate that later.After upgrading to 1.10, Cursive stopped working, that is why I suspected a relation. But I think Cursive also upgraded, so now I am not sure what was the cause.
you can use something like brew switch clojure 1.9.0.397
to switch to a different (older or newer) version
I have tried that, but got
Error: clojure does not have a version "1.9.0.397" in the Cellar.
well, it has to be a version you’ve installed in the past - brew info clojure
I don’t think Cursive does anything with brew. you may be confusing two different things here
Maven is used to download versions of the clojure jar (the language itself) - those versions are usually like 1.9.0 or 1.10.0
I know. What I am saying is that on brew I can only get clojure 1.10
$ brew info clojure
clojure: stable 1.10.0.411
The Clojure Programming Language
/usr/local/Cellar/clojure/1.10.0.411 (9 files, 21.1MB) *
Built from source on 2019-02-11 at 10:58:02
From:
==> Dependencies
Required: rlwrap ✔
==> Requirements
Required: java >= 1.8 ✔
==> Analytics
install: 2,988 (30 days), 12,022 (90 days), 41,661 (365 days)
install_on_request: 2,949 (30 days), 11,821 (90 days), 40,716 (365 days)
build_error: 0 (30 days)
brew is used to install a version of the clojure
and clj
tools which have versions like 1.9.0.397 or 1.10.0.411
the tools are the things that let you run clojure
or clj
at the terminal
many tools (clj, lein, boot, Cursive, etc) may cause the Clojure jar to get downloaded and cached in the Maven repository
that error you posted before (Call to clojure.core/ns did not conform to spec.) will prevent a namespace from loading, so is likely to be a problem for you
I will try to go deeper into what Cursive is trying to run, to check out why 1.9.0 is failing.
Thanks @alexmiller 🙇
Interesting. From the shell, both versions below do work
clj -m red-robin.main
clj -A:main
From Intellij, it breaks on:
Clojure 1.9.0
nREPL server started on port 64956 on host 127.0.0.1
Exception in thread "main" java.io.FileNotFoundException: -m red-robin.main (No such file or directory)
at java.io.FileInputStream.open0(Native Method)
...
at clojure.main.main(main.java:37)
Because it is passing “-m red-robin.main”from deps.edn straight to:
public static void main(String[] args) {
REQUIRE.invoke(CLOJURE_MAIN);
MAIN.applyTo(RT.seq(args));
}