Skip to content

Commit 5899c4c

Browse files
abrichrclaude
andauthored
fix: skip verify_apps, close_all, activate_window in lightweight mode (#177)
These setup entry types hang (120s timeout), crash the WAA server, or are unnecessary for task execution. In lightweight mode (the default), they are now skipped entirely — both the verify_apps step injected from related_apps and any close_all / activate_window entries in the task config array. Each skipped entry is recorded with status "skipped" in _last_setup_results for auditability. Co-authored-by: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
1 parent f5ad884 commit 5899c4c

1 file changed

Lines changed: 14 additions & 1 deletion

File tree

  • openadapt_evals/adapters/waa

openadapt_evals/adapters/waa/live.py

Lines changed: 14 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1928,7 +1928,7 @@ def _run_task_setup(self, raw_config: dict) -> None:
19281928
self._last_setup_results = []
19291929

19301930
related_apps = raw_config.get("related_apps", [])
1931-
if related_apps:
1931+
if related_apps and not self.config.lightweight:
19321932
verify_step = {
19331933
"type": "verify_apps",
19341934
"parameters": {"apps": related_apps},
@@ -1944,6 +1944,19 @@ def _run_task_setup(self, raw_config: dict) -> None:
19441944
for entry in config:
19451945
entry_type = entry.get("type", "unknown")
19461946

1947+
# In lightweight mode, skip non-critical setup entries that are
1948+
# known to hang or crash the WAA server.
1949+
if self.config.lightweight and entry_type in (
1950+
"verify_apps",
1951+
"close_all",
1952+
"activate_window",
1953+
):
1954+
logger.debug("Lightweight mode: skipping %s", entry_type)
1955+
self._last_setup_results.append(
1956+
{"type": entry_type, "status": "skipped"}
1957+
)
1958+
continue
1959+
19471960
# Sleep is handled locally, not on the server
19481961
if entry_type == "sleep":
19491962
duration = entry.get("parameters", {}).get("seconds", 1)

0 commit comments

Comments
 (0)