fix(research): normalize Compose memory limits before checking RSS

This commit is contained in:
2026-11-20 17:38:58 +03:00
parent e11ee51e90
commit 7282aa8b18
4 changed files with 14315 additions and 1 deletions
File diff suppressed because it is too large Load Diff
File diff suppressed because it is too large Load Diff
@@ -0,0 +1,10 @@
Traceback (most recent call last):
File "<frozen runpy>", line 203, in _run_module_as_main
File "<frozen runpy>", line 88, in _run_code
File "<repository>/scripts/research_slo.py", line 631, in <module>
main()
~~~~^^
File "<repository>/scripts/research_slo.py", line 479, in main
max(s["signals"]["collector_memory"] for s in points)
< report["container_limits"]["otel"]["mem_limit"]
TypeError: '<' not supported between instances of 'float' and 'str'
+3 -1
View File
@@ -224,7 +224,9 @@ def main():
config = json.loads(compose("config", "--format", "json"))
report["container_limits"] = {
name: {
k: service[k]
k: int(service[k])
if k in {"mem_limit", "memswap_limit", "scale"}
else service[k]
for k in ["cpus", "mem_limit", "memswap_limit", "scale"]
if k in service
}