getClass.getResource
yields wrong result using 1.9.9 with sbtPlugin := true
#7514
Labels
getClass.getResource
yields wrong result using 1.9.9 with sbtPlugin := true
#7514
steps
See https://github.com/agboom/sbt-resource-test for a repro project.
problem
In a nutshell: when I call
getClass.getResource
in sbt 1.9.8, the local resource directory URL is returned.In 1.9.9, a Jar URL is returned:
jar:file:~/.sbt/boot/scala-2.12.18/org.scala-sbt/sbt/1.9.9/jansi-2.4.1.jar!/META-INF/versions/9/
.I created a repro, with a GH workflow that reproduces the problem. The workflow run with logs can be found here: https://github.com/agboom/sbt-resource-test/actions/runs/8297335057
For completeness I added both Java 11 and 17 to the build matrix, but the Java version doesn't seem to affect or cause the bug.
expectation
I expect the behavior to be the same as 1.9.8
notes
This is my first issue here, so let me know if you need more information.
Looking at the diff between 1.9.8 and 1.9.9, the Jansi dependency seems to have been updated. Could this be part of the cause? v1.9.8...v1.9.9#diff-ad2642dc77b3679e4ad2c7d3b2f59a2dcf48c1bf5b93a558a4fa44828315a34cR96
The text was updated successfully, but these errors were encountered: