Fork me on GitHub
Alexis Vincent14:12:42

@alexmiller I’m running into a number of cases where I want to build a library (and publish it to a maven repository) that relies on a library that only provides a gitdep. Libraries or projects using this published library then dont have access to the gitdep since its not representable in the pom. Is there a recommended way to deal with this? Or is the advice to publish copies of these git libraries to maven ourselves?

Alex Miller (Clojure team)14:12:40

that's the only path afaik

Alex Miller (Clojure team)14:12:02

I mean, you can ask the owner to do so of course

Alex Miller (Clojure team)14:12:23

if you have questions about how to best do so, you can ask at #clojars

Alexis Vincent14:12:27

Thanks. Do you think its worth publishing a note about this case in the docs? I didn’t make the logical leap about the effects of designing against gitdeps. Im sure others will likely not either.

Alexis Vincent14:12:22

Even though I’d posted an issue about this exact case in. November, I forgot about it and ran into the same thing

Alexis Vincent14:12:30

I’m concerned we end up with a bunch of library authors not realising the results of not publishing to Clojars or something similar


The idea of pulling deps.edn from jars was floated as a solution for this at some point.

Alexis Vincent15:12:15

Currently I’m forking libs, and publishing to an internal maven repo. But from a maintenance POV this is quite an ask, especially for folks who don’t necessarily have access to the same infrastructure setup we do. Also considering dep resolution will no longer work, I’m thinking a better way of dealing with this might make sense to consider.


Is there a way to use tools.deps to know which SNAPSHOT version is currently resolved. For example currently becomes but I don't seem to be able to retrieve 20191108.004735-9 from the functions I've tested in, but I didn't test everything. That first url is made up, but I pass kitchen-async/kitchen-async #:mvn{:version "0.1.0-SNAPSHOT"} {"central" {:url ""}, "clojars" {:url ""}} as parameters (depending on the function I'm testing).


I don't believe tools.deps does anything with SNAPSHOT, it just gets passed on to the maven code, which picks a version when it actually looks at what is in the repos


ok, so I should rather point my attention to aether for this?

Alex Miller (Clojure team)18:12:56

From tools.deps - no. From aether, I’m not really sure how to do it there either

Alex Miller (Clojure team)18:12:34

You request the snapshot version and it resolves that to a url but I don’t think you can see the time stamped version

Alex Miller (Clojure team)18:12:02

I guess my question would be why do you care?


It's for a simple app I made in nix, where I create a file with all the endpoints and the artifact's hashsum. Appearently some other people are using it, and a user made a ticket that snapshot versions are returning 404.


Snapshot is very against integrity, but if the artifact is timestamped, it can be "frozen" to the time which the endpoints are generated.

Alex Miller (Clojure team)18:12:00

well, the Maven solution to that is a non-SNAPSHOT release


that sort of compounds the error of using snapshots, different people running the tool will resolve the snapshot differently


so its frozen, but no one agrees to what it is frozen as


you can directly depend on the timestamped version too


@hiredman true that, the generated nix file will be frozen but not the file that generated it. It would be convenience that it would work. I think any serious release should be adviced against using snapshot versions in general.


I will try other options, thanks for both of your inputs.


Hello! I am using a mac mini with an M1 chip and it seems I can’t add a private github repo in my deps.edn file. The JDK I am using is this:

