docs: update for v1.2.1 performance changes

- USAGE.md: alert output format, background seeding, per-backend errors,
  concurrent fetches
- CHEATSHEET.md: updated alert section
- DEBUG.md: added profiling section (cProfile + tracemalloc)
- ROADMAP.md: added v1.2.1 milestone

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
This commit is contained in:
user
2026-02-17 18:09:53 +01:00
parent a2a607baa2
commit e11994f320
4 changed files with 66 additions and 12 deletions

View File

@@ -97,6 +97,41 @@ ERROR derp.plugin failed to load plugin: plugins/broken.py
- In container: resolver is typically `127.0.0.11` (Podman DNS)
- Fallback: `8.8.8.8` if no resolver found in `/etc/resolv.conf`
## Profiling
### CPU (cProfile)
```bash
derp --cprofile # Dump to derp.prof on shutdown
derp --cprofile /app/data/derp.prof # Custom path
```
Analyze with:
```python
import pstats
p = pstats.Stats("data/derp.prof")
p.sort_stats("tottime").print_stats(30)
p.sort_stats("cumulative").print_stats("plugins/", 20)
```
### Memory (tracemalloc)
```bash
derp --tracemalloc # 10 frames (default)
derp --tracemalloc 25 # 25 frames deep
```
Writes top 25 allocations with full tracebacks to `data/derp.malloc`
on clean shutdown. Both flags can be combined:
```bash
derp --verbose --cprofile /app/data/derp.prof --tracemalloc
```
Requires clean SIGTERM shutdown (not SIGKILL) to flush data.
Use `podman stop -t 30 derp` to allow graceful shutdown.
## Testing IRC Connection
```bash