mirror of
https://github.com/9001/copyparty.git
synced 2025-08-18 09:22:31 -06:00
improve scheduling
This commit is contained in:
parent
357e7333cc
commit
2170ee8da4
12
bin/up2k.py
12
bin/up2k.py
|
@ -3,7 +3,7 @@ from __future__ import print_function, unicode_literals
|
||||||
|
|
||||||
"""
|
"""
|
||||||
up2k.py: upload to copyparty
|
up2k.py: upload to copyparty
|
||||||
2022-10-30, v0.20, ed <irc.rizon.net>, MIT-Licensed
|
2022-11-04, v0.21, ed <irc.rizon.net>, MIT-Licensed
|
||||||
https://github.com/9001/copyparty/blob/hovudstraum/bin/up2k.py
|
https://github.com/9001/copyparty/blob/hovudstraum/bin/up2k.py
|
||||||
|
|
||||||
- dependencies: requests
|
- dependencies: requests
|
||||||
|
@ -782,16 +782,18 @@ class Ctl(object):
|
||||||
while True:
|
while True:
|
||||||
with self.mutex:
|
with self.mutex:
|
||||||
if (
|
if (
|
||||||
self.hash_b - self.up_b < 1024 * 1024 * 128
|
self.hash_f - self.up_f == 1
|
||||||
and self.hash_c - self.up_c < 64
|
or (
|
||||||
and (
|
self.hash_b - self.up_b < 1024 * 1024 * 1024
|
||||||
|
and self.hash_c - self.up_c < 512
|
||||||
|
)
|
||||||
|
) and (
|
||||||
not self.ar.nh
|
not self.ar.nh
|
||||||
or (
|
or (
|
||||||
self.q_upload.empty()
|
self.q_upload.empty()
|
||||||
and self.q_handshake.empty()
|
and self.q_handshake.empty()
|
||||||
and not self.uploader_busy
|
and not self.uploader_busy
|
||||||
)
|
)
|
||||||
)
|
|
||||||
):
|
):
|
||||||
break
|
break
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue