Skip to content

Conversation

@Borda
Copy link
Member

@Borda Borda commented Jan 7, 2026

This pull request includes minor updates to the .pre-commit-config.yaml and a test utility file. The main focus is on improving consistency and formatting in test content and pre-commit hook configuration.

Formatting and configuration improvements:

  • Updated the FILE_2_CONTENT string in test/utils/test_file.py to have consistent newline and whitespace formatting.
  • Removed the exclude: test/.*\.py rule from the trailing-whitespace hook in .pre-commit-config.yaml, so test files will now be checked for trailing whitespace.

Copilot AI review requested due to automatic review settings January 7, 2026 12:58
@Borda Borda requested a review from SkalskiP as a code owner January 7, 2026 12:58
Copy link
Contributor

Copilot AI left a 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 pull request removes the exclusion of test files from the trailing-whitespace pre-commit hook and updates test fixtures to comply with the stricter formatting requirements.

Key Changes:

  • Removed the exclude: test/.*\.py rule from the trailing-whitespace hook in pre-commit configuration, making trailing whitespace checks apply to all Python files including tests
  • Refactored FILE_2_CONTENT test fixture to eliminate trailing whitespace while maintaining semantic equivalence by converting the multiline string format to use an escaped newline character
  • Removed the # noqa comment that was previously suppressing the trailing whitespace linting warning

Reviewed changes

Copilot reviewed 2 out of 2 changed files in this pull request and generated no comments.

File Description
.pre-commit-config.yaml Removed test directory exclusion from trailing-whitespace hook to apply consistent formatting checks across all Python files
test/utils/test_file.py Refactored FILE_2_CONTENT string literal to eliminate trailing whitespace by using escaped newline notation, and removed the now-unnecessary noqa comment

The changes in this PR are correct and achieve the stated goal. The string refactoring in test/utils/test_file.py maintains semantic equivalence (the resulting string value is identical), while eliminating the trailing whitespace that previously required a linting suppression comment. The pre-commit configuration change makes formatting checks more consistent across the codebase by removing the special exception for test files.


💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

@Borda Borda enabled auto-merge (squash) January 9, 2026 08:12
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants