MCPcopy Create free account
hub / github.com/BUPT-GAMMA/MASFactory / debugloop_terminate

Function debugloop_terminate

applications/mapcoder/workflows/controllers.py:101–111  ·  view source on GitHub ↗

Stop early on `full_passed`; framework caps at t iterations.

(message: dict[str, Any], attrs: dict[str, Any])

Source from the content-addressed store, hash-verified

99# ---------------------------------------------------------------------------
100
101def debugloop_terminate(message: dict[str, Any], attrs: dict[str, Any]) -> bool:
102 """Stop early on `full_passed`; framework caps at t iterations."""
103 full_passed = _bool_signal(message.get("full_passed"))
104 code = _clean(message.get("code"), default="")
105 if not isinstance(code, str):
106 code = str(code)
107
108 message["final_code"] = code
109 message["final_passed"] = full_passed
110
111 return full_passed
112
113
114# ---------------------------------------------------------------------------

Callers

nothing calls this directly

Calls 2

_bool_signalFunction · 0.85
_cleanFunction · 0.70

Tested by

no test coverage detected