Fork me on GitHub
#cursive
<
2021-11-24
>
Ian Fernandez03:11:02

Why Run with IntelliJ project classpath and adding a alias that have :jvm-opts ["-Denvironment=test"] does not print this variable when I run (get (System/getProperties) "environment") but when I run with clj -A:my-profile it works well?

cfleming07:11:27

When you run with the IntelliJ project classpath, you can’t select an alias. It will use whichever aliases you had selected in the deps toolwindow when you last synced.

cfleming07:11:51

But those aliases won’t be used to supply things like :jvm-opts

imre11:11:40

Is there any reason jvm-opts are ignored?

👍 1
Ian Fernandez14:11:00

I've selected the aliases on deps toolwindow, Is there any reason jvm-opts are ignored?

cfleming19:11:44

Because those aliases are only used to sync the project, so they’re only involved in run configurations tangentially. Basically, those aliases determine the deps and source paths that will be synced to the IntelliJ project, and those deps and paths determine the classpath IntelliJ uses. If you do want proper alias support, then the thing to do is to use “Run with deps” and select the aliases there.

imre10:10:07

@U0567Q30W apologies for resurrecting an old thread, but is this decision something you could be open to reconsidering? The deps tool window is a lot more user-friendly for selecting aliases. Moreover, 'running with deps' is still affected by the Deferred parameters have not been cached! problem reported at https://github.com/cursive-ide/cursive/issues/2308

imre10:10:54

Whenever I hit restart repl on a running with deps repl I get this and it won'r restart

ingesol11:11:05

I have a tools.deps project. I use aliases to override maven style dependencies with :local/root ones to get hot reloading for dependency source code in shadow-cljs. Is there a way in cursive to make code navigation point to dependency source rather than the dependency JAR? So I can cmd-click a function name and go to its definition in the :local/root source?

cfleming20:11:22

Do you have those aliases selected in your deps toolwindow?

ingesol20:11:24

I did not, do now 🙂

ingesol20:11:50

Thanks, wasn’t aware of that feature.

favila17:11:03

Using 2021.2.3 with 1.12.0-eap2-2021.2, I am unable to send stacktrace reports. (I don’t know whose fault this is :)) The error is Error submitting report: 422 Unprocessable Entity : ErrorResponse(message=Validation Failed, errors=[ErrorItem(resource=Issue, field=labels, code=custom)]) Top of stack:

cursive.exception.GithubException: 422 Unprocessable Entity : ErrorResponse(message=Validation Failed, errors=[ErrorItem(resource=Issue, field=labels, code=custom)])
	at cursive.exception.ClojureErrorReportSubmitterKt.update(ClojureErrorReportSubmitter.kt:190)
	at cursive.exception.ClojureErrorReportSubmitterKt.access$update(ClojureErrorReportSubmitter.kt:1)
	at cursive.exception.ClojureErrorReportSubmitter$submit$1.run(ClojureErrorReportSubmitter.kt:339)
	at com.intellij.openapi.progress.impl.CoreProgressManager.startTask(CoreProgressManager.java:450)
	at com.intellij.openapi.progress.impl.ProgressManagerImpl.startTask(ProgressManagerImpl.java:117)

1
kenny18:11:25

For me, it doesn't happen for all exceptions.

cfleming04:11:44

Does this happen for all exceptions for you, @U09R86PA4? It’s a weird error, I’m not sure what the code=custom means and the error is a bit meaningless without that.

favila04:11:42

It’s a recent error. I’ll have to wait for another cursive exception to try again

favila04:11:53

The original exception I was submitting was related to cursive using a not-yet-ready index, which I’ve seen before and submitted without problems