Releases: openpolis/django-eztaskmanager
Release v0.5.1 - Task Deduplication Fix
🐛 Bug Fixes
Critical: Fix duplicate task scheduling issue
Resolves a critical issue where tasks could be scheduled multiple times in Redis Queue, leading to duplicate executions. This occurred after stack restarts, CI/CD deployments, or manual task re-activation.
What's Fixed
- Deduplication Logic: RQTaskQueueService now checks for existing scheduled jobs before creating new ones
- Automatic Cleanup: Old scheduled jobs are automatically cancelled before creating new schedules
- Graceful Error Handling: Properly handles orphaned job IDs (jobs that no longer exist in Redis)
- Comprehensive Logging: Added warning/info/debug messages for tracking deduplication events
🧪 Testing
Added 6 comprehensive test cases covering all deduplication scenarios:
- Normal scheduling without existing jobs
- Cancellation of existing valid jobs
- Graceful handling of orphaned jobs
- Periodic task deduplication
- Multiple rapid re-scheduling attempts
- Immediate execution with orphaned job cleanup
All 80 tests pass (74 existing + 6 new)
📚 Documentation
- README.md: Added Development and Testing section with instructions for running tests
- CLAUDE.md: Added comprehensive documentation for AI assistant context
🔧 Technical Details
The deduplication logic prevents the following scenario:
- Task scheduled with job_id "abc123"
- Stack restarts or task is re-activated
- New job_id "xyz789" created
- ❌ Old job "abc123" remains in Redis → duplicate execution
Now properly handled with automatic cancellation of old jobs before creating new ones.
📦 Installation
pip install --upgrade django-eztaskmanager🙏 Credits
This release includes contributions from Claude Code for deduplication logic implementation and comprehensive test coverage.
Packages versions upgraded
The packages versions in pyproject.toml have been updated.
The package supports rq v2 and django-rq v3, that introduce backward incompatibilities.
Please use version 0.4.3 in order to use a release of rq prior to 2.0.
v0.4.3
Full Changelog: v0.4.2...v0.4.3
v0.4.2
Full Changelog: v0.4.1...v0.4.2
v0.4.1
Full Changelog: v0.4.0...v0.4.1
v0.4.0
Import simplified.
Full Changelog: v0.3.8...v0.4.0
v0.3.8
Italian translations added.
Full Changelog: v0.3.7...v0.3.8
v0.3.7
Conditional import added for rq and celery.
Documentation improvements.
Full Changelog: v0.3.1...v0.3.7
v0.3.1
Full Changelog: v0.2.0...v0.3.1
Fixing release workflow
github actions in release.yml fixed to main.