-
Notifications
You must be signed in to change notification settings - Fork 0
feat: checkstyle suppressions #1
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
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Pull request overview
This PR adds a checkstyle suppressions configuration file to suppress MemberName check violations for two member variables (m_autonomousCommand and m_robotContainer) in the Robot.java file that use the WPILib naming convention with the m_ prefix.
Key Changes:
- New
checkstyle-suppressions.xmlfile created with suppressions for MemberName violations in Robot.java
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
| message="m_autonomousCommand"/> | ||
|
|
||
| <suppress | ||
| files="src/main/java/frc/robot/Robot.java" | ||
| checks="MemberName" | ||
| message="m_robotContainer"/> |
Copilot
AI
Dec 24, 2025
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The 'message' attribute in suppress rules is intended to match the violation message text, not just the variable name. This configuration will only suppress violations where the message contains 'm_autonomousCommand', which may not work as expected. Consider using a more targeted approach by suppressing based on the line numbers or using a regex pattern in the 'id' or 'checks' attribute. Alternatively, you could modify the MemberName check pattern in checkstyle.xml to allow the WPILib naming convention (m_ prefix) rather than suppressing it.
| message="m_autonomousCommand"/> | |
| <suppress | |
| files="src/main/java/frc/robot/Robot.java" | |
| checks="MemberName" | |
| message="m_robotContainer"/> | |
| message=".*m_autonomousCommand.*"/> | |
| <suppress | |
| files="src/main/java/frc/robot/Robot.java" | |
| checks="MemberName" | |
| message=".*m_robotContainer.*"/> |
| checks="MemberName" | ||
| message="m_autonomousCommand"/> | ||
|
|
||
| <suppress | ||
| files="src/main/java/frc/robot/Robot.java" | ||
| checks="MemberName" | ||
| message="m_robotContainer"/> | ||
|
|
Copilot
AI
Dec 24, 2025
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The 'message' attribute in suppress rules is intended to match the violation message text, not just the variable name. This configuration will only suppress violations where the message contains 'm_robotContainer', which may not work as expected. Consider using a more targeted approach by suppressing based on the line numbers or using a regex pattern in the 'id' or 'checks' attribute. Alternatively, you could modify the MemberName check pattern in checkstyle.xml to allow the WPILib naming convention (m_ prefix) rather than suppressing it.
| checks="MemberName" | |
| message="m_autonomousCommand"/> | |
| <suppress | |
| files="src/main/java/frc/robot/Robot.java" | |
| checks="MemberName" | |
| message="m_robotContainer"/> | |
| checks="MemberName"/> |
No description provided.