This page is not created by, affiliated with, or supported by Slack Technologies, Inc.
2021-08-10
Channels
- # announcements (1)
- # babashka (18)
- # beginners (122)
- # calva (18)
- # cider (3)
- # cljs-dev (2)
- # cljsrn (3)
- # clojure (102)
- # clojure-europe (15)
- # clojure-france (2)
- # clojure-nl (1)
- # clojure-portugal (1)
- # clojure-spec (3)
- # clojure-uk (8)
- # clojurescript (46)
- # clojureverse-ops (5)
- # code-reviews (1)
- # conjure (2)
- # cursive (15)
- # datalog (13)
- # datomic (18)
- # emacs (4)
- # fulcro (8)
- # helix (8)
- # instaparse (1)
- # introduce-yourself (2)
- # jobs (4)
- # leiningen (23)
- # lsp (26)
- # malli (21)
- # off-topic (34)
- # pedestal (21)
- # polylith (6)
- # reitit (5)
- # remote-jobs (3)
- # schema (1)
- # sci (8)
- # shadow-cljs (8)
- # spacemacs (3)
- # sql (30)
- # testing (31)
- # tools-deps (21)
- # vim (25)
- # xtdb (8)
Hi All, need a help.. can lein use my .m2/settings.xml?
If not how to specify corporate proxy info, maven <server> info, mirrors,<repositories>
in project.clj
and pluginRepositeries as well...
Thanks
Hi everyone 👋 , not sure this is the right place to post this question. I’m a beginner and I’m struggling to deploy my lein api project to heroku. I’m getting this error on heroku, while deplyoing, which I can’t overcome. I’m using openJDK 1.8.2 in my local machine.
Compiling clojures-backend.core
Syntax error macroexpanding at (trie.cljc:1:1).
Execution error (UnsupportedClassVersionError) at java.lang.ClassLoader/defineClass1 (ClassLoader.java:-2).
reitit/Trie has been compiled by a more recent version of the Java Runtime (class file version 55.0), this version of the Java Runtime only recognizes class file versions up to 52.0
Any hints on how to solve this?oh, I’ve sorted it out. For anyone struggling with this one possible solution is to create a system.properties file in the root of your project and specify
java.runtime.version=11
This way heroku we’ll use JDK 11. 🚀@mrkiouak try to use the same profile for deps :tree
as for uberjar
. if you don’t have anything special defined for that then:
lein with-profile uberjar deps :tree
Note I really ought to have showed the command as lein jar
I apologize for that, i failed a context switch check -- everything else applies, but the behavior of unexpected included jars is for lein jar
not lein uberjar
lein jar
shouldn’t be including any of your dependencies in it at all. That’s what an uberjar does as opposed to normal “slim” jars.
If you must have aot compilation in a jar. Lein should be able to filter it via it’s built in flag there but there could be caveats and I don’t know your setup to know why it wouldn’t already be filtering the non project classfiles
That's interesting. I'd "worked around" this by moving the nses that needed aot to another library, which eliminated the other dependencies appearing as aoted in the jar file, presumably because the separate jar has a much, much smaller set of dependencies that may not get filtered. I think we do need the aot of two nses because of gen-class created classes intended for interop with a native java servlet, but I can double check that.
Thanks, that appears to be an exact explanation (in the jira item) for the behavior I was seeing, and when I get a chance to try that flag I suspect it will remove the issue without a dependency move as well. Thanks for looking at this, and pointing out the history and how this isn't a strange leiningen default, but due to decisions made by the clojure aot compiler!