This release modernizes the SignalRGB Python library with improved dependency management, enhanced CLI features, expanded API capabilities, and better error handling. It introduces layout management, preset handling, and improved visual output while migrating from Poetry to UV for more reliable package management.
โจ Highlights
๐ง Migration to UV Package Manager
Switched from Poetry to UV for faster, more reliable dependency management with broader Python version compatibility (now supporting Python 3.9+).
๐ Enhanced CLI Experience
Completely revamped CLI with colorful output, improved table formatting, and a new subcommand structure that makes working with effects and layouts more intuitive.
โจ Layout Management
Added new functionality to view, list, and switch between SignalRGB layouts, expanding the library's capabilities beyond just effect control.
โป๏ธ Python 3.11 Type Hints
Modernized codebase with improved type annotations using Python 3.11 features, making the library more robust and developer-friendly.
โจ New Features
- Implemented layout management functionality with methods to get current layout, set layout, and list available layouts
- Added rich preset handling with ability to list and apply effect presets
- Introduced effect navigation with next, previous, and random effect selection
- Added --full-rgb flag to CLI for vibrant gradient-colored output
- Implemented EffectIterator for simpler programmatic effect iteration
- Replaced Bash release script with more robust Python version featuring improved validation and colored output
โป๏ธ Code Improvements
- Modernized codebase with Python 3.11 type hints using union syntax (str | None) and improved collection types
- Refactored SignalRGBClient to use context manager for requests with improved error handling
- Restructured CLI commands into logical subcommands (effect, preset, layout, canvas) for better organization
- Renamed EffectNotFoundError to NotFoundError for broader use across different resource types
- Introduced explicit caching in SignalRGBClient replacing LRU cache for better control
- Created new data models for EffectPreset, EffectPresetList, Layout, and related responses
๐ง Infrastructure Changes
- Migrated from Poetry to UV for dependency management with PEP 621 compliant pyproject.toml
- Updated CI/CD workflow configuration to work with UV instead of Poetry
- Lowered Python requirement from 3.12 to 3.9 for broader compatibility
- Updated all dependencies to their latest compatible versions
๐ UI/UX Improvements
- Enhanced CLI with colorful output, icons, and improved table formatting
- Added progress bar for effect cycling operations
- Improved parameter display with better formatting for boolean and color values
- Simplified preset and layout display by removing unnecessary type information
๐ Documentation
- Updated documentation to reflect new subcommand structure in CLI
- Added sections for preset and layout management in the docs
- Revised library usage docs with new methods and error handling examples
- Updated installation instructions to reference UV instead of Poetry
โ
Testing
- Updated test cases to cover new methods and error handling scenarios
- Added tests for layout-related functionality
- Modified test assertions to align with CLI output format changes
- Converted assertions to pytest-style in tests for better diagnostics
๐ง Upgrade Notes
- The CLI command structure has changed to use subcommands. For example, `signalrgb list_effects` is now `signalrgb effect list`.
- If you were using the Python library directly and catching `EffectNotFoundError`, update your code to catch `NotFoundError` instead.
- Users who had development environments set up with Poetry should migrate to using UV for dependency management.
๐ Metrics
- Total Commits: 24
- Files Changed: 61
- Insertions: 5533
- Deletions: 2416