v1.0.2 Python 3.7+ MIT License

🧙‍♂️ PyWizardry Magical Python Utilities

A comprehensive collection of 150+ production-ready utilities covering file operations, string manipulation, security, networking, async programming, data processing, and much more. Transform your Python development experience.

150+ Utility Functions
15 Modules
0 Required Dependencies
95%+ Test Coverage
example.py
import pywizardry as pw

# Initialize the wizard
wiz = pw.Wizard()

# File Magic 🪄
files = wiz.files.find("*.py", recursive=True)
metadata = wiz.files.metadata("data.txt")

# String Sorcery 🔤
slug = wiz.strings.slugify("My Awesome Title!")
password = wiz.strings.password(length=16)

# Security Spells 🔒
hashed = wiz.security.hash("secret", algorithm="sha256")
encrypted = wiz.security.aes_encrypt("data", "password")

# Time Wizardry ⏰
relative = wiz.dates.humanize("2024-01-20")
duration = wiz.dates.format_duration(3661)  # "1 hour 1 minute 1 second"

# Async Magic ⚡
import asyncio
async def main():
    data = await wiz.async_utils.fetch_json("https://api.example.com")
    print(data)

# One-liner spells ✨
token = pw.utils.generate_uuid()
hashed = pw.quick.hash("password")

✨ Powerful Features

Everything you need for modern Python development

File System Magic

Safe file operations, recursive directory traversal, metadata extraction, atomic writes, backup utilities, and file watching.

  • Safe atomic file writes
  • Recursive file finding
  • File metadata extraction
  • Backup and restore

String Sorcery

Advanced string manipulation, validation, password generation, slugification, text extraction, and pattern matching.

  • Smart string truncation
  • Password generation
  • Email/URL extraction
  • Text similarity

Security Spells

AES/RSA encryption, JWT tokens, password hashing, input sanitization, CSRF protection, and security validation.

  • AES-256 encryption
  • JWT token handling
  • Password strength
  • Input sanitization

Network Enchantments

HTTP client with retries, WebSocket support, rate limiting, file downloads, DNS resolution, and connection utilities.

  • Async HTTP client
  • File download with progress
  • Rate limiting
  • Port scanning

Data Alchemy

Data transformation, CSV/JSON processing, statistics calculation, outlier detection, normalization, and batch processing.

  • Data chunking
  • Statistical analysis
  • CSV/JSON utilities
  • Data normalization

Async Magic

Async/await utilities, timeout handling, parallel processing, task queues, rate limiting, and event-driven patterns.

  • Async decorators
  • Timeout handling
  • Parallel processing
  • Rate limiting

🚀 Quick Installation

Get started in seconds with PyPI

Terminal
pip install PyWizardry

Install only the core library with zero required dependencies.

Terminal
pip install PyWizardry[full]

Install with all optional dependencies (Pillow, psutil, aiohttp).

Terminal
git clone https://github.com/saifullah10141/pywizardry.git cd pywizardry pip install -e .[dev]

Install for development with testing and documentation tools.

📦 Complete Module Reference

15 modules covering all aspects of development

Ready to Transform Your Python Code?

Join thousands of developers who have enhanced their productivity with PyWizardry.