[NEEDS CODE REVIEWER] (time-out related) Fix detect_deletions disable gating and harden timeout handling - #333
Conversation
|
Can we please get this merged? Would like to use V2 but this timeout issue is preventing me from connecting to my qbittorrent instance |
|
hi @tomerh2001 , I am truly sorry I haven't looked into your PR in such a long time. I do appreciate very much that you took the time to contribute. Unfortunately, I don't have the time to look into it still. Would you be willing to act as a formal contributor? If yes, I will add you, and if I find others (from open PRs), hopefully you can review each others PR and they can be merged. Thanks for letting me know, and apologies again for my radio silence. Would love to have you on board! |
|
Hey @tomerh2001, thank you for contributing! I am currently reviewing this as part of clearing the open PR backlog with @ManiMatter. Read through against the linked issues — code looks solid, two small asks before I'd approve. Linkage confirmed:
Ask 1 — auto-close keywords: Heads-up — overlap with #346: Code-wise: error boundaries are scoped tightly (per ARR group, per download-client job, per qbit cookie refresh), |
Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
833f10d to
2e39485
Compare
|
Hi all, I've been testing this PR extensively and would like to help get it over the line. @lolimmlost, you mentioned in April that you were reviewing this as part of the backlog. Are you still planning to take it? Happy to coordinate either way. @tomerh2001, thanks for the fix. I force-updated your branch to bring it up to date (details below). Your authorship and logic are unchanged. If you'd rather drive the PR yourself, just let me know. What I changed on the branch:
Testing:
If anyone following this thread wants to verify the fix before merge, I've published a multi-arch image of this branch at One scope note: the startup reachability check still exits on timeout by design. The current mitigation is configuring |
lolimmlost
left a comment
There was a problem hiding this comment.
Approved. The code looked solid when I reviewed it in April and the two asks were minor (auto-close keywords in the PR body, and coordinating merge order with #346 for the request_timeout overlap).
@jrhager84 — thanks for picking this up and doing the legwork: rebasing, formatting, reproducing the bug, publishing a test image. That kind of thorough validation is exactly what this PR needed to get over the line. Welcome aboard.
One note: the PR body still doesn't have the auto-close keywords. If someone can update it to include Closes #329 and Fixes #317, the issues will close automatically on merge.
Good call. |
|
Merged. Thanks for the review and the welcome, @lolimmlost. On the #346 overlap: agreed this was the right one to land first, since it closes both #317 and #329. @eadgbear, this is now in dev, so #346 will need a rebase. The general.request_timeout setting it adds is already here now, so the rebase is mostly dropping that duplicate and keeping your per-instance timeout: override on top of it. Happy to help with the rebase or handle it directly on the branch if you're swamped, just let me know. |
Summary
detect_deletionsgating so disabled jobs do not start folder watchers (main.pynow checks.enabled).JobParams.__bool__so object truthiness consistently reflects job enabled state.general.request_timeout(and envREQUEST_TIMEOUT) instead of a hardcoded 15s timeout inmake_request.request_timeoutand add regression tests.Why
detect_deletionswas starting folder watchers even when disabled;main.pynow checks.enabled.request_timeout(envREQUEST_TIMEOUT) and adds per-group error boundaries so one request failure no longer terminates the full run loop.Validation
python3 -m pytest -qpython3 -m pylint main.py src/job_manager.py src/utils/common.py src/settings/_general.py src/settings/_jobs.py src/settings/_user_config.py tests/jobs/test_job_manager.py tests/settings/test_general.py tests/settings/test_jobs.py tests/utils/test_common.py