v0.3.0
Release v0.3.0
🎯 Major Update - Enhanced Assertions & Documentation
py-logguard features a completely revamped assertion system, improved exception hierarchy, and comprehensive documentation updates.
✨ Features
- Revamped Assertion System: Complete overhaul with enhanced documentation and flexible failure handling in development and production environments
- New Assertion Exceptions: Added specialized exceptions for assert operations with improved error handling
- Demo Script: Added comprehensive demo script showcasing LogGuard capabilities
- Makefile Enhancement: New
lint-fixtarget for automatic code fixing with Ruff
Note: This release includes breaking changes to the assertion system. Please review the updated documentation for migration details.
🐛 Bug Fixes
- Fixed issues with assertion error handling, now properly raising exceptions instead of logging errors in production environments
- Fixed
get_loggerfunction to ensure correct logger retrieval and configuration:- Before:
get_loggeralways created a new logger instance, leading to potential issues with multiple loggers and inconsistent logging, requiring setforce=Trueto override existing loggers
- Before:
🔄 Refactoring
- Exception Hierarchy: Migrated from
AppBaseErrortoLogGuardErroras the base exception class for better naming consistency - AppLogger Enhancement: Improved logging configuration logic and documentation
- Handler Management: Better AppLogger setup and improved handler management
- Lazy Loading: Optimized imports and lazy loading for better performance
- Repository Cleanup: Removed outdated example scripts to streamline repository structure
📚 Documentation
- Package Documentation: Updated for clarity and improved structure
- README Updates: Comprehensive README update highlighting new features and capabilities
- Enhanced Docstrings: Improved documentation across all modules
🧪 Testing
- Updated Tests: New comprehensive tests for version 0.3.0 features
- Assertion Tests: Enhanced test coverage for the new assertion system