openrewrite / rewrite-third-party

OpenRewrite recipes maintained by third parties.
Apache License 2.0
1 stars 1 forks source link

Mismatches on some rules, but not all, when running EPS v0.16.0 recipes through the platform #5

Closed timtebeek closed 6 months ago

timtebeek commented 6 months ago

A run of TimeRulesRecipes with results: https://app.moderne.io/results/etD0xEAcI

A run of JUnitToAssertJRulesRecipes without any results: https://app.moderne.io/results/BgfO0Wp2C Whereas this classic AssertJ migration does have a ton of results: https://app.moderne.io/results/pjjEWSdi3

knutwannheden commented 6 months ago

Interesting. Already got any leads?

timtebeek commented 6 months ago

Haven't had time to dive in, and with how my agenda is looking it'll be a month. :)

knutwannheden commented 6 months ago

One thing which strikes me as problematic is the fact that the dependencies of error-prone-contrib are declared as provided: https://github.com/PicnicSupermarket/error-prone-support/blob/23ceb4aa6b2429283b0dec39ff073965b31b800b/error-prone-contrib/pom.xml#L140-L144

For error-prone-contrib this makes perfect sense, but when running the recipes in the SaaS, these dependencies won't be on the classpath unless they are also on the recipe artifact's classpath.

This might not be the only problem at hand here, but this definitely also needs correcting.

Stephan202 commented 6 months ago

One thing which strikes me as problematic is the fact that the dependencies of error-prone-contrib are declared as provided: PicnicSupermarket/error-prone-support@23ceb4a/error-prone-contrib/pom.xml#L140-L144

For error-prone-contrib this makes perfect sense, but when running the recipes in the SaaS, these dependencies won't be on the classpath unless they are also on the recipe artifact's classpath.

This might not be the only problem at hand here, but this definitely also needs correcting.

Interesting. We wouldn't want to make e.g. AssertJ a runtime dependency of Error Prone Support. Do you propose to do "something" on the OpenRewrite SaaS-side, or should we look into creating a custom artifact? (I didn't think yet about what this could look like.)