Skip to content

chore: improve exceptions quality and add comprehensive tests#85

Open
jaodsilv wants to merge 1 commit intomainfrom
chore/issue-23-exceptions-quality
Open

chore: improve exceptions quality and add comprehensive tests#85
jaodsilv wants to merge 1 commit intomainfrom
chore/issue-23-exceptions-quality

Conversation

@jaodsilv
Copy link
Copy Markdown
Owner

@jaodsilv jaodsilv commented Apr 2, 2026

Summary

  • Renamed FileIOError to GrindPulseIOError for clearer namespace scoping
  • Made file_path a required parameter in DataFileNotFoundError and DataFileEmptyError
  • Added line_number >= 1 validation in TSVParseError
  • Passed file_path to ValidationError in data_parser.py
  • Fixed hardcoded path in data_parser.py docstring
  • Added comprehensive test coverage for all exception classes

Test plan

  • All existing tests pass
  • New tests in tests/python/test_exceptions.py cover all exception classes
  • file_path required parameter enforcement verified
  • line_number validation boundary conditions tested

Closes #23

- Rename FileIOError to GrindPulseIOError with backward-compat alias
- Add required file_path parameter to DataFileNotFoundError and DataFileEmptyError
- Add validation for TSVParseError line_number (must be >= 1)
- Add comprehensive test suite in tests/python/test_exceptions.py
- Update data_parser.py to use new exception signatures
- Improve docstrings and error messages
@github-actions
Copy link
Copy Markdown

github-actions bot commented Apr 2, 2026

Build Size

tracker.html: 866.28KB

Built with Python 3.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.

Code quality improvements for exceptions module

1 participant