tools-deps

Discuss tools.deps.alpha, tools.build, and the clj/clojure command-line scripts! See also #depstar #clj-new
danieroux 2020-07-17T08:51:18.421400Z

@kenny This is how I solved it:

mvn org.apache.maven.plugins:maven-install-plugin:3.0.0-M1:install-file -Dfile=dev-local-0.9.172.jar -DlocalRepositoryPath=s3_m2_repository
aws s3 sync s3_m2_repository <s3://matter-mvn-repo/releases>

kenny 2020-07-21T02:30:25.445200Z

This approach still results in the Download corrupted: Checksum validation failed, no checksums available warning message though 😞

danieroux 2020-07-17T09:06:39.421900Z

@drewverlee I have entries like these: org.slf4j/slf4j-api {:mvn/version "1.7.14" :required-by :datomic-cloud}

kenny 2020-07-17T15:29:08.422Z

Oh, nice! This seems like it'd upload all the necessary files. Sweet.

alexmiller 2020-07-17T21:03:38.423800Z

hey clj super fans, there is a new version of clj (and tools.deps) out and I'd love to have some people try it and verify no dep tree differences. you can install the latest dev release with:

brew uninstall clojure
brew install --devel clojure/tools/clojure

alexmiller 2020-07-17T21:06:58.426300Z

the change of note here is I have rewritten how exclusions are handled if the same dep shows up more than once in the dep tree with different exclusion sets. this is uncommon, but possible and most commonly happens by having the dep with exclusions in one place and with no exclusions in another. in the past, what happened was somewhat arbitrary - depending which you first encountered you may get the dep or not.

alexmiller 2020-07-17T21:08:24.427700Z

the updated behavior is that you will get the intersection of exclusion sets from all occurrences, so in the case above you will always get the dep

alexmiller 2020-07-17T21:09:49.429Z

in the process of implementing this, I've also substantially refactored the deps expansion code to make it easier to work on and comprehend. while those changes should be a no op, I did change a lot of code and well, you know.

alexmiller 2020-07-17T21:10:17.429500Z

so if anyone has time to do a sanity check, that would be cool

alexmiller 2020-07-17T21:12:59.432300Z

also, in the process of checking these changes, it's become clearer to me that -Stree is likely to lie to you about what happened in exclusion cases like the above, because it's based on the lib map, which is an inverted tree that loses exclusion path info. I'm going to rewrite it in terms of the trace data and then it will be both correct but can also include substantially more useful information (akin to tools.deps.graph trace mode). but going to do other work first.

seancorfield 2020-07-17T21:24:41.432400Z

@alexmiller I expect you know about this

Warning: Calling 'devel' blocks in formulae is deprecated! Use 'head' blocks or @-versioned formulae instead.
Please report this issue to the clojure/tools tap (not Homebrew/brew or Homebrew/core), or even better, submit a PR to fix it:
  /usr/local/Homebrew/Library/Taps/clojure/homebrew-tools/Formula/clojure.rb:7

alexmiller 2020-07-17T21:26:02.432600Z

yeah

alexmiller 2020-07-17T21:26:29.432800Z

brew breaks things faster than I can fix them

seancorfield 2020-07-17T21:27:32.433Z

Then I got

==&gt; Downloading <https://download.clojure.org/install/clojure-tools-1.10.1.561.ta>
######################################################################## 100.0%
Error: clojure 1.10.1.536 is already installed
To upgrade to 1.10.1.561, run `brew upgrade clojure/tools/clojure`.
==&gt; `brew cleanup` has not been run in 30 days, running now...
and it did not actually upgrade clojure 😐

seancorfield 2020-07-17T21:28:16.433200Z

(! 1406)-&gt; clojure -Sdescribe
{:version "1.10.1.547"
 :config-files ["/usr/local/Cellar/clojure/1.10.1.547/deps.edn" "/Users/sean/.clojure/deps.edn" ]

seancorfield 2020-07-17T21:28:23.433400Z

Which is not 561

alexmiller 2020-07-17T21:29:04.433600Z

oh, sorry

alexmiller 2020-07-17T21:29:12.433800Z

brew upgrade --devel clojure/tools/clojure

seancorfield 2020-07-17T21:29:21.434Z

Nope, that doesn't work either.

seancorfield 2020-07-17T21:29:34.434200Z

Error: invalid option: --devel

alexmiller 2020-07-17T21:29:37.434400Z

well then brew uninstall clojure first

alexmiller 2020-07-17T21:30:23.434700Z

then install --devel

seancorfield 2020-07-17T21:30:25.434900Z

(! 1413)-&gt; clojure -Sdescribe
{:version "1.10.1.561"
 :config-files ["/usr/local/Cellar/clojure/1.10.1.561/deps.edn" "/Users/sean/.clojure/deps.edn" ]
Had to uninstall then install --devel

alexmiller 2020-07-17T21:31:05.435200Z

yeah, that's the correct one

seancorfield 2020-07-17T21:32:09.435900Z

A quick test shows that it doesn't attempt to download any new dependencies for our monorepo so that looks sane.

alexmiller 2020-07-17T21:33:11.436100Z

:)

alexmiller 2020-07-17T21:34:09.437100Z

having a new clj should make everything stale (so effectively -Sforce), but maybe -Sforce too?

seancorfield 2020-07-17T21:35:27.438300Z

I'm running our script that checks for updated versions of deps -- it builds new projects with our deps and then runs -Stree in those so there no cache. I'll let you know if that turns up any differences.

seancorfield 2020-07-17T21:36:40.438900Z

Looks good. It detected a new version of org.apache.axis/axis and all the other dependencies remained unchanged.

seancorfield 2020-07-17T21:36:50.439200Z

(that script hammers clojure -Stree 🙂 )

seancorfield 2020-07-17T21:43:26.440Z

Just for good measure, I blew away the cache folder in every subproject in our monorepo and rebuilt things. No changes in deps as far as I can tell.

alexmiller 2020-07-17T21:45:04.440500Z

Thanks, good to have someone else try it :)

seancorfield 2020-07-17T21:45:52.441Z

You know me -- always happy to be on the bleeding edge!

kenny 2020-07-17T22:06:28.442100Z

I can try this. @seancorfield how did you check for differences? Set diff of classpath?

seancorfield 2020-07-17T22:16:39.442400Z

Just compared -Stree before and after.

seancorfield 2020-07-17T22:17:33.443100Z

But also ran our test suite to see if any new dependencies got downloaded (none).