librelist archives

« back to archive

Ignoring checksum failures on central

Ignoring checksum failures on central

From:
Stuart Sierra
Date:
2012-07-24 @ 17:58
Hi all,

Occasionally I run across directories in the Maven Central Repository
which lack all the appropriate checksum files. Leiningen 1.x ignores
this, but Leiningen 2.x fails.

I tried to override the check like this:

  :repositories {"central" {:url "http://repo1.maven.org/maven2"
                            :checksum :warn}}

But that seems to have no effect.

Is there a workaround?

Thanks,
-S

Re: [leiningen] Ignoring checksum failures on central

From:
Phil Hagelberg
Date:
2012-07-24 @ 18:51
Stuart Sierra <mail@stuartsierra.com> writes:

> Occasionally I run across directories in the Maven Central Repository
> which lack all the appropriate checksum files. Leiningen 1.x ignores
> this, but Leiningen 2.x fails.
>
> I tried to override the check like this:
>
>   :repositories {"central" {:url "http://repo1.maven.org/maven2"
>                             :checksum :warn}}
>
> But that seems to have no effect.

Interesting; that sounds like a bug in Leiningen. Do you have a specific
dependency declaration that triggers it so I can try to fix it?

At some point it would probably also be good to bring this to the
attention of the maintainers of the library with the offending checksum
too.

-Phil

Re: [leiningen] Ignoring checksum failures on central

From:
Stuart Sierra
Date:
2012-07-24 @ 21:43
Sure:

    [org.mongodb/mongo-java-driver "2.6.5"]

It's missing some of the checksum files:
http://central.maven.org/maven2/org/mongodb/mongo-java-driver/2.6.5/

I guess I can report this to ... Sonatype? Apache?
-S

Re: [leiningen] Ignoring checksum failures on central

From:
Sean Corfield
Date:
2012-07-24 @ 22:09
On Tue, Jul 24, 2012 at 2:43 PM, Stuart Sierra <mail@stuartsierra.com> wrote:
>     [org.mongodb/mongo-java-driver "2.6.5"]

FWIW, later versions of mongo-java-driver fixed this so it may have
been 10gen's fault that earlier versions were missing metadata?
-- 
Sean A Corfield -- (904) 302-SEAN
An Architect's View -- http://corfield.org/
World Singles, LLC. -- http://worldsingles.com/

"Perfection is the enemy of the good."
-- Gustave Flaubert, French realist novelist (1821-1880)

Re: [leiningen] Ignoring checksum failures on central

From:
Phil Hagelberg
Date:
2012-07-24 @ 22:10
On Tue, Jul 24, 2012 at 2:43 PM, Stuart Sierra <mail@stuartsierra.com> wrote:
> Sure:
>
>     [org.mongodb/mongo-java-driver "2.6.5"]
>
> It's missing some of the checksum files:
> http://central.maven.org/maven2/org/mongodb/mongo-java-driver/2.6.5/

It looks like the problem with your original attempt was that the
original definition of Central was taking precedence over the one you
specified. Adding `:omit-default-repositories true` allows the
:checksum setting to be applied. But that's a bug; the merge logic
should give your explicit Central declaration precedence. Tracking
this here: https://github.com/technomancy/leiningen/issues/697

> I guess I can report this to ... Sonatype? Apache?

I was thinking the fix should be performed by whoever maintains the
Mongo drivers, although it's curious that Sonatype allowed it to be
promoted to Central in this broken state.

-Phil