You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
[error] undefined: new simulacrum.noop # 1982310: TermRef(TypeRef(TermRef(ThisType(TypeRef(NoPrefix,module class <root>)),module simulacrum),noop),<init>) at sbt-api
[warn] sbt-api: Unhandled type class dotty.tools.dotc.core.Types$$anon$7 : <error undefined: new simulacrum.noop # 1982310: TermRef(TypeRef(TermRef(ThisType(TypeRef(NoPrefix,module class <root>)),module simulacrum),noop),<init>) at sbt-api>
You can reproduce this by attempting to build Cats Effect series/2.x branch against Cats 2.3.0-M1 removing the withDottyCompat on the dependencies. We originally thought this was because simulacrum-scalafix was being stripped from the Cats POM, but I removed that in this PR, published locally, and still see the above.
Just to push even further, I explicitly added "org.typelevel" %% "simulacrum-scalafix-annotations" % "0.5.1" % Provided to the corelibraryDependencies and it appears to have gotten further. I think I also have to add it to laws, but you see where this is going. It just generally appears that annotations, defined in Scala and published against Dotty, when used by an upstream project, do not correctly parse on the downstream project unless the annotation library is a direct dependency.
This is probably fixable by removing % Provided in the Cats build, but then simulacrum-scalafix is on everyone's classpath randomly.
The text was updated successfully, but these errors were encountered:
Oh, to make matters simpler, I'm relatively certain this can be reproduced with any project which depends on Cats, but I just happened to be working on CE.
We originally thought this was because simulacrum-scalafix was being stripped from the Cats POM, but I removed that in this PR, published locally, and still see the above.
You removed the pom-stripping but kept the % Provided so it's likely still missing from the classpath. My guess is that porting sbt/zinc#701 will fix this.
You removed the pom-stripping but kept the % Provided so it's likely still missing from the classpath
I can confirm this is exactly the problem. Adding it to the laws project as well as core in CE resolves it downstream.
Just to be clear, this is a regression from Scala 2 behavior, where this kind of thing was fine. I do think magic comments would be better than annotations in this case. We'll probably workaround this in cats for the time being by just putting simulacrum on the transitive classpath.
The error I get is as follows:
You can reproduce this by attempting to build Cats Effect
series/2.x
branch against Cats 2.3.0-M1 removing thewithDottyCompat
on the dependencies. We originally thought this was because simulacrum-scalafix was being stripped from the Cats POM, but I removed that in this PR, published locally, and still see the above.Just to push even further, I explicitly added
"org.typelevel" %% "simulacrum-scalafix-annotations" % "0.5.1" % Provided
to thecore
libraryDependencies
and it appears to have gotten further. I think I also have to add it tolaws
, but you see where this is going. It just generally appears that annotations, defined in Scala and published against Dotty, when used by an upstream project, do not correctly parse on the downstream project unless the annotation library is a direct dependency.This is probably fixable by removing
% Provided
in the Cats build, but then simulacrum-scalafix is on everyone's classpath randomly.The text was updated successfully, but these errors were encountered: