1
0
mirror of https://github.com/dkmstr/openuds.git synced 2025-01-18 06:03:54 +03:00

Fixed Metapool comparision (fixes #106)

This commit is contained in:
Adolfo Gómez García 2023-12-22 04:35:31 +01:00
parent 2f6132ec56
commit 78a70368b7
No known key found for this signature in database
GPG Key ID: DD1ABF20724CDA23

View File

@ -1003,10 +1003,10 @@ class UserServiceManager(metaclass=singleton.Singleton):
# Remove "full" pools (100%) from result and pools in maintenance mode, not ready pools, etc...
sortedPools = sorted(sortPools, key=lambda x: x[0])
pools: typing.List[ServicePool] = [
p[1] for p in sortedPools if p[1].usage() < 100 and p[1].isUsable()
p[1] for p in sortedPools if p[1].usage()[0] < 100 and p[1].isUsable()
]
poolsFull: typing.List[ServicePool] = [
p[1] for p in sortedPools if p[1].usage() == 100 and p[1].isUsable()
p[1] for p in sortedPools if p[1].usage()[0] == 100 and p[1].isUsable()
]
logger.debug('Pools: %s/%s', pools, poolsFull)