Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

clojars distribution => missing checksum makes lein refuse to get the lib #2

Closed
denlab opened this issue Aug 6, 2012 · 6 comments
Closed
Assignees

Comments

@denlab
Copy link

denlab commented Aug 6, 2012

Hi,

When I added to my project.clj:

A lein deps gave me:

Retrieving net/mikera/clisk/0.3.0/clisk-0.3.0.pom (2k)
    from https://clojars.org/repo/
Could not transfer artifact net.mikera:clisk:pom:0.3.0 from/to clojars (https://clojars.org/repo/): Checksum validation failed, no checksums available from the repository
Failed to collect dependencies for clojure.lang.LazySeq@45daf4cd

In the clojars repository I can see that there's no checksum.

So I put manually the jars and poms in my local repo ~/.m2 and it seems to work.

By the way I checked a lib that I used recently without this problem, here, and I can see the checksums along with the files:

Index of /repo/net/cgrand/parsley/0.9.1/

../
parsley-0.9.1.jar                                  01-Jun-2012 07:33               22247
parsley-0.9.1.jar.md5                              01-Jun-2012 07:33                  32
parsley-0.9.1.jar.sha1                             01-Jun-2012 07:33                  40
parsley-0.9.1.pom                                  01-Jun-2012 07:33                1771
parsley-0.9.1.pom.md5                              01-Jun-2012 07:33                  32
parsley-0.9.1.pom.sha1                             01-Jun-2012 07:33                  40

Cheers,

Denis

@mikera
Copy link
Owner

mikera commented Aug 6, 2012

Thanks for reporting! Not sure of the best way to fix this - any idea how to get Maven to generate these when it does a deploy?

@denlab
Copy link
Author

denlab commented Aug 6, 2012

No idea how to fix it the right way.

However I can propose a hack (I took a dummy project clojure-station has an example):

  • Generate the sha1:
cd ~/.m2/repository/clojure-station/clojure-station/0.0.1-SNAPSHOT
sha1sum clojure-station-0.0.1-SNAPSHOT.jar > clojure-station-0.0.1-SNAPSHOT.jar.sha1
sah1sum clojure-station-0.0.1-SNAPSHOT.pom > clojure-station-0.0.1-SNAPSHOT.pom.sha1
  • Upload to Clojars:
    Important Do not change the username to yours, and do not forget the : at the end (and don't put anything behind it)
    In other words: Copy & Paste The following line as is:
scp *.sha1 clojars@clojars.org:

Should do the job ...
See it there: https://clojars.org/repo/clojure-station/clojure-station/0.0.1-SNAPSHOT/

Source: http://www.cubrid.org/wiki_apis/entry/how-to-push-new-cubrid-jdbc-driver-to-clojars-maven-repository

Cheers,

Denis

PS : and by the way thanks for sharing clisk, I started playing with the wiki examples, seems fun!

@mikera
Copy link
Owner

mikera commented Aug 7, 2012

Hmmm I hate Maven sometimes :-)

This is proving to be difficult since I'm on Windows at the moment and don't have the helpful sha1gen tools etc. Will try to figure out how to get this to work with PuTTy etc.....

Glad you like clisk!

@ghost ghost assigned mikera Aug 7, 2012
@mikera
Copy link
Owner

mikera commented Aug 7, 2012

Denis - I think I managed to get a workaround in place using pscp - can you confirm that the 0.3.0 version from Clojars now works for you?

@denlab
Copy link
Author

denlab commented Aug 7, 2012

Working fine now !

$ rm -r ~/.m2/repository/net/mikera/clisk/0.3.0/
$ lein deps
$ ls -l ~/.m2/repository/net/mikera/clisk/0.3.0/
total 64
-rw-rw-r-- 1 denis denis 47876 Aug  7 09:26 clisk-0.3.0.jar
-rw-rw-r-- 1 denis denis    40 Aug  7 09:26 clisk-0.3.0.jar.sha1
-rw-rw-r-- 1 denis denis  2151 Aug  7 09:26 clisk-0.3.0.pom
-rw-rw-r-- 1 denis denis    40 Aug  7 09:26 clisk-0.3.0.pom.sha1
-rw-rw-r-- 1 denis denis   177 Aug  7 09:26 _maven.repositories

So you went the dirty way? By generating & uploading manually the SHA1?

There's some informations about deploying here: https://github.com/technomancy/leiningen/blob/master/doc/DEPLOY.md
and there lein help deploying, but I couldn't find anything on signing

@denlab denlab closed this as completed Aug 7, 2012
@mikera
Copy link
Owner

mikera commented Aug 7, 2012

Solution was to upload via pscp, apparently clojars will do the generation of the SHA checksums automatically upon successful upload. More details here:

http://stackoverflow.com/questions/11837961/maven-deployment-timeout-failure-to-generate-checksums

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants