# PowerLogger
A high-performance, thread-safe logging library built with Python's logging module and enhanced with the Rich library for beautiful console output with full UTF-8 support.
[](https://badge.fury.io/py/powerlogger)
[](https://pypi.org/project/powerlogger/)
[](https://opensource.org/licenses/MIT)
## โจ Features
- **๐จ Rich Console Output**: Beautiful, colored logging with the Rich library
- **๐ Thread-Safe Queue Logging**: Asynchronous, non-blocking log processing
- **๐ File Rotation**: Automatic log file rotation with size-based truncation
- **๐ UTF-8 Support**: Full Unicode and emoji support in log files
- **โ๏ธ Configuration Management**: Flexible configuration via `log_config.ini`
- **๐ช Windows Optimized**: Special handling for Windows file access issues
- **๐ง Multiple Logger Types**: Console-only, file-only, queue-based, and combined loggers
- **โก High Performance**: Optimized for real-time logging applications
- **๐ก๏ธ Production Ready**: Comprehensive error handling and recovery mechanisms
## ๐ Installation
```bash
pip install powerlogger
```
## ๐ฏ Quick Start
```python
from powerlogger import get_logger
# Create a basic logger
logger = get_logger("my_app")
# Log messages with beautiful formatting
logger.info("๐ Application started successfully!")
logger.warning("โ ๏ธ This is a warning message")
logger.error("โ An error occurred during execution")
logger.debug("๐ Debug information for developers")
```
## ๐ Automated Publishing (Windows)
PowerLogger uses GitHub Actions for automated building, testing, and publishing to PyPI on Windows:
- **๐ Auto-publish**: Creates GitHub releases automatically
- **๐ช Windows-optimized testing**: Comprehensive Windows compatibility testing
- **๐ฆ Multi-version support**: Python 3.11-3.13 compatibility on Windows
- **๐ Security scanning**: Automated vulnerability checks on Windows
- **๐ Coverage reporting**: Windows-specific code coverage metrics
- **โก Performance testing**: Windows performance and scalability testing
See [GitHub Actions Guide](GITHUB_ACTIONS.md) for detailed Windows workflow information.
## ๐ Logger Types
### Basic Logger (Console Only)
```python
from powerlogger import get_logger
logger = get_logger("app_name")
# Beautiful console output with colors and formatting
```
### File Logger with Rotation
```python
from powerlogger import get_logger_with_file_handler
logger = get_logger_with_file_handler("app_name")
# Logs to both console and file with automatic rotation
```
### Queue Logger (Thread-Safe)
```python
from powerlogger import get_logger_with_queue
logger = get_logger_with_queue("app_name")
# Asynchronous logging for high-performance applications
```
### Complete Solution (Queue + File)
```python
from powerlogger import get_logger_with_queue_and_file
logger = get_logger_with_queue_and_file("app_name")
# Best of both worlds: thread-safe + file output + rotation
```
## โ๏ธ Configuration
Create `log_config.ini` in your project root:
```ini
[app]
name = my_app
[logging]
output_mode = both
level = INFO
format = %%(levelname)s %%(name)s - %%(message)s
console_format = %%(levelname)s %%(message)s
logs_dir = logs
max_bytes = 1048576
queue_enabled = true
queue_size = 100
flush_interval = 0.1
```
### Configuration Options
| Option | Description | Default | Example |
|--------|-------------|---------|---------|
| `level` | Log level (DEBUG, INFO, WARNING, ERROR, CRITICAL) | INFO | `DEBUG` |
| `format` | Log message format for files | `%(levelname)s %(name)s - %(message)s` | `%(asctime)s - %(levelname)s - %(message)s` |
| `console_format` | Log message format for console | `%(levelname)s %(message)s` | `%(levelname)s: %(message)s` |
| `logs_dir` | Directory for log files | `logs` | `app_logs` |
| `max_bytes` | Maximum log file size before rotation | 1MB (1048576) | 5242880 (5MB) |
| `queue_enabled` | Enable thread-safe queue logging | true | false |
| `queue_size` | Maximum queue size for log records | 100 | 1000 |
| `flush_interval` | Queue flush interval in seconds | 0.1 | 0.5 |
## ๐ Log Rotation
PowerLogger automatically manages log file sizes through intelligent truncation:
- **Size-based Rotation**: Logs rotate when they reach `max_bytes`
- **Truncation Strategy**: Current log file is truncated to start fresh
- **Single File Management**: Maintains one log file instead of multiple backups
- **Windows Optimized**: Special handling for Windows file access conflicts
## ๐งต Thread Safety
The queue-based loggers provide enterprise-grade thread safety:
- **๐ Asynchronous Processing**: Log records are buffered in a thread-safe queue
- **๐ท Dedicated Worker**: Single worker thread processes all log records
- **โก Non-blocking**: Log emission never blocks your application
- **๐ Configurable**: Adjustable queue size and flush intervals
- **๐ก๏ธ Error Handling**: Robust error recovery and fallback mechanisms
## ๐ก Usage Examples
### Basic Application Logging
```python
from powerlogger import get_logger
logger = get_logger("my_application")
def main():
logger.info("๐ Starting application")
try:
# Your application logic here
logger.info("โ
Application running successfully")
logger.debug("๐ Processing user input...")
except Exception as e:
logger.error(f"โ Application error: {e}")
logger.exception("๐ Full traceback:")
logger.info("๐ Application finished")
if __name__ == "__main__":
main()
```
### Web Application with File Logging
```python
from powerlogger import get_logger_with_file_handler
import time
logger = get_logger_with_file_handler("web_app")
def handle_request(request_id):
logger.info(f"๐ฅ Processing request {request_id}")
time.sleep(0.1) # Simulate work
logger.info(f"โ
Request {request_id} completed")
# Simulate multiple requests
for i in range(100):
handle_request(i)
```
### High-Performance Multi-threaded Logging
```python
from powerlogger import get_logger_with_queue_and_file
import threading
import time
logger = get_logger_with_queue_and_file("high_perf_app")
def worker(worker_id):
for i in range(1000):
logger.info(f"๐ท Worker {worker_id}: Processing task {i}")
time.sleep(0.001) # Very fast logging
# Start multiple worker threads
threads = []
for i in range(5):
t = threading.Thread(target=worker, args=(i,))
t.start()
threads.append(t)
# Wait for completion
for t in threads:
t.join()
# Clean up resources
from powerlogger import cleanup_loggers
cleanup_loggers()
```
### UTF-8 and Emoji Support
```python
from powerlogger import get_logger_with_file_handler
logger = get_logger_with_file_handler("unicode_test")
# International characters
logger.info("Hola mundo! Bonjour le monde! Hallo Welt!")
logger.warning("Special chars: รก รฉ รญ รณ รบ รฑ รง")
# Emojis and symbols
logger.info("โ
Success! ๐ Launching... ๐ Amazing!")
logger.error("โ Error occurred ๐ฅ Boom! ๐ฅ Fire!")
# Complex Unicode
logger.info("ไธ็ ๐ 2024 ยฉ ยฎ โข")
logger.debug("Math: ยฑ ร รท โ โ โ โค โฅ")
```
## โก Performance Considerations
- **๐ Queue Size**: Smaller queues (100-1000) provide better real-time logging
- **โฑ๏ธ Flush Interval**: Lower intervals (0.1-0.5s) reduce latency but increase CPU usage
- **๐พ File Rotation**: Truncation-based rotation minimizes I/O overhead
- **๐งต Thread Count**: Single worker thread optimizes resource usage
- **๐ Memory Usage**: Efficient memory management for long-running applications
## ๐ ๏ธ Troubleshooting
### Console Colors Not Working
- **Windows**: Use Windows Terminal or enable ANSI support
- **macOS/Linux**: Ensure `TERM` environment variable is set
- **Check**: Verify your terminal supports ANSI color codes
### Log Files Not Rotating
- **File Size**: Ensure file size exceeds `max_bytes` setting
- **Permissions**: Check write permissions to the logs directory
- **Configuration**: Verify `log_config.ini` is in the correct location
### Queue Performance Issues
- **Queue Full**: Increase `queue_size` or reduce logging frequency
- **High Latency**: Decrease `flush_interval` for faster processing
- **Memory Usage**: Monitor queue size and adjust accordingly
### Windows File Access Errors
- **Built-in Protection**: PowerLogger includes special Windows handling
- **File Locks**: Ensure no other processes are accessing log files
- **Permissions**: Run with appropriate user permissions
## ๐ API Reference
### Core Functions
| Function | Description | Returns |
|----------|-------------|---------|
| `get_logger(name, level, config_file)` | Basic Rich console logger | Logger instance |
| `get_logger_with_file_handler(name, level, log_file, config_file)` | Logger with file output and rotation | Logger instance |
| `get_logger_with_queue(name, level, config_file)` | Thread-safe queue logger | Logger instance |
| `get_logger_with_queue_and_file(name, level, log_file, config_file)` | Complete solution | Logger instance |
| `cleanup_loggers()` | Clean up all loggers and handlers | None |
### Utility Functions
| Function | Description | Returns |
|----------|-------------|---------|
| `load_config(config_file)` | Load configuration from INI file | ConfigParser instance |
| `get_log_level_from_config(config)` | Get log level from config | Logging level constant |
### Classes
| Class | Description | Purpose |
|-------|-------------|---------|
| `WindowsSafeRotatingFileHandler` | Windows-optimized file rotation | Handle file rotation safely |
| `ThreadSafeQueueHandler` | Asynchronous log processing | Process logs in background |
## ๐งช Testing
Run the test suite to verify everything works:
```bash
# Install development dependencies
pip install powerlogger[dev]
# Run tests
python -m pytest tests/ -v
# Run specific test
python -m pytest tests/test_logging.py -v
```
## ๐ค Contributing
We welcome contributions! Here's how to get started:
1. **Fork** the repository
2. **Create** a feature branch (`git checkout -b feature/amazing-feature`)
3. **Make** your changes
4. **Add** tests if applicable
5. **Commit** your changes (`git commit -m 'Add amazing feature'`)
6. **Push** to the branch (`git push origin feature/amazing-feature`)
7. **Open** a Pull Request
### Development Setup
```bash
# Clone the repository
git clone https://github.com/Pandiyarajk/powerlogger.git
cd powerlogger
# Create virtual environment
python -m venv venv
source venv/bin/activate # On Windows: venv\Scripts\activate
# Install development dependencies
pip install -e ".[dev]"
# Run tests
python -m pytest tests/ -v
```
## ๐ License
This project is licensed under the MIT License - see the [LICENSE](https://github.com/Pandiyarajk/powerlogger/blob/main/LICENSE) file for details.
## ๐ Changelog
See [CHANGELOG.md](https://github.com/Pandiyarajk/powerlogger/blob/main/CHANGELOG.md) for a detailed history of changes and features.
## ๐ What's New in 1.0.0
- **๐ Production Release**: First stable release with comprehensive features
- **๐ Truncation-based Rotation**: Simplified log rotation strategy
- **โก Performance Optimizations**: Enhanced queue processing and file handling
- **๐ก๏ธ Windows Compatibility**: Improved file access handling for Windows
- **๐ Enhanced Documentation**: Comprehensive guides and examples
- **๐งช Test Coverage**: Extensive test suite for reliability
- **๐ง Configuration Management**: Flexible and robust configuration system
## ๐ Support
- **๐ง Email**: pandiyarajk@live.com
- **๐ Issues**: [GitHub Issues](https://github.com/Pandiyarajk/powerlogger/issues)
- **๐ Documentation**: [GitHub README](https://github.com/Pandiyarajk/powerlogger#readme)
- **๐ฌ Discussions**: [GitHub Discussions](https://github.com/Pandiyarajk/powerlogger/discussions)
## โญ Star History
If you find PowerLogger useful, please consider giving it a star on GitHub! โญ
---
**Made with โค๏ธ by [Pandiyaraj Karuppasamy](https://github.com/Pandiyarajk)**
*PowerLogger - Empowering your applications with beautiful, high-performance logging.*
Raw data
{
"_id": null,
"home_page": "https://github.com/Pandiyarajk/powerlogger",
"name": "powerlogger",
"maintainer": null,
"docs_url": null,
"requires_python": ">=3.11",
"maintainer_email": "Pandiyaraj Karuppasamy <pandiyarajk@live.com>",
"keywords": "logging, rich, console, unicode, file-rotation, thread-safe, windows",
"author": "Pandiyaraj Karuppasamy",
"author_email": "Pandiyaraj Karuppasamy <pandiyarajk@live.com>",
"download_url": "https://files.pythonhosted.org/packages/1f/cf/32624d95e431d99c931b1e63a179ba89eff4eb0027bbf6cc393530f1cf5c/powerlogger-0.1.0.tar.gz",
"platform": null,
"description": "# PowerLogger\r\n\r\nA high-performance, thread-safe logging library built with Python's logging module and enhanced with the Rich library for beautiful console output with full UTF-8 support.\r\n\r\n[](https://badge.fury.io/py/powerlogger)\r\n[](https://pypi.org/project/powerlogger/)\r\n[](https://opensource.org/licenses/MIT)\r\n\r\n## \u2728 Features\r\n\r\n- **\ud83c\udfa8 Rich Console Output**: Beautiful, colored logging with the Rich library\r\n- **\ud83d\udd04 Thread-Safe Queue Logging**: Asynchronous, non-blocking log processing\r\n- **\ud83d\udcc1 File Rotation**: Automatic log file rotation with size-based truncation\r\n- **\ud83c\udf0d UTF-8 Support**: Full Unicode and emoji support in log files\r\n- **\u2699\ufe0f Configuration Management**: Flexible configuration via `log_config.ini`\r\n- **\ud83e\ude9f Windows Optimized**: Special handling for Windows file access issues\r\n- **\ud83d\udd27 Multiple Logger Types**: Console-only, file-only, queue-based, and combined loggers\r\n- **\u26a1 High Performance**: Optimized for real-time logging applications\r\n- **\ud83d\udee1\ufe0f Production Ready**: Comprehensive error handling and recovery mechanisms\r\n\r\n## \ud83d\ude80 Installation\r\n\r\n```bash\r\npip install powerlogger\r\n```\r\n\r\n## \ud83c\udfaf Quick Start\r\n\r\n```python\r\nfrom powerlogger import get_logger\r\n\r\n# Create a basic logger\r\nlogger = get_logger(\"my_app\")\r\n\r\n# Log messages with beautiful formatting\r\nlogger.info(\"\ud83d\ude80 Application started successfully!\")\r\nlogger.warning(\"\u26a0\ufe0f This is a warning message\")\r\nlogger.error(\"\u274c An error occurred during execution\")\r\nlogger.debug(\"\ud83d\udd0d Debug information for developers\")\r\n```\r\n\r\n## \ud83d\ude80 Automated Publishing (Windows)\r\n\r\nPowerLogger uses GitHub Actions for automated building, testing, and publishing to PyPI on Windows:\r\n\r\n- **\ud83d\ude80 Auto-publish**: Creates GitHub releases automatically\r\n- **\ud83e\ude9f Windows-optimized testing**: Comprehensive Windows compatibility testing\r\n- **\ud83d\udce6 Multi-version support**: Python 3.11-3.13 compatibility on Windows\r\n- **\ud83d\udd12 Security scanning**: Automated vulnerability checks on Windows\r\n- **\ud83d\udcca Coverage reporting**: Windows-specific code coverage metrics\r\n- **\u26a1 Performance testing**: Windows performance and scalability testing\r\n\r\nSee [GitHub Actions Guide](GITHUB_ACTIONS.md) for detailed Windows workflow information.\r\n\r\n## \ud83d\udcda Logger Types\r\n\r\n### Basic Logger (Console Only)\r\n```python\r\nfrom powerlogger import get_logger\r\n\r\nlogger = get_logger(\"app_name\")\r\n# Beautiful console output with colors and formatting\r\n```\r\n\r\n### File Logger with Rotation\r\n```python\r\nfrom powerlogger import get_logger_with_file_handler\r\n\r\nlogger = get_logger_with_file_handler(\"app_name\")\r\n# Logs to both console and file with automatic rotation\r\n```\r\n\r\n### Queue Logger (Thread-Safe)\r\n```python\r\nfrom powerlogger import get_logger_with_queue\r\n\r\nlogger = get_logger_with_queue(\"app_name\")\r\n# Asynchronous logging for high-performance applications\r\n```\r\n\r\n### Complete Solution (Queue + File)\r\n```python\r\nfrom powerlogger import get_logger_with_queue_and_file\r\n\r\nlogger = get_logger_with_queue_and_file(\"app_name\")\r\n# Best of both worlds: thread-safe + file output + rotation\r\n```\r\n\r\n## \u2699\ufe0f Configuration\r\n\r\nCreate `log_config.ini` in your project root:\r\n\r\n```ini\r\n[app]\r\nname = my_app\r\n\r\n[logging]\r\noutput_mode = both\r\nlevel = INFO\r\nformat = %%(levelname)s %%(name)s - %%(message)s\r\nconsole_format = %%(levelname)s %%(message)s\r\nlogs_dir = logs\r\nmax_bytes = 1048576\r\nqueue_enabled = true\r\nqueue_size = 100\r\nflush_interval = 0.1\r\n```\r\n\r\n### Configuration Options\r\n\r\n| Option | Description | Default | Example |\r\n|--------|-------------|---------|---------|\r\n| `level` | Log level (DEBUG, INFO, WARNING, ERROR, CRITICAL) | INFO | `DEBUG` |\r\n| `format` | Log message format for files | `%(levelname)s %(name)s - %(message)s` | `%(asctime)s - %(levelname)s - %(message)s` |\r\n| `console_format` | Log message format for console | `%(levelname)s %(message)s` | `%(levelname)s: %(message)s` |\r\n| `logs_dir` | Directory for log files | `logs` | `app_logs` |\r\n| `max_bytes` | Maximum log file size before rotation | 1MB (1048576) | 5242880 (5MB) |\r\n| `queue_enabled` | Enable thread-safe queue logging | true | false |\r\n| `queue_size` | Maximum queue size for log records | 100 | 1000 |\r\n| `flush_interval` | Queue flush interval in seconds | 0.1 | 0.5 |\r\n\r\n## \ud83d\udd04 Log Rotation\r\n\r\nPowerLogger automatically manages log file sizes through intelligent truncation:\r\n\r\n- **Size-based Rotation**: Logs rotate when they reach `max_bytes`\r\n- **Truncation Strategy**: Current log file is truncated to start fresh\r\n- **Single File Management**: Maintains one log file instead of multiple backups\r\n- **Windows Optimized**: Special handling for Windows file access conflicts\r\n\r\n## \ud83e\uddf5 Thread Safety\r\n\r\nThe queue-based loggers provide enterprise-grade thread safety:\r\n\r\n- **\ud83d\udd04 Asynchronous Processing**: Log records are buffered in a thread-safe queue\r\n- **\ud83d\udc77 Dedicated Worker**: Single worker thread processes all log records\r\n- **\u26a1 Non-blocking**: Log emission never blocks your application\r\n- **\ud83d\udcca Configurable**: Adjustable queue size and flush intervals\r\n- **\ud83d\udee1\ufe0f Error Handling**: Robust error recovery and fallback mechanisms\r\n\r\n## \ud83d\udca1 Usage Examples\r\n\r\n### Basic Application Logging\r\n```python\r\nfrom powerlogger import get_logger\r\n\r\nlogger = get_logger(\"my_application\")\r\n\r\ndef main():\r\n logger.info(\"\ud83d\ude80 Starting application\")\r\n \r\n try:\r\n # Your application logic here\r\n logger.info(\"\u2705 Application running successfully\")\r\n logger.debug(\"\ud83d\udd0d Processing user input...\")\r\n except Exception as e:\r\n logger.error(f\"\u274c Application error: {e}\")\r\n logger.exception(\"\ud83d\udccb Full traceback:\")\r\n \r\n logger.info(\"\ud83c\udfc1 Application finished\")\r\n\r\nif __name__ == \"__main__\":\r\n main()\r\n```\r\n\r\n### Web Application with File Logging\r\n```python\r\nfrom powerlogger import get_logger_with_file_handler\r\nimport time\r\n\r\nlogger = get_logger_with_file_handler(\"web_app\")\r\n\r\ndef handle_request(request_id):\r\n logger.info(f\"\ud83d\udce5 Processing request {request_id}\")\r\n time.sleep(0.1) # Simulate work\r\n logger.info(f\"\u2705 Request {request_id} completed\")\r\n\r\n# Simulate multiple requests\r\nfor i in range(100):\r\n handle_request(i)\r\n```\r\n\r\n### High-Performance Multi-threaded Logging\r\n```python\r\nfrom powerlogger import get_logger_with_queue_and_file\r\nimport threading\r\nimport time\r\n\r\nlogger = get_logger_with_queue_and_file(\"high_perf_app\")\r\n\r\ndef worker(worker_id):\r\n for i in range(1000):\r\n logger.info(f\"\ud83d\udc77 Worker {worker_id}: Processing task {i}\")\r\n time.sleep(0.001) # Very fast logging\r\n\r\n# Start multiple worker threads\r\nthreads = []\r\nfor i in range(5):\r\n t = threading.Thread(target=worker, args=(i,))\r\n t.start()\r\n threads.append(t)\r\n\r\n# Wait for completion\r\nfor t in threads:\r\n t.join()\r\n\r\n# Clean up resources\r\nfrom powerlogger import cleanup_loggers\r\ncleanup_loggers()\r\n```\r\n\r\n### UTF-8 and Emoji Support\r\n```python\r\nfrom powerlogger import get_logger_with_file_handler\r\n\r\nlogger = get_logger_with_file_handler(\"unicode_test\")\r\n\r\n# International characters\r\nlogger.info(\"Hola mundo! Bonjour le monde! Hallo Welt!\")\r\nlogger.warning(\"Special chars: \u00e1 \u00e9 \u00ed \u00f3 \u00fa \u00f1 \u00e7\")\r\n\r\n# Emojis and symbols\r\nlogger.info(\"\u2705 Success! \ud83d\ude80 Launching... \ud83c\udf1f Amazing!\")\r\nlogger.error(\"\u274c Error occurred \ud83d\udca5 Boom! \ud83d\udd25 Fire!\")\r\n\r\n# Complex Unicode\r\nlogger.info(\"\u4e16\u754c \ud83c\udf0d 2024 \u00a9 \u00ae \u2122\")\r\nlogger.debug(\"Math: \u00b1 \u00d7 \u00f7 \u221a \u221e \u2260 \u2264 \u2265\")\r\n```\r\n\r\n## \u26a1 Performance Considerations\r\n\r\n- **\ud83d\udcca Queue Size**: Smaller queues (100-1000) provide better real-time logging\r\n- **\u23f1\ufe0f Flush Interval**: Lower intervals (0.1-0.5s) reduce latency but increase CPU usage\r\n- **\ud83d\udcbe File Rotation**: Truncation-based rotation minimizes I/O overhead\r\n- **\ud83e\uddf5 Thread Count**: Single worker thread optimizes resource usage\r\n- **\ud83d\ude80 Memory Usage**: Efficient memory management for long-running applications\r\n\r\n## \ud83d\udee0\ufe0f Troubleshooting\r\n\r\n### Console Colors Not Working\r\n- **Windows**: Use Windows Terminal or enable ANSI support\r\n- **macOS/Linux**: Ensure `TERM` environment variable is set\r\n- **Check**: Verify your terminal supports ANSI color codes\r\n\r\n### Log Files Not Rotating\r\n- **File Size**: Ensure file size exceeds `max_bytes` setting\r\n- **Permissions**: Check write permissions to the logs directory\r\n- **Configuration**: Verify `log_config.ini` is in the correct location\r\n\r\n### Queue Performance Issues\r\n- **Queue Full**: Increase `queue_size` or reduce logging frequency\r\n- **High Latency**: Decrease `flush_interval` for faster processing\r\n- **Memory Usage**: Monitor queue size and adjust accordingly\r\n\r\n### Windows File Access Errors\r\n- **Built-in Protection**: PowerLogger includes special Windows handling\r\n- **File Locks**: Ensure no other processes are accessing log files\r\n- **Permissions**: Run with appropriate user permissions\r\n\r\n## \ud83d\udcd6 API Reference\r\n\r\n### Core Functions\r\n\r\n| Function | Description | Returns |\r\n|----------|-------------|---------|\r\n| `get_logger(name, level, config_file)` | Basic Rich console logger | Logger instance |\r\n| `get_logger_with_file_handler(name, level, log_file, config_file)` | Logger with file output and rotation | Logger instance |\r\n| `get_logger_with_queue(name, level, config_file)` | Thread-safe queue logger | Logger instance |\r\n| `get_logger_with_queue_and_file(name, level, log_file, config_file)` | Complete solution | Logger instance |\r\n| `cleanup_loggers()` | Clean up all loggers and handlers | None |\r\n\r\n### Utility Functions\r\n\r\n| Function | Description | Returns |\r\n|----------|-------------|---------|\r\n| `load_config(config_file)` | Load configuration from INI file | ConfigParser instance |\r\n| `get_log_level_from_config(config)` | Get log level from config | Logging level constant |\r\n\r\n### Classes\r\n\r\n| Class | Description | Purpose |\r\n|-------|-------------|---------|\r\n| `WindowsSafeRotatingFileHandler` | Windows-optimized file rotation | Handle file rotation safely |\r\n| `ThreadSafeQueueHandler` | Asynchronous log processing | Process logs in background |\r\n\r\n## \ud83e\uddea Testing\r\n\r\nRun the test suite to verify everything works:\r\n\r\n```bash\r\n# Install development dependencies\r\npip install powerlogger[dev]\r\n\r\n# Run tests\r\npython -m pytest tests/ -v\r\n\r\n# Run specific test\r\npython -m pytest tests/test_logging.py -v\r\n```\r\n\r\n## \ud83e\udd1d Contributing\r\n\r\nWe welcome contributions! Here's how to get started:\r\n\r\n1. **Fork** the repository\r\n2. **Create** a feature branch (`git checkout -b feature/amazing-feature`)\r\n3. **Make** your changes\r\n4. **Add** tests if applicable\r\n5. **Commit** your changes (`git commit -m 'Add amazing feature'`)\r\n6. **Push** to the branch (`git push origin feature/amazing-feature`)\r\n7. **Open** a Pull Request\r\n\r\n### Development Setup\r\n\r\n```bash\r\n# Clone the repository\r\ngit clone https://github.com/Pandiyarajk/powerlogger.git\r\ncd powerlogger\r\n\r\n# Create virtual environment\r\npython -m venv venv\r\nsource venv/bin/activate # On Windows: venv\\Scripts\\activate\r\n\r\n# Install development dependencies\r\npip install -e \".[dev]\"\r\n\r\n# Run tests\r\npython -m pytest tests/ -v\r\n```\r\n\r\n## \ud83d\udcc4 License\r\n\r\nThis project is licensed under the MIT License - see the [LICENSE](https://github.com/Pandiyarajk/powerlogger/blob/main/LICENSE) file for details.\r\n\r\n## \ud83d\udccb Changelog\r\n\r\nSee [CHANGELOG.md](https://github.com/Pandiyarajk/powerlogger/blob/main/CHANGELOG.md) for a detailed history of changes and features.\r\n\r\n## \ud83c\udf1f What's New in 1.0.0\r\n\r\n- **\ud83c\udf89 Production Release**: First stable release with comprehensive features\r\n- **\ud83d\udd04 Truncation-based Rotation**: Simplified log rotation strategy\r\n- **\u26a1 Performance Optimizations**: Enhanced queue processing and file handling\r\n- **\ud83d\udee1\ufe0f Windows Compatibility**: Improved file access handling for Windows\r\n- **\ud83d\udcda Enhanced Documentation**: Comprehensive guides and examples\r\n- **\ud83e\uddea Test Coverage**: Extensive test suite for reliability\r\n- **\ud83d\udd27 Configuration Management**: Flexible and robust configuration system\r\n\r\n## \ud83d\udcde Support\r\n\r\n- **\ud83d\udce7 Email**: pandiyarajk@live.com\r\n- **\ud83d\udc1b Issues**: [GitHub Issues](https://github.com/Pandiyarajk/powerlogger/issues)\r\n- **\ud83d\udcd6 Documentation**: [GitHub README](https://github.com/Pandiyarajk/powerlogger#readme)\r\n- **\ud83d\udcac Discussions**: [GitHub Discussions](https://github.com/Pandiyarajk/powerlogger/discussions)\r\n\r\n## \u2b50 Star History\r\n\r\nIf you find PowerLogger useful, please consider giving it a star on GitHub! \u2b50\r\n\r\n---\r\n\r\n**Made with \u2764\ufe0f by [Pandiyaraj Karuppasamy](https://github.com/Pandiyarajk)**\r\n\r\n*PowerLogger - Empowering your applications with beautiful, high-performance logging.*\r\n",
"bugtrack_url": null,
"license": "MIT",
"summary": "Enhanced logging functionality with Rich console output and file rotation",
"version": "0.1.0",
"project_urls": {
"Bug Tracker": "https://github.com/Pandiyarajk/powerlogger/issues",
"Changelog": "https://github.com/Pandiyarajk/powerlogger/blob/main/CHANGELOG.md",
"Documentation": "https://github.com/Pandiyarajk/powerlogger/blob/main/README.md",
"Homepage": "https://github.com/Pandiyarajk/powerlogger",
"Repository": "https://github.com/Pandiyarajk/powerlogger"
},
"split_keywords": [
"logging",
" rich",
" console",
" unicode",
" file-rotation",
" thread-safe",
" windows"
],
"urls": [
{
"comment_text": null,
"digests": {
"blake2b_256": "eef4b6b59c54f78e0448f7de9d1fdafe60c0e33a839b9d00f8f4fe13374bc4b4",
"md5": "55eb8521d112c468727177f0e0dba3e1",
"sha256": "cfda96cca146fe347c87c961af3254f849c76660aa919833bbc2ae8003e0a520"
},
"downloads": -1,
"filename": "powerlogger-0.1.0-py3-none-any.whl",
"has_sig": false,
"md5_digest": "55eb8521d112c468727177f0e0dba3e1",
"packagetype": "bdist_wheel",
"python_version": "py3",
"requires_python": ">=3.11",
"size": 11587,
"upload_time": "2025-08-20T16:41:42",
"upload_time_iso_8601": "2025-08-20T16:41:42.400458Z",
"url": "https://files.pythonhosted.org/packages/ee/f4/b6b59c54f78e0448f7de9d1fdafe60c0e33a839b9d00f8f4fe13374bc4b4/powerlogger-0.1.0-py3-none-any.whl",
"yanked": false,
"yanked_reason": null
},
{
"comment_text": null,
"digests": {
"blake2b_256": "1fcf32624d95e431d99c931b1e63a179ba89eff4eb0027bbf6cc393530f1cf5c",
"md5": "cf819e1414300515f7c976eebf6faccf",
"sha256": "c80003b1188ee3574592cd3f1cb9d30f8b3c08bdfa62cb73942399ec3788737c"
},
"downloads": -1,
"filename": "powerlogger-0.1.0.tar.gz",
"has_sig": false,
"md5_digest": "cf819e1414300515f7c976eebf6faccf",
"packagetype": "sdist",
"python_version": "source",
"requires_python": ">=3.11",
"size": 39922,
"upload_time": "2025-08-20T16:41:44",
"upload_time_iso_8601": "2025-08-20T16:41:44.170112Z",
"url": "https://files.pythonhosted.org/packages/1f/cf/32624d95e431d99c931b1e63a179ba89eff4eb0027bbf6cc393530f1cf5c/powerlogger-0.1.0.tar.gz",
"yanked": false,
"yanked_reason": null
}
],
"upload_time": "2025-08-20 16:41:44",
"github": true,
"gitlab": false,
"bitbucket": false,
"codeberg": false,
"github_user": "Pandiyarajk",
"github_project": "powerlogger",
"travis_ci": false,
"coveralls": false,
"github_actions": true,
"requirements": [
{
"name": "rich",
"specs": [
[
">=",
"13.0.0"
]
]
},
{
"name": "build",
"specs": [
[
">=",
"0.10.0"
]
]
},
{
"name": "twine",
"specs": [
[
">=",
"4.0.0"
]
]
},
{
"name": "wheel",
"specs": [
[
">=",
"0.40.0"
]
]
},
{
"name": "setuptools",
"specs": [
[
">=",
"65.0.0"
]
]
},
{
"name": "pytest",
"specs": [
[
">=",
"7.0.0"
]
]
},
{
"name": "pytest-cov",
"specs": [
[
">=",
"4.0.0"
]
]
},
{
"name": "black",
"specs": [
[
">=",
"23.0.0"
]
]
},
{
"name": "flake8",
"specs": [
[
">=",
"6.0.0"
]
]
},
{
"name": "isort",
"specs": [
[
">=",
"5.12.0"
]
]
},
{
"name": "mypy",
"specs": [
[
">=",
"1.0.0"
]
]
},
{
"name": "safety",
"specs": [
[
">=",
"2.3.0"
]
]
},
{
"name": "bandit",
"specs": [
[
">=",
"1.7.0"
]
]
},
{
"name": "pytest-benchmark",
"specs": [
[
">=",
"4.0.0"
]
]
}
],
"lcname": "powerlogger"
}