openjdk 2020-11-04 LTS
OpenJDK Runtime Environment Zulu11.43+1015-CA (build
OpenJDK 64-Bit Server VM Zulu11.43+1015-CA (build, mixed mode)
and you can find the error in the thread (not to pollute the main chat) 🙂.


Error building classpath. /private/var/folders/kv/64_g981979325dj8jwwd90fc0000gn/T/jna-106985/jna3259090784966322613.tmp: dlopen(/private/var/folders/kv/64_g981979325dj8jwwd90fc0000gn/T/jna-106985/jna3259090784966322613.tmp, 1): no suitable image found.  Did find:
[watch:cljs] 	/private/var/folders/kv/64_g981979325dj8jwwd90fc0000gn/T/jna-106985/jna3259090784966322613.tmp: no matching architecture in universal wrapper
[watch:cljs] 	/private/var/folders/kv/64_g981979325dj8jwwd90fc0000gn/T/jna-106985/jna3259090784966322613.tmp: no matching architecture in universal wrapper
[watch:cljs] java.lang.UnsatisfiedLinkError: /private/var/folders/kv/64_g981979325dj8jwwd90fc0000gn/T/jna-106985/jna3259090784966322613.tmp: dlopen(/private/var/folders/kv/64_g981979325dj8jwwd90fc0000gn/T/jna-106985/jna3259090784966322613.tmp, 1): no suitable image found.  Did find:
[watch:cljs] 	/private/var/folders/kv/64_g981979325dj8jwwd90fc0000gn/T/jna-106985/jna3259090784966322613.tmp: no matching architecture in universal wrapper
[watch:cljs] 	/private/var/folders/kv/64_g981979325dj8jwwd90fc0000gn/T/jna-106985/jna3259090784966322613.tmp: no matching architecture in universal wrapper
[watch:cljs] 	at java.base/java.lang.ClassLoader$NativeLibrary.load0(Native Method)
[watch:cljs] 	at java.base/java.lang.ClassLoader$NativeLibrary.load(
[watch:cljs] 	at java.base/java.lang.ClassLoader$NativeLibrary.loadLibrary(
[watch:cljs] 	at java.base/java.lang.ClassLoader.loadLibrary0(
[watch:cljs] 	at java.base/java.lang.ClassLoader.loadLibrary(
[watch:cljs] 	at java.base/java.lang.Runtime.load0(
[watch:cljs] 	at java.base/java.lang.System.load(
[watch:cljs] 	at com.sun.jna.Native.loadNativeDispatchLibraryFromClasspath(
[watch:cljs] 	at com.sun.jna.Native.loadNativeDispatchLibrary(
[watch:cljs] 	at com.sun.jna.Native.<clinit>(
[watch:cljs] 	at com.jcraft.jsch.agentproxy.usocket.JNAUSocketFactory$CLibrary.<clinit>(
[watch:cljs] 	at
[watch:cljs] 	at
[watch:cljs] 	at com.jcraft.jsch.agentproxy.connector.SSHAgentConnector.<init>(
[watch:cljs] 	at com.jcraft.jsch.agentproxy.ConnectorFactory.createConnector(
[watch:cljs] 	at$fn__1250.invokeStatic(impl.clj:31)
[watch:cljs] 	at$fn__1250.invoke(impl.clj:29)
[watch:cljs] 	at clojure.lang.Delay.deref(
[watch:cljs] 	at clojure.core$deref.invokeStatic(core.clj:2320)
[watch:cljs] 	at clojure.core$deref.invoke(core.clj:2306)
[watch:cljs] 	at$call_with_auth.invokeStatic(impl.clj:51)
[watch:cljs] 	at$call_with_auth.invoke(impl.clj:43)
[watch:cljs] 	at$git_clone_bare.invokeStatic(impl.clj:73)
[watch:cljs] 	at$git_clone_bare.invoke(impl.clj:70)
[watch:cljs] 	at$ensure_git_dir.invokeStatic(impl.clj:112)
[watch:cljs] 	at$ensure_git_dir.invoke(impl.clj:102)
[watch:cljs] 	at$resolve.invokeStatic(gitlibs.clj:33)
[watch:cljs] 	at$resolve.invoke(gitlibs.clj:29)
[watch:cljs] 	at$procure.invokeStatic(gitlibs.clj:47)
[watch:cljs] 	at$procure.invoke(gitlibs.clj:41)
[watch:cljs] 	at$eval1316$fn__1318.invoke(git.clj:42)
[watch:cljs] 	at clojure.lang.MultiFn.invoke(
[watch:cljs] 	at$expand_deps.invokeStatic(alpha.clj:422)
[watch:cljs] 	at$expand_deps.invoke(alpha.clj:390)
[watch:cljs] 	at$resolve_deps.invokeStatic(alpha.clj:495)
[watch:cljs] 	at$resolve_deps.invoke(alpha.clj:475)
[watch:cljs] 	at$calc_basis.invokeStatic(alpha.clj:648)
[watch:cljs] 	at$calc_basis.invoke(alpha.clj:622)
[watch:cljs] 	at$run_core.invokeStatic(make_classpath2.clj:91)
[watch:cljs] 	at$run_core.invoke(make_classpath2.clj:57)
[watch:cljs] 	at$run.invokeStatic(make_classpath2.clj:119)
[watch:cljs] 	at$run.invoke(make_classpath2.clj:113)
[watch:cljs] 	at$_main.invokeStatic(make_classpath2.clj:169)
[watch:cljs] 	at$_main.doInvoke(make_classpath2.clj:140)
[watch:cljs] 	at clojure.lang.RestFn.applyTo(
[watch:cljs] 	at clojure.lang.Var.applyTo(
[watch:cljs] 	at clojure.core$apply.invokeStatic(core.clj:665)
[watch:cljs] 	at clojure.main$main_opt.invokeStatic(main.clj:514)
[watch:cljs] 	at clojure.main$main_opt.invoke(main.clj:510)
[watch:cljs] 	at clojure.main$main.invokeStatic(main.clj:664)
[watch:cljs] 	at clojure.main$main.doInvoke(main.clj:616)
[watch:cljs] 	at clojure.lang.RestFn.applyTo(
[watch:cljs] 	at clojure.lang.Var.applyTo(
[watch:cljs] 	at clojure.main.main(

Alex Miller (Clojure team)22:12:37

you are doing something that selects a classifier dep based on architecture

Alex Miller (Clojure team)22:12:57

for a dep that has native stuff in it


@alexmiller make-classpath I think is triggering this? Looks like jsch to me?


so probably jgit?

Alex Miller (Clojure team)22:12:25

oh yeah, it's tools.deps itself

Alex Miller (Clojure team)22:12:34

but yes, jsch for ssh git support


So, no ARM support for (that version) of jsch?

Alex Miller (Clojure team)22:12:34

probably not anything easy to fix at the drop of a hat

Alex Miller (Clojure team)22:12:21

can you avoid using a git dep?


(or more likely JCE directly in the JDK doesn't support ARM?)

Alex Miller (Clojure team)22:12:48

or use an https git dep? that should work as the ssh code is in a delay that won't be forced


Thanks for the prompt responses 🙂 Yes, I can just have the repo live in the project and use :local/root


@UE35Y835W Is that JDK specifically for the ARM chip or are you relying on Rosetta emulation?


That’s specific for the ARM chip.. I haven’t tried yet an emulated one tbh


'k... hmm, I would have expected JCE to work then. Good job you have a workaround with a local dep.

👍 3

Out of curiosity I’ll give it a spin with an emulated jdk


@alexmiller When you say to try https you mean:

bar {:git/url ""
     :sha "..."}
This is failing due to authentication - no CredentialsProvider has been registered


but that’s fine anyways.. I’ll simply get it in the repo for now 🙂 Thanks all again

Alex Miller (Clojure team)22:12:36

yes, that's what I meant

🙏 3