-
-
Notifications
You must be signed in to change notification settings - Fork 1.2k
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
Can't use Scala 3 artifact with Scala 2 #4304
Comments
I'm inclined to say this is not officially supported. |
Such a quick response 😲 Yeah, I'm aware that mixing |
Right, it's not about whether it's evil or not. It's more that you can't rely on this technique, because it doesn't really work. The fundamental issue here is that the Scala 3 build of Cats relies on So not really sure what you can do about that. My best advice is to pin to an older version of Cats that doesn't have this requirement. Or, maybe you can try shimming it in Scala 2. |
Artifact for Scala 3 is generated with this annotation taken into account. If yes, isn't it only a matter of support for it in tasty reader? I'm not an expert here, just thinking loudly. Pinning to |
@bishabosha do you think tasty reader could help in this case? EDIT: sorry for pinging, I've been not thinking clearly at that moment and it was unnecessary 😅 |
I am not sure what you mean. In any case this seems like a question/issue for the dotty team. Perhaps a minimum reproduction would help with that investigation.
Your error message says:
I propose one way to fix that, is to define the missing class yourself, so it is on the classpath :) |
@armanbilge I have to ask, are you a single person or are you a facade for a whole bunch of people? The amount of your activity and contributions is just insane :D Clearly, after one week of migrating stuff I'm not thinking anymore, have to reset mind and I'll try workaround which you proposed. Thank you very much from the bottom of my ❤️ |
so using the |
I investigated a little bit and |
@armanbilge my recommendation is that |
@bishabosha thanks for the investigation. Sure, we can make that change. A PR from you or @kpodsiad would be appreciated! |
[OFFTOPIC] @kpodsiad I just noticed that you quoted my tweet 😂 [EDIT] I added a pr too following @bishabosha suggestion! |
if you directly use |
Thank @bishabosha. At least now we have a way to perform what @kpodsiad was asking in the issue. Plus, that annotation renaming is in a private package, so technically, library users shouldn't be able to access it. /cc @armanbilge |
I do not see how that would be possible. cats/core/src/main/scala/cats/Invariant.scala Lines 129 to 132 in bf216a4
|
Hey, is this possible to use
cats-core_3
with Scala 2?fails with
can't find type required by method catsInstancesForIdCompat2_6_1 in object cats.Invariant: compat.targetName; perhaps it is missing from the classpath.
I was able to find source code but I'm still not sure if this should be considered as a bug.
The text was updated successfully, but these errors were encountered: