Skip to content

[Rule] Disabler found but no issue was raised #1312

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

Open
bhirsz opened this issue Mar 12, 2025 · 0 comments
Open

[Rule] Disabler found but no issue was raised #1312

bhirsz opened this issue Mar 12, 2025 · 0 comments
Labels
rule Issue related to creating or changing a rule

Comments

@bhirsz
Copy link
Member

bhirsz commented Mar 12, 2025

Disablers are typically added in two occassions:

  • issues in user code that they want to fix later, and they don't want to disable globally
  • issues in Robocop itself thay causes some invalid positives for some cases

If user fixes the issue but don't take the disabler, or Robocop release the fix we are left with unnecessary disabler:

*** Keywords ***
Used in EXCEPT branch
    [Arguments]    ${arg1}    ${arg2}
    TRY
        May Fail    ${arg1}  # robocop: off  it could be disabled because in the past we actually didn't use it, but then fixed it
    EXCEPT    ${arg2}  # robocop: off  it was disabled because Robocop was incorrectly raising here
        No Operation

We should have rule that catches such issue. Implementation would compare disabler class and raised issues (with their ranges). If there is disabler but no rule is matching, we will raise an issue.

@bhirsz bhirsz added the rule Issue related to creating or changing a rule label Mar 12, 2025
@bhirsz bhirsz changed the title [Rule] Disabler found but not issue was raised [Rule] Disabler found but no issue was raised Mar 12, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
rule Issue related to creating or changing a rule
Projects
None yet
Development

No branches or pull requests

1 participant