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

introduce suggested fixes for potentially unsafe or undesired fixes #207

Open
ajafff opened this issue Apr 20, 2018 · 0 comments
Open

introduce suggested fixes for potentially unsafe or undesired fixes #207

ajafff opened this issue Apr 20, 2018 · 0 comments

Comments

@ajafff
Copy link
Member

ajafff commented Apr 20, 2018

Some fixes may break the code but actually reveal errors, e.g. #186.
Then there are fixes that disguise an actual problem, e.g. #181 or #203. These are better fixed manually by the developer.
And then there are fixes that you don't want to happen automatically in your IDE if you use autofix-on-save, e.g. no-debugger.

This proposes adding a new category of fixes that may advertised in IDEs and other integrations. These fixes will not be automatically fixed with --fix.

TBD

  • What does the API look like?
    • introduce a Failure class that has setters for regular fixes and suggested fixes?
    • introduce a Fix class with a category field
      • addFailure would then accept any number of fixes as variadic argument.
      • allows a failure to suggest different fixes for the same issue
  • Each Fix needs a name/description so the user knows what it does
  • Add CLI option to automatically apply all suggested fixes?
  • How does this work with baseline testing?
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

1 participant