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

scoverage fails due to unresolved dependency path #392

Closed
prolific-dev opened this issue Nov 4, 2021 · 3 comments
Closed

scoverage fails due to unresolved dependency path #392

prolific-dev opened this issue Nov 4, 2021 · 3 comments

Comments

@prolific-dev
Copy link

prolific-dev commented Nov 4, 2021

IDE_version:

  • IntelliJ IDEA Ultimate 2021.2.3

Scala_version:

  • 3.1.0

build.properties:

  • sbt.version=1.5.5

libraryDependencies:

  • libraryDependencies += "org.scalactic" %% "scalactic" % "3.2.10"
  • libraryDependencies += "org.scalatest" %% "scalatest" % "3.2.10" % "test"

plugins:

  • addSbtPlugin("org.scoverage" % "sbt-scoverage" % "1.9.2")
  • addSbtPlugin("org.scoverage" % "sbt-coveralls" % "1.3.1")

CI/CD:

  • Travis CI
  • Coveralls.io

When I use the following commands inside the sbt shell sbt clean test everything just works fine.
As soon as I activate coverage before test and try to run the tests trough sbt I get following output.

[IJ]coverage
[info] Defining ThisBuild / coverageEnabled
[info] The new value will be used by Compile / compile / scalacOptions, libraryDependencies
[info] Reapplying settings...
[info] set current project to my-project (in build file:/D:/Projects/my-project/)
[IJ]test
[warn]
[warn]  Note: Unresolved dependencies path:
[error] stack trace is suppressed; run 'last update' for the full output
[error] (update) sbt.librarymanagement.ResolveException: Error downloading org.scoverage:scalac-scoverage-runtime_3:1.4.10
[error]   Not found
[error]   Not found
[error]   not found: C:\Users\USER\.ivy2\localorg.scoverage\scalac-scoverage-runtime_3\1.4.10\ivys\ivy.xml
[error]   not found: https://repo1.maven.org/maven2/org/scoverage/scalac-scoverage-runtime_3/1.4.10/scalac-scoverage-runtime_3-1.4.10.pom
[error] Total time: 0 s, completed 04.11.2021, 16:23:17

I already tried downgrading all versions of the visible plugins and dependencies to avoid the problem. Nothing really changed.

For me it seems like as I activate coverage sbt tries to reference a library which is not reachable. In this case it would for what ever reason be the pom file of scalac-scoverage-runtime_3\1.4.10\ that doesn't exist yet.

Has anyone an idea on that problem?

Thank you for helping me out!

PS.: Take it easy on me as this is my first issue I put out ever in my whole GitHub history.

@ckipp01
Copy link
Member

ckipp01 commented Nov 4, 2021

Hello! Thanks for reporting.

scoverage isn't yet published for Scala 3. You can track the progress on it here: scoverage/scalac-scoverage-plugin#299

@ckipp01 ckipp01 closed this as completed Nov 4, 2021
@SethTisue
Copy link

SethTisue commented Nov 4, 2021

welcome! :-)

@ckipp01
Copy link
Member

ckipp01 commented Nov 4, 2021

PS.: Take it easy on me as this is my first issue I put out ever in my whole GitHub history.

Whoa whoa whoa, hold the ☎️ . I must admit I read this quickly and didn't realize this was your first issue ever! Haha, sorry to close so quickly on your first issue! As Seth mentioned, welcome to the GitHub / Open Source / Scala world!

Your project is in Scala 3, which should hopefully be supported soon, but for the time being I'd recommend just removing the plugin altogether. Follow the future Scala 3 releases and you should see it announced in the upcoming releases that coverage is supported. When you see that, then add the plugin back in.

Please do report back if you have any other issues. Cheers and good luck!

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

No branches or pull requests

3 participants