leiningen

N.B. The maintainers are on #leiningen on Libera chat IRC. Go there for direct support/bug reports.
λustin f(n) 2020-03-26T16:04:16.001700Z

Is there a lein command that will tell me what deps are bringing something in? I think I have 3+ libraries fighting over which version of org.clojure/java.jdbc to use and I want to find out what they are

2020-03-26T16:06:20.001800Z

lein deps :tree

2020-03-26T16:37:54.002Z

The only issue is I don’t think it’ll show you specifically the conflict - you’ll just see the final decision of which one was chosen. If they are coming in on the same “transitive dependency tree” level, then I believe it’s first one traversed wins (could be last, but I think it’s first)

2020-03-26T16:38:10.002200Z

you can do an :exclusions on the one that it chooses to see what the next would be, and so on

2020-03-26T16:48:15.002400Z

I thought lein deps tree showed me conflicts explicitly last I checked?

2020-03-26T16:51:04.002700Z

% lein deps :tree
Possibly confusing dependencies found:
[org.apache.kafka/kafka-clients "2.3.1"]
 overrides
[io.confluent/kafka-avro-serializer "5.3.1"] -> [io.confluent/kafka-schema-registry-client "5.3.1"] -> [org.apache.kafka/kafka-clients "5.3.1-ccs" :exclusions [org.slf4j/slf4j-log4j12]]
 and
[io.confluent/kafka-schema-registry-client "5.3.1" :exclusions [com.fasterxml.jackson.core/jackson-databind]] -> [org.apache.kafka/kafka-clients "5.3.1-ccs" :exclusions [org.slf4j/slf4j-log4j12]]

Consider using these exclusions:
[io.confluent/kafka-avro-serializer "5.3.1" :exclusions [org.apache.kafka/kafka-clients]]
[io.confluent/kafka-schema-registry-client "5.3.1" :exclusions [org.apache.kafka/kafka-clients com.fasterxml.jackson.core/jackson-databind]]

[io.confluent/kafka-schema-registry-client "5.3.1" :exclusions [com.fasterxml.jackson.core/jackson-databind]] -> [org.apache.avro/avro "1.8.1"] -> [com.thoughtworks.paranamer/paranamer "2.7"]
 overrides
[org.apache.kafka/kafka_2.11 "2.3.1"] -> [com.fasterxml.jackson.module/jackson-module-scala_2.11 "2.10.0" :exclusions [*/jms */mail */javax */jmxri */jline */jmxtools]] -> [com.fasterxml.jackson.module/jackson-module-paranamer "2.10.0"] -> [com.thoughtworks.paranamer/paranamer "2.8"]

Consider using these exclusions:
[org.apache.kafka/kafka_2.11 "2.3.1" :exclusions [com.thoughtworks.paranamer/paranamer]]

 [aleph "0.4.6"]
   [byte-streams "0.2.4"]
...

2020-03-26T17:15:04.002900Z

ah in the error output

2020-03-26T17:15:24.003100Z

I often only look at the output map - so forgot about those details. Thanks for clarifying.

🍻 1
tzzh 2020-03-26T17:20:15.004900Z

Hi everyone, I am trying to use a java library that has native library dependencies (respectively [com.amazonaws/DynamoDBLocal "1.12.0"] and sqlite4java ) inside a library I am working on and I am not sure how I can package the native dependencies with my library I have tried copying the native dependencies to my resources and set :jvm-opts [“-Dsqlite4java.library.path=resources/native-libs/sqlite4java-392/“] and then I can lein run but then when I build and run the standalone uberjar it can’t find the native library anymore

tzzh 2020-03-26T17:25:55.005100Z

I found some potential hacks on SO e.g https://stackoverflow.com/questions/2937406/how-to-bundle-a-native-library-and-a-jni-library-inside-a-jar but was wondering if there were other options