7 Commits

Author SHA1 Message Date
agessaman
217d2a4089 Refactor database connection handling across multiple modules
- Replaced direct SQLite connection calls with a context manager in various modules to ensure proper resource management and prevent file descriptor leaks.
- Introduced a new `connection` method in `DBManager` to standardize connection handling.
- Updated all relevant database interactions in modules such as `feed_manager`, `scheduler`, `commands`, and others to utilize the new connection method.
- Improved code readability and maintainability by consolidating connection logic.
2026-03-01 14:12:22 -08:00
agessaman
04bd004f36 Improve monitor channel handling by adding support for quoted values
- Introduced `strip_optional_quotes` function to handle monitor channel values with optional surrounding quotes.
- Updated `load_monitor_channels` method in `CommandManager` to utilize the new function, ensuring compatibility with quoted and unquoted channel configurations.
- Modified `generate_samples` function to apply the same logic for consistency.
- Added tests for `strip_optional_quotes` to validate behavior with various input cases.
2026-02-15 21:02:48 -08:00
agessaman
d699ea1cf1 Update configuration handling and validation for bot sections
- Enhanced .gitignore to allow test files in the tests/ directory and committed pytest.ini for test discovery.
- Added checks for missing sections in configuration files, specifically for Admin_ACL and Banned_Users, to prevent errors during bot startup.
- Updated generate_website.py and command_manager.py to handle cases where required sections are absent, returning empty lists instead of raising exceptions.
- Introduced optional dependencies for testing in pyproject.toml, ensuring a smoother development experience.
- Improved localization handling in core.py to default to English when the Localization section is missing, enhancing user experience.
2026-02-12 19:23:35 -08:00
agessaman
117b687b0b feat: Add dynamic styling and sample generation for website
- Introduced multiple CSS styles for the generated website, allowing users to select their preferred theme.
- Enhanced the `generate_html` function to accept a style parameter and apply corresponding CSS variables.
- Added a `list_styles` function to display available styles and their descriptions.
- Implemented a `generate_samples` function to create sample HTML files for each style, including an index page for easy navigation.
- Updated command-line interface to support style selection and sample generation options.
2026-01-15 21:51:31 -08:00
agessaman
d2abc49048 feat: Enhance command documentation and usage information
- Updated the `generate_html` function to include detailed command usage information, including syntax, examples, and parameters for better user guidance.
- Added CSS styles for improved presentation of command usage and parameters in the generated website documentation.
- Enhanced command classes with structured documentation fields, allowing for consistent and informative command descriptions across the platform.
2026-01-15 20:04:58 -08:00
Adam Gessaman
4bd48e5165 feat: Add sub-command support and usage information retrieval for commands
- Implemented `get_usage_info` method in `BaseCommand` to provide structured usage information, including descriptions, sub-commands, usage patterns, and examples.
- Enhanced `generate_html` function to display sub-commands in the generated HTML output, improving command documentation.
- Updated translations in `en.json` to include sub-command details for various commands, enhancing user guidance and interaction.
2026-01-15 10:04:09 -08:00
agessaman
7984fa3af6 feat: Enhance command messaging with repeat tracking and transmission monitoring
- Updated `send_dm` and `send_channel_message` methods to include an optional `command_id` for tracking message repeats.
- Integrated transmission tracking to record and manage repeat messages, improving message handling and response accuracy.
- Enhanced `capture_command` method in `BotIntegration` to store repeat information for better analysis in the web viewer.
- Added favicon support and improved web viewer templates to display repeat information effectively.
- Implemented JavaScript updates in the web viewer to handle command updates and display repeat counts dynamically.
2026-01-11 20:30:02 -08:00