Skip to content

Commit f68a40d

Browse files
committed
mypy
1 parent 34446c5 commit f68a40d

File tree

1 file changed

+4
-1
lines changed

1 file changed

+4
-1
lines changed

services/autoscaling/src/simcore_service_autoscaling/modules/cluster_scaling/_utils_computational.py

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3,8 +3,10 @@
33

44
from aws_library.ec2 import Resources
55
from dask_task_models_library.resource_constraints import (
6+
DASK_WORKER_THREAD_RESOURCE_NAME,
67
get_ec2_instance_type_from_resources,
78
)
9+
from pydantic import ByteSize
810

911
from ...models import DaskTask
1012

@@ -17,7 +19,8 @@
1719
def resources_from_dask_task(task: DaskTask) -> Resources:
1820
return Resources(
1921
cpus=task.required_resources.get("CPU", _DEFAULT_MAX_CPU),
20-
ram=task.required_resources.get("RAM", _DEFAULT_MAX_RAM),
22+
ram=ByteSize(task.required_resources.get("RAM", _DEFAULT_MAX_RAM)),
23+
generic_resources={DASK_WORKER_THREAD_RESOURCE_NAME: 1},
2124
)
2225

2326

0 commit comments

Comments
 (0)