Closed TonioGela closed 1 month ago
Thanks for reporting, looks like this might be caused by trees dependency from scalameta:
│ ├─ org.scalameta:trees_2.13:4.9.7
│ │ ├─ org.scala-lang:scala-library:2.13.14
│ │ └─ org.scalameta:common_2.13:4.9.7
│ │ ├─ com.thesamet.scalapb:scalapb-runtime_2.13:0.11.17
│ │ │ ├─ com.google.protobuf:protobuf-java:3.19.6
│ │ │ ├─ com.thesamet.scalapb:lenses_2.13:0.11.17
│ │ │ │ └─ org.scala-lang:scala-library:2.13.14
│ │ │ └─ org.scala-lang:scala-library:2.13.14
│ │ └─ org.scala-lang:scala-library:2.13.14
│ │ └─ org.scalameta:parsers_2.13:4.9.9
│ │ ├─ org.scala-lang:scala-library:2.13.11 -> 2.13.14
│ │ └─ org.scalameta:trees_2.13:4.9.9
│ │ ├─ org.scala-lang:scala-library:2.13.11 -> 2.13.14
│ │ └─ org.scalameta:common_2.13:4.9.9
│ │ ├─ com.lihaoyi:sourcecode_2.13:0.4.2
│ │ │ └─ org.scala-lang:scala-library:2.13.8 -> 2.13.14
│ │ └─ org.scala-lang:scala-library:2.13.11 -> 2.13.14
I am not sure how that changes especially that we used to shade it. A workaround for now would be just excluding sourcecode_2.13 either here or in typelevel toolkit.
I will take a look what happened on the scalameta side. There was a bit of reshuffling of modules
Thanks for solving this! Is there maybe a snapshot I can use to test tl-toolkit CI?
There will be a nightly to test out, but I think our CI is quite full at the moment
You can test out 1.4.3-9-g57d633514-SNAPSHOT/
I don't see the 2.13 sourcecode dependency anymore
Although, I might need to exclude scala-collection-compat
also :thinking:
It seems that shading didn't solve the original issue though: https://github.com/typelevel/toolkit/actions/runs/10400127288/job/28800129401
Wait, but where is com.lihaoyi:sourcecode_2.13
coming from?
Wait, but where is
com.lihaoyi:sourcecode_2.13
coming from?
I'm trying to figure it out, once I'll find it out I'll tell you :)
Maybe, we still haven't published the fixed version :thinking:
Maybe, we still haven't published the fixed version 🤔
Might be, I think this was the CI run pointing at this branch getting into main: https://github.com/VirtusLab/scala-cli/actions/runs/10387953976
As an alternative, you can do:
"com.lihaoyi" %% "sourcecode" % "0.4.3" % Test,
"org.scala-lang.modules" %% "scala-collection-compat" % "2.12.0" % Test,
("org.virtuslab.scala-cli" %% "cli" % "1.4.3" cross (CrossVersion.for2_13Use3))
.exclude("com.lihaoyi", "sourcecode_2.13")
.exclude("org.scala-lang.modules", "scala-collection-compat_2.13")
uncomment the deps added if it turns out it break otherwise this should work
And in the meantime https://github.com/VirtusLab/scala-cli/pull/3105 should work.
I forgot that we need exact name of the artifact with _2.13
As an alternative, you can do:
"com.lihaoyi" %% "sourcecode" % "0.4.3" % Test, "org.scala-lang.modules" %% "scala-collection-compat" % "2.12.0" % Test, ("org.virtuslab.scala-cli" %% "cli" % "1.4.3" cross (CrossVersion.for2_13Use3)) .exclude("com.lihaoyi", "sourcecode_2.13") .exclude("org.scala-lang.modules", "scala-collection-compat_2.13")
~uncomment the deps added if it turns out it break otherwise~ this should work
Yes, of course, thanks :D That's the way that I would have followed in case you would have closed this as a won't fix
for the aforementioned reasons.
I have the general feeling that you (meaning the contributors of this project) don't completely dislike the fact that the typelevel toolkit tests are constantly probing the cli
artifact, that's why I'm here 😇
It's always good to report things like this, we might not be able to fix them right away, but it's good to know when something is off (and this case certainly is a bit off)
Version(s) 1.4.1+
Describe the bug Very much like it happened for #2809 (hence the name of the this bug) something in the publication strategy of
org.virtuslab.scala-cli::cli
might have changed since version 1.4.1 as in the compilation of the tests packages of the typelevel toolkit (for all versions and platforms) we're experiencing the following exception:and we haven't really changed anything on our side.
Keeping in mind what @Gedochao once said
those are internal APIs, not necessarily prepared for external use (so there's no guarantees on our side, really)
I still felt like raising a bug, because this might be simply highlighting something more serious.To Reproduce Declaring
org.virtuslab.scala-cli::cli
as a dependency in any 2.13 or 3 project won't make the tool able to correctly solve the dependency.Thanks in advance for any help or info that you might provide.