r/Clojure • • Apr 14 '23

Clojure 1.12.0-alpha2

https://clojure.org/news/2023/04/14/clojure-1-12-alpha2
96 Upvotes

23 comments sorted by

View all comments

6

u/lgstein Apr 14 '23

When a added lib transiently requires a newer lib than what is on the classpath it should throw or refuse and advise a JVM restart. Otherwise you might run into weird errors.

6

u/alexdmiller Apr 14 '23

Often, you (smart human) may know better whether this is definitely ok, maybe ok, or not ok than add-lib can know. Having lived with it for a while, it's usually fine. As the docstring says, this is a "best effort" operation designed to work at the repl. "best effort" is meant to convey - "may not always work".

5

u/lgstein Apr 15 '23

I'm surely not smart enough to know the dependency tree of libs I require... Maybe consider printing a warning? I would find it very helpful.