fix(agent-job-notification): Add notification for deactivate site job - #6245
Conversation
Physical backup site updates have separate deactivate site job
Greptile SummaryThis PR extends Confidence Score: 4/5Safe to merge with a minor UX concern; no runtime errors or data loss risk. The only finding is P2: the notification message body becomes self-referential when the failing job type is "Deactivate Site", which is confusing but does not break functionality or cause data loss. The URL anchor fixes are correct improvements. Score is 4 rather than 5 because the misleading message is a correctness-of-communication concern worth addressing before the feature ships. press/press/doctype/agent_job/agent_job_notifications.py — the update_with_rq_jobs_in_queue_err message body needs a branch for the "Deactivate Site" case. Important Files Changed
Flowchart%%{init: {'theme': 'neutral'}}%%
flowchart TD
A[Agent Job Fails] --> B{Match string found?\n'Site might have lot\nof jobs in queue.'}
B -- No --> C[Other handlers / default notification]
B -- Yes --> D{job.job_type in\nallowed list?}
D -- No --> C
D -- Yes --> E[Set title: 'High number of queued jobs']
E --> F[Set shared message body\n'please deactivate your site...']
F --> G{job.job_type ==\n'Deactivate Site'?}
G -- Yes --> H["⚠️ Message says 'deactivate site'\nbut user is already doing that"]
G -- No --> I[Notification shown\nUpdate Site Pull / Update Site Migrate]
H --> J[assistance_url = 'how-do-i-deactivate-my-site'\nalso self-referential]
|
Codecov Report❌ Patch coverage is
❌ Your patch status has failed because the patch coverage (0.00%) is below the target coverage (75.00%). You can increase the patch coverage or adjust the target coverage. Additional details and impacted files@@ Coverage Diff @@
## develop #6245 +/- ##
===========================================
+ Coverage 49.53% 56.25% +6.72%
===========================================
Files 935 935
Lines 77596 77596
Branches 353 525 +172
===========================================
+ Hits 38434 43649 +5215
+ Misses 39138 33919 -5219
- Partials 24 28 +4
Flags with carried forward coverage won't be shown. Click here to find out more. ☔ View full report in Codecov by Sentry. 🚀 New features to boost your workflow:
|
|
🎉 This PR is included in version 0.23.0 🎉 The release is available on GitHub release Your semantic-release bot 📦🚀 |
Physical backup site updates have separate deactivate site job
Also update broken doc links