cursive

Issues at: https://git.io/cursive-issues
onetom 2020-12-09T10:24:20.362Z

how does Cursive determines whether a deps path should be a Sources root or a Test sources root? can i somehow avoid this? manually marking the folder as sources root is not enough; Refresh Clojure Deps Project reverts it back to test sources. i have a directory which has only 1 clj file in it and it keeps being recognized as test sources. it doesn't contain tests, though im requiring clojure.test in it, because i've implemented some feature using kaocha.runner/-main.

cfleming 2020-12-09T10:53:06.362100Z

Source roots are marked as tests if they’re in the test alias. This isn’t configurable at the moment. I made a change a while ago to allow arbitrary source roots to be marked as test roots and Cursive would leave them that way, but I haven’t made the equivalent change in the other direction (which would basically be to leave all source root type markings alone).

cjmurphy 2020-12-09T11:38:28.362300Z

I just have an alias with a different name: :tset.

:tset      {:extra-paths ["src/test"]}

dima 2020-12-09T13:08:30.362600Z

And there is one more plugin for that https://plugins.jetbrains.com/plugin/12731-amethyst

hadils 2020-12-09T16:06:35.364400Z

Hi I am using Intellij Ultimate 2020.3 with Cursive. One change I've noticed is that the namespace no longer shows up in my local REPL tab. Is there a way I can fix this?

2020-12-09T16:09:37.364600Z

Might be related to this: https://groups.google.com/g/cursive/c/Ybcgx_oTS7c

2020-12-09T16:10:42.365500Z

(That’s an email from Colin talking about Cursive 1.10.0-eap1 — he mentions a bug in 2020.3 related to namespaces, not sure if that’s the same thing you’re talking about

hadils 2020-12-09T16:41:18.365700Z

Thanks @manutter51

JAtkins 2020-12-09T20:46:09.367700Z

How can I figure out what is wrong with stubs generation? I'm seeing some error appearing when I try to generate them for my project, but the description only contains the *out* of the clj process, which isn't very enlightening. AFAICT there shouldn't be any errors at all.

JAtkins 2020-12-09T20:50:06.369100Z

Also, I accidentally clicked Disable on the stub generation failure popup... I see nothing in either main settings or project settings to undo that. I don't see a diff in my project files, so I have no idea how to undo this ;p

JAtkins 2020-12-09T21:05:12.369300Z

Actually, could it be related to this: https://github.com/cursive-ide/cursive/issues/2066 . I get a warning from slf4j

JAtkins 2020-12-09T21:05:28.369600Z

It's printed on *err* though

JAtkins 2020-12-09T21:50:12.369800Z

I can silence my *err* stream with "-Dorg.eclipse.jetty.util.log.announce=false" . I put that in my dev alias (which is enabled in the project view). It removes all prints to *err* while starting the repl, but it appears that this option is not applied while building stubs... How do I control the build of the stub generator?

JAtkins 2020-12-09T22:08:43.370Z

Found under Project Settings -> Modules -> (Clojure Tab) -> Create stubs if required

JAtkins 2020-12-09T22:31:20.370200Z

After much ado, I realized that I could put

(java.lang.System/setProperty "org.eclipse.jetty.util.log.announce" "false")
in my user.clj. That fixes it. However, can this be documented elsewhere? This was a 1.5 ish hour problem, and it's not obvious at all that cursive is doing it's own thing without deps.edn, and that it crashes on anything printed to *err* (except those redefinition warnings).

JAtkins 2020-12-09T22:48:40.372700Z

anyway, all of that was me trying to get rewrite-clj.potemkin/import-vars to resolve correctly as potemkin/import-vars. Unfortunately, this is still not working. After invalidating cache and rebuilding stubs and verifying that the macro is resolved as potemkin/import-vars, documentation/autocomplete still don't work.