A collection of practical Python automation scripts with tests and CI — built for real-world tasks like data processing, API monitoring, and log analysis.
| Script | What it does | No external deps |
|---|---|---|
csv_processor.py |
Validate, summarize, and report on any CSV file | ✅ |
api_health_check.py |
Ping HTTP endpoints and produce a health report | ✅ |
log_analyzer.py |
Scan log files for ERROR/WARNING patterns | ✅ |
All scripts use only the Python standard library — no pip installs needed to run them.
git clone https://github.com/MadursJohn/Freelance_Portfolio.git
cd Freelance_Portfolio/python-automation-scripts
cd python-automation-scripts
# Run any script directly — no install required
python scripts/csv_processor.py data.csv
python scripts/log_analyzer.py app.log --level ERROR
python scripts/api_health_check.py endpoints.jsonpython scripts/csv_processor.py my_data.csv --format markdown
python scripts/csv_processor.py my_data.csv --format json --output report.jsonOutput example:
# CSV Report
**Total rows:** 1500
**Columns:** id, name, revenue, region
## Column Statistics
### `revenue`
- Min / Mean / Max: 0.5 / 4823.1 / 98000.0
Create an endpoints.json:
[
{"name": "Main API", "url": "https://api.example.com/health"},
{"name": "Auth Service","url": "https://auth.example.com/ping"}
]Then run:
python scripts/api_health_check.py endpoints.json --timeout 5Returns exit code 0 if all healthy, 1 if any endpoint is down — perfect for CI gates.
python scripts/log_analyzer.py /var/log/app.log --level ERROR --format markdown
python scripts/log_analyzer.py app.log --tail 500 # last 500 lines onlypip install -r requirements-dev.txt
pytest tests/ -v --cov=scriptspython-automation-scripts/
├── scripts/
│ ├── csv_processor.py # CSV validation & reporting
│ ├── api_health_check.py # HTTP endpoint monitoring
│ └── log_analyzer.py # Log scanning & analysis
├── tests/
│ ├── test_csv_processor.py
│ └── test_log_analyzer.py
├── .github/workflows/ci.yml
└── requirements-dev.txt
These automate three of the most common recurring tasks in any software team:
- CSV/data ingestion validation — catch format issues before they reach production
- Health monitoring — lightweight alternative to heavy monitoring suites for small projects
- Log triage — quickly surface critical errors from noisy log files after a deployment
Each script outputs both Markdown (for reports/wikis) and JSON (for pipeline integration).
MIT