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

Use coursier to get dependencies #1144

Conversation

manuelcueto
Copy link
Contributor

closes #1139

What do you think @fthomas ?

Would this (UpdateAlg.findUpdateUnderNewGroup) in line 115 have to be reimplemented?

@codecov
Copy link

codecov bot commented Dec 9, 2019

Codecov Report

Merging #1144 into master will decrease coverage by 0.75%.
The diff coverage is 0%.

Impacted file tree graph

@@            Coverage Diff             @@
##           master    #1144      +/-   ##
==========================================
- Coverage   69.74%   68.99%   -0.76%     
==========================================
  Files          93       93              
  Lines        1408     1390      -18     
  Branches       38       39       +1     
==========================================
- Hits          982      959      -23     
- Misses        426      431       +5
Impacted Files Coverage Δ
...la/org/scalasteward/core/application/Context.scala 0% <ø> (ø) ⬆️
.../main/scala/org/scalasteward/core/sbt/SbtAlg.scala 94.11% <ø> (-5.89%) ⬇️
...ala/org/scalasteward/core/nurture/NurtureAlg.scala 8.82% <0%> (-0.09%) ⬇️
.../scala/org/scalasteward/core/data/Dependency.scala 60% <0%> (-40%) ⬇️

Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update b822e2d...8ed8fb9. Read the comment docs.

@fthomas
Copy link
Member

fthomas commented Dec 9, 2019

If we want to get rid of getUpdatesForRepo, we need to have #1141 first so that we also find updates of dependencies that are only in private repositories. My intention with #1139 was to only replace withTemporarySbtDependency with UpdateAlg.findUpdate. withTemporarySbtDependency allows us to also get updates of org.scala-sbt:sbt and org.scalameta:scalafmt-core which are then used to update the sbt version in project/build.properties and the scalafmt version in .scalafmt.conf. To find updates of these two dependencies, support for custom repositories in CoursierAlg is not needed.

@manuelcueto
Copy link
Contributor Author

Ohh i see. I first tried calling findUpdate from SbtAlg but i couldn't create it because it was creating a Circular Dependency.

@fthomas
Copy link
Member

fthomas commented Dec 9, 2019

Oh, I didn't noticed that there would be circular dependency if findUpdate is used in SbtAlg. Which class is causing it?

@manuelcueto
Copy link
Contributor Author

manuelcueto commented Dec 10, 2019

RepoCacheAlg needs SbtAlg And UpdateAlg needs RepoCacheAlg
so SbtAlg cannot need UpdateAlg.
(at least the way it's done now)

@fthomas
Copy link
Member

fthomas commented Dec 10, 2019

I think we should split UpdateAlg into two classes. One contains findUpdate, findUpdateUnderNewGroup, and getNewerGroupId and the other one the rest which just exists for the "pruning repos" implementation.

fthomas added a commit that referenced this pull request Dec 11, 2019
@fthomas
Copy link
Member

fthomas commented Jan 22, 2020

Superseded by #1209.

@fthomas fthomas closed this Jan 22, 2020
@fthomas fthomas added the enhancement New feature or request label Feb 2, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Find updates of sbt and scalafmt with CoursierAlg
2 participants