Fork me on GitHub
#tools-deps
<
2021-03-04
>
seancorfield02:03:39

com.github.seancorfield/clj-new {:mvn/version "1.1.264"} -- Create new applications and libraries with the Clojure CLI -- https://github.com/seancorfield/clj-new/releases/tag/v1.1.264 -- adjusts all generated projects so they follow the Clojars policy change to Verified Group Names; changes the group ID of clj-new to a VGN (releases will be double-published to seancorfield/clj-new for a while). Follow-up in #clj-new for the library, follow-up in #clojars for the policy

👍 6
mkvlr14:03:00

I’m seeing this

/t/deps ❯❯❯ clojure -version
Clojure CLI version 1.10.2.801
/t/deps ❯❯❯ cat deps.edn
{:deps {org.clojure/clojure {:mvn/version "1.10.2"}
        org.clojure/clojurescript {:git/url "", :sha "715cdc07dbb1d595af91ea12affb6faf0b615d4b"}}}
/t/deps ❯❯❯ clojure -Stree
Error building classpath. Manifest type not detected when finding deps for org.clojure/clojurescript in coordinate {:git/url "", :sha "715cdc07dbb1d595af91ea12affb6faf0b615d4b"}

Alex Miller (Clojure team)14:03:21

I can't reproduce that - can you try with -Sforce ?

Alex Miller (Clojure team)14:03:18

(git urls typically end in .git btw, although github doesn't seem to require it)

mkvlr14:03:07

@alexmiller same:

/t/deps ❯❯❯ clojure -Sforce
Error building classpath. Manifest type not detected when finding deps for org.clojure/clojurescript in coordinate {:git/url "", :sha "715cdc07dbb1d595af91ea12affb6faf0b615d4b"}

seancorfield03:03:30

FWIW, I ran into a similar situation later today @alexmiller but I wasn't able to nail down a repro. In the end, I blew away ~/.gitlibs and that fixed it. Here's the output from one of my attempts:

Checking out:  at ee2badaaf4b26754f903ed92e77fd4e82cf2ed70
Error building classpath. Manifest type not detected when finding deps for com.github.seancorfield/depstar in coordinate {:git/url "", :sha "ee2badaaf4b26754f903ed92e77fd4e82cf2ed70"}
And that checked out folder was empty.

seancorfield03:03:14

And with a different SHA -- same result:

(! 806)-> clojure -X:jar
Checking out:  at a8cf78c9e09e3504e64fc77bcb133a7ada39a68f
Error building classpath. Manifest type not detected when finding deps for com.github.seancorfield/depstar in coordinate {:git/url "", :sha "a8cf78c9e09e3504e64fc77bcb133a7ada39a68f"}

seancorfield03:03:34

The only odd thing is that this line was missing when it failed:

Cloning: 
but present when it worked.

seancorfield04:03:47

Just a follow-up note: in the main channel, you indicated that the problem might be due to prior parallel jgit downloads causing corruption but these SHAs were new since I moved to 1.10.2.801 -- are you saying that the jgit impl could have messed things up in the ~/.gitlibs folder such that it causes problems for the new git-sh impl @alexmiller?

Alex Miller (Clojure team)12:03:18

Yes. Or there was some logic that detected this and recloned and I removed it. Going to look at it today.

3
seancorfield16:03:23

Happy to test more and do any debugging that might assist.

Alex Miller (Clojure team)14:03:27

that... does not make any sense to me

mkvlr14:03:27

(also if I append .git)

Alex Miller (Clojure team)14:03:52

the manifest type is pulled from the :git/url ns attribute

Alex Miller (Clojure team)14:03:11

(I'm not saying you're not seeing it, just saying I don't understand why)

mkvlr14:03:07

I’m also a bit puzzled, works for another git dep

Alex Miller (Clojure team)14:03:23

anything in your ~/.clojure/deps.edn? Can you try with -Srepro (that will omit that one)

Alex Miller (Clojure team)14:03:04

can you attach the actual deps.edn file here

mkvlr14:03:02

there you go, still reproduces with clojure -Sforce -Srepro for me

borkdude14:03:20

$ clojure -Sdeps '{:deps {org.clojure/clojure {:mvn/version "1.10.2"}
        org.clojure/clojurescript {:git/url "", :sha "715cdc07dbb1d595af91ea12affb6faf0b615d4b"}}}'
Works for me locally

mkvlr14:03:10

clojure -Srepro -Sdeps '{:deps {org.clojure/clojure {:mvn/version "1.10.2"}
        org.clojure/clojurescript {:git/url "", :sha "715cdc07dbb1d595af91ea12affb6faf0b615d4b"}}}'
Error building classpath. Manifest type not detected when finding deps for org.clojure/clojurescript in coordinate {:git/url "", :sha "715cdc07dbb1d595af91ea12affb6faf0b615d4b"}

borkdude14:03:26

@mkvlr try rm -rf ~/.gitlibs; rm -rf .cpcache

Alex Miller (Clojure team)14:03:44

neither of those should be in play here

mkvlr14:03:04

@borkdude moving ~/.gitlibs away fixed it

Alex Miller (Clojure team)14:03:40

oh, I'm misreading the error message

mkvlr14:03:47

@alexmiller I had previously our fork at http://github.com/nextjournal/clojurescript.git of ClojureScript with the same sha in the deps.edn . Let me know if I should try to isolate the issue with ~/.gitlibs and send you a minimal version

Alex Miller (Clojure team)14:03:56

this is not detecting a manifest type in the git working tree

Alex Miller (Clojure team)14:03:30

it's looking for either deps.edn or pom.xml in the dir

Alex Miller (Clojure team)15:03:36

so curious what you see in ~/.gitlibs/libs/org.clojure/clojurescript/715cdc07dbb1d595af91ea12affb6faf0b615d4b

Alex Miller (Clojure team)15:03:46

is that maybe an empty dir?

mkvlr15:03:38

@alexmiller yes, it’s empty

Alex Miller (Clojure team)15:03:13

ok, well I understand the error then :)

Alex Miller (Clojure team)15:03:14

that (I think) is a side effect of parallel download conflicts from the prior jgit impl

👍 3
Alex Miller (Clojure team)15:03:52

I was never able to repro that so I can't say that it won't happen in the new one (but I think it won't)

borkdude15:03:02

Maybe treat an empty dir as non-existing?

borkdude15:03:19

That would cover up the cause maybe too much

Alex Miller (Clojure team)15:03:31

right now we use the existence of the dir as a signal, but I want to look at this more

Alex Miller (Clojure team)15:03:35

thx for trying it and reporting

mkvlr15:03:45

thank you!

seancorfield22:03:22

@alexmiller Is there a documented, supported way to get hold of the injected basis for a t.d.a based program? The system property went away, right? I know how to calculate the project basis but that's not necessarily the same.

seancorfield23:03:54

I guess (t/merge-edns ((juxt :root-edn :user-edn :project-edn) (t/find-edn-maps))) is really all I need (since I'm just trying to look up available aliases, not deps at this point).