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

Usage with > 3.1.2 doesn't show the @implicitNotFound in Compare.scala #565

Open
ckipp01 opened this issue Jul 23, 2022 · 2 comments
Open
Milestone

Comments

@ckipp01
Copy link
Member

ckipp01 commented Jul 23, 2022

I came across this today when trying to update some stuff in the Dotty Community build and realized that munit when synced was actually failing in the community build. The error that it's failing with is the same that you see in #545 where the expected message for the @implicitNotFound on the Compare trait is no longer showing and instead you just get:

missing argument for parameter compare of method assertEquals in trait Assertions: (implicit loc: munit.Location, compare: munit.Compare[None.type, Some[Int]])

Looking at the commits between 3.1.2 and 3.1.3 it wasn't clear what was causing this, and I didn't try and bisect it yet.

You can see the same failures in a pr in Dotty here: https://github.com/lampepfl/dotty/runs/7481846884?check_suite_focus=true

@ckipp01
Copy link
Member Author

ckipp01 commented Jul 24, 2022

Also adding that when I try to minimally reproduce this same scenario with 3.1.2 and 3.1.3 in a hello world project that is using @implicitNotFound, both work fine. So it's something more involved here. Also looking more closely I think this might be a red herring and something else is going wrong here before it even needs to look for the @implicitNotFound message.

Actually in a minimal test I can reproduce this using 3.1.3 with:

  implicit val x: Compare[List[Int], Vector[Int]] = ???

  test("reproduce") {
    assertEquals[List[Int], Vector[Int]](List(1), Vector(1))
  }

The above works fine, but remove x and you won't see the @implicitNotFound message.

However, just trying to reproduce this minimally with a missing implicit in a regular file I can't reproduce.

@valencik
Copy link
Collaborator

valencik commented Feb 2, 2024

Ahh, I overlooked this issue and ran into the same problem here: #733

I was able to reproduce outside of munit and opened an issue upstream: scala/scala3#19594

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

2 participants