This page is not created by, affiliated with, or supported by Slack Technologies, Inc.
2024-01-30
Channels
- # announcements (5)
- # babashka (2)
- # beginners (85)
- # cider (59)
- # cljs-dev (2)
- # clojure (10)
- # clojure-europe (61)
- # clojure-gamedev (20)
- # clojure-nl (2)
- # clojure-norway (9)
- # clojure-uk (5)
- # cursive (24)
- # data-science (4)
- # datascript (8)
- # emacs (1)
- # fulcro (8)
- # graalvm (30)
- # gratitude (9)
- # hyperfiddle (71)
- # introduce-yourself (1)
- # jackdaw (1)
- # leiningen (8)
- # london-clojurians (1)
- # missionary (3)
- # other-languages (10)
- # pathom (8)
- # pedestal (18)
- # polylith (4)
- # proletarian (5)
- # reitit (7)
- # releases (4)
- # ring (8)
- # sci (10)
- # shadow-cljs (27)
- # squint (3)
- # tools-deps (2)
- # xtdb (17)
Hi everyone. Hope you're all doing great!
I'm having problems with Cursive when starting REPL... I"m getting a java.lang.IllegalArgumentException: /work/collage/image-processor/src/java/stylitics/StyliticsMagick.class is not a relative path
I've tried:
• Different Java versions (21 and 11)
• Run lein clean
, clear maven (`~/m2`) and /target
folders
• Clear my ~/.lein/profiles.clj
• Fresh start (deleted the whole thing and cloned it again)
Nothing has worked 'till now
Environment:
• Mac M2 (MacOS Sonoma 14.3)
• IntelliJ IDEA Ultimate
• Cursive with an active license
Project:
• Leiningen project at the root /work/collage
• Some subprojects (the one that's causing problems is image-processor
)
Can someone help me with that?
Thank you in advance
Do you get the same error running lein repl on the command line, e.g. in the IntelliJ terminal?
Are you able to share your project.clj? If you’d prefer, you can mail it to me at <mailto:[email protected]|[email protected]>. Otherwise, what do the java-related parts look like? java-source-paths etc.
Here's the java-source-paths
. That's only java related stuff
:java-source-paths ["image-processor/src/java"
"components/bigquery/src/java"
"stylitics/services/shop_the_image_matcher/"]
In this case, isn’t image-processor a sub-project? Shouldn’t that subproject just have src/java
as its java-source paths?
I have those in the same repo under /image-processor
. I found that weird because I'm not being able to reproduce it in a isolated project
So in your root project.clj, you have image-processor/src/java
, and in your image-processor project.clj you have src/java
? Does it help if you remove the one in the root project?
Yep, but it should not interfere since I'm pointing to my root project.clj
is that right? :thinking_face: Because lein should be seeing those paths as part of the same project.
here's my project tree simplified:
.
├── image-processor
│ ├── bin
│ │ └── docker-enter.sh
│ ├── src
│ │ ├── clj
│ │ └── java
│ │ └── stylitics
│ │ ├── ImageMagick.java
│ │ ├── MagickVersion.java
│ │ ├── PNGquant.java
│ │ └── StyliticsMagick.java
│ ├── .gitignore
│ ├── Dockerfile
│ ├── project.clj
│ └── README.md
├
├── resources
├── src
│ ├── c
│ └── clj
├── test
│ └── clj
├── project.clj
└── README.md
I’m not sure, you’re getting to the edges of my lein knowledge now, sorry. When you run the REPL, are you running it in the context of your root project or the sub-project?
Actually, don’t worry about the version, the most recent version lines up with the stacktrace. So I can see what’s going on, but I don’t know why. I’ll have to see if I can reproduce this.
BTW one thing I forgot to mention - the standard workaround in these cases is to run the REPL on the command line, and then connect to it using a Remote REPL from Cursive, like this: https://cursive-ide.com/userguide/repl.html#remote-repls
Hi @U0567Q30W thank you!
fyi, I’m seeing this exception under the latest EAP