-
Notifications
You must be signed in to change notification settings - Fork 352
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
Recipe or Marker for Missing TypeAttribution #4783
Comments
hi @amishra-u ; did you already come across rewrite/rewrite-java/src/main/java/org/openrewrite/java/search/FindMissingTypes.java Lines 34 to 329 in cdb945f
|
Thanks this is useful, only missing thing here is that it doesn't generate datatable. Would it be ok If I update the code to generate datatable? |
Yeah sure! Sounds like a good addition. |
What problem are you trying to solve?
In certain scenarios, OpenRewrite fails to add type attribution to some expressions. Currently, it does not provide any information about such expressions after parsing. When running a recipe on source files with these un-attributed expressions, it can result in inaccurate changes or recipe failures with exceptions.
Describe the solution you'd like
Similar to the FindParseFailures recipe, which generates a ParseError data table, we can introduce a TypeAttribution recipe. This recipe would scan all expressions with missing type attribution and generate a data table. This feature would help identify and debug issues in OpenRewrite's code. Additionally, when recipes make inaccurate changes, users could refer to this data table to rule out recipe-specific issues instead of having to analyze the recipe code.
Are you interested in [contributing this feature to OpenRewrite]
Yes
The text was updated successfully, but these errors were encountered: