mirror of
https://github.com/StuffAnThings/qbit_manage.git
synced 2025-12-10 13:56:13 +08:00
fix(share_limits): set limits when throttle skipped
When upload_speed_on_limit_reached is 0, the logic returned early without applying the configured share limits. This ensures limits are applied even if throttling is not configured.
This commit is contained in:
parent
e214ef0b97
commit
861fe622a3
2 changed files with 8 additions and 2 deletions
2
VERSION
2
VERSION
|
|
@ -1 +1 @@
|
|||
4.6.5-develop5
|
||||
4.6.5-develop6
|
||||
|
|
|
|||
|
|
@ -305,7 +305,7 @@ class ShareLimits:
|
|||
tracker=tracker["url"],
|
||||
reset_upload_speed_on_unmet_minimums=group_config["reset_upload_speed_on_unmet_minimums"],
|
||||
)
|
||||
|
||||
logger.trace(f"tor_reached_seed_limit: {tor_reached_seed_limit}")
|
||||
# Update share limits tag if needed
|
||||
self.update_share_limits_tag_for_torrent(torrent)
|
||||
|
||||
|
|
@ -376,6 +376,12 @@ class ShareLimits:
|
|||
# Skip if throttle not configured (0 means not set)
|
||||
if throttle_kib == 0:
|
||||
logger.debug(f"Skipping throttle for {torrent.name}: upload_speed_on_limit_reached not configured")
|
||||
self.set_limits(
|
||||
torrent=torrent,
|
||||
max_ratio=group_config["max_ratio"],
|
||||
max_seeding_time=group_config["max_seeding_time"],
|
||||
limit_upload_speed=group_config["limit_upload_speed"],
|
||||
)
|
||||
return
|
||||
|
||||
# Validate throttle value (must be -1 for unlimited or positive)
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue