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

Upgrade clj-http to 2.0.0 #2032

Merged
merged 1 commit into from
Dec 9, 2015
Merged

Upgrade clj-http to 2.0.0 #2032

merged 1 commit into from
Dec 9, 2015

Conversation

danielcompton
Copy link
Collaborator

This makes a lot of it's dependencies optional, including tools.reader.

@danielcompton
Copy link
Collaborator Author

clj-http is only used once in leiningen.search for a simple GET.

@hypirion
Copy link
Collaborator

Yeah, clj-http itself is only used for leiningen.search, but there are some transitive deps here too:

<  [clj-http "0.9.2" :exclusions [[crouton] [potemkin]]]
<    [commons-codec "1.9" :exclusions [[org.clojure/clojure]]]
<    [org.apache.httpcomponents/httpclient "4.3.3" :exclusions [[org.clojure/clojure]]]
<    [org.apache.httpcomponents/httpcore "4.3.2" :exclusions [[org.clojure/clojure]]]
<    [org.apache.httpcomponents/httpmime "4.3.3" :exclusions [[org.clojure/clojure]]]
<    [org.clojure/tools.reader "0.8.4" :exclusions [[org.clojure/clojure]]]
---
>  [clj-http "2.0.0"]
>    [commons-codec "1.10" :exclusions [[org.clojure/clojure]]]
>    [org.apache.httpcomponents/httpclient "4.5" :exclusions [[org.clojure/clojure]]]
>    [org.apache.httpcomponents/httpcore "4.4.1" :exclusions [[org.clojure/clojure]]]
>    [org.apache.httpcomponents/httpmime "4.5" :exclusions [[org.clojure/clojure]]]

Pomegranate depends on wagon-http, which depends on 4.1.x-versions of httpclient and httpcore.

I am guessing this is fine as httpcomponents have strict backwards compatibility, but I'd like a quick verification of that. Seems to work without issues here. (Preferably also with someone using the s3-wagon-private plugin should verify this).

Would be happy to merge it in if someone else could verify that this works, both for deploy and fetching dependencies from clojars/maven central.

@danielcompton
Copy link
Collaborator Author

Using lein-master, I was able to download dependencies from central, clojars and a private S3 wagon. I was able to deploy to the private S3 wagon, but I wasn't able to deploy to Clojars. I was able to deploy the same library to Clojars with lein 2.5.3. I got the following error message

lein-master deploy
<my private GPG creds printed out here>
java.lang.NullPointerException: null
 at java.io.StringReader.<init> (StringReader.java:50)
    clojure.lang.RT.readString (RT.java:1820)
    clojure.lang.RT.readString (RT.java:1816)
    clojure.core$read_string.invoke (core.clj:3663)
    leiningen.core.user$credentials_fn.invoke (user.clj:143)
    leiningen.core.user$credentials_fn.invoke (user.clj:134)
    clojure.lang.AFn.applyToHelper (AFn.java:152)
    clojure.lang.AFn.applyTo (AFn.java:144)
    clojure.core$apply.invoke (core.clj:630)
    clojure.core$memoize$fn__5479.doInvoke (core.clj:6082)
    clojure.lang.RestFn.invoke (RestFn.java:397)
    leiningen.core.user$resolve_credential$resolve__7011.invoke (user.clj:165)
    leiningen.core.user$resolve_credential.invoke (user.clj:174)
    clojure.core$partial$fn__4527.invoke (core.clj:2494)
    clojure.core.protocols$iter_reduce.invoke (protocols.clj:49)
    clojure.core.protocols/fn (protocols.clj:112)
    clojure.core.protocols$fn__6452$G__6447__6465.invoke (protocols.clj:13)
    clojure.core$reduce.invoke (core.clj:6519)
    leiningen.core.user$resolve_credentials.invoke (user.clj:183)
    leiningen.core.classpath$add_repo_auth.invoke (classpath.clj:67)
    leiningen.deploy$repo_for.invoke (deploy.clj:72)
    leiningen.deploy$deploy.invoke (deploy.clj:197)
    leiningen.deploy$deploy.invoke (deploy.clj:186)
    clojure.lang.Var.invoke (Var.java:379)
    clojure.lang.AFn.applyToHelper (AFn.java:154)
    clojure.lang.Var.applyTo (Var.java:700)
    clojure.core$apply.invoke (core.clj:632)
    leiningen.core.main$partial_task$fn__6449.doInvoke (main.clj:272)
    clojure.lang.RestFn.invoke (RestFn.java:410)
    clojure.lang.AFn.applyToHelper (AFn.java:154)
    clojure.lang.RestFn.applyTo (RestFn.java:132)
    clojure.lang.AFunction$1.doInvoke (AFunction.java:29)
    clojure.lang.RestFn.applyTo (RestFn.java:137)
    clojure.core$apply.invoke (core.clj:632)
    leiningen.core.main$apply_task.invoke (main.clj:322)
    leiningen.core.main$resolve_and_apply.invoke (main.clj:328)
    leiningen.core.main$_main$fn__6515.invoke (main.clj:401)
    leiningen.core.main$_main.doInvoke (main.clj:394)
    clojure.lang.RestFn.invoke (RestFn.java:408)
    clojure.lang.Var.invoke (Var.java:379)
    clojure.lang.AFn.applyToHelper (AFn.java:154)
    clojure.lang.Var.applyTo (Var.java:700)
    clojure.core$apply.invoke (core.clj:630)
    clojure.main$main_opt.invoke (main.clj:316)
    clojure.main$main.doInvoke (main.clj:421)
    clojure.lang.RestFn.invoke (RestFn.java:436)
    clojure.lang.Var.invoke (Var.java:388)
    clojure.lang.AFn.applyToHelper (AFn.java:160)
    clojure.lang.Var.applyTo (Var.java:700)
    clojure.main.main (main.java:37)

It doesn't really look like it's related to the clj-http change (at least not directly), but it needs to be checked out.

This makes a lot of it's dependencies optional, including tools.reader.
@danielcompton
Copy link
Collaborator Author

Rebasing my commit against master let me deploy correctly to clojars as well. This is working for me now.

@hypirion
Copy link
Collaborator

hypirion commented Dec 9, 2015

Alright, that's good enough for me. Thanks for verifying

hypirion added a commit that referenced this pull request Dec 9, 2015
@hypirion hypirion merged commit f3ed8e4 into technomancy:master Dec 9, 2015
@danielcompton danielcompton deleted the upgrade-clj-http-2-0-0 branch December 9, 2015 18:52
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

Successfully merging this pull request may close these issues.

None yet

2 participants