From 22c0a2ba61ee4b0d6fd9cd0cb0b5733a3e5a4bfa Mon Sep 17 00:00:00 2001 From: Dom Date: Wed, 6 May 2026 20:31:31 +0200 Subject: [PATCH] =?UTF-8?q?revert:=20d=C3=A9sactiver=20self-healing=20Win+?= =?UTF-8?q?D=20auto=20(cercle=20vicieux)?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Revert effectif du commit c969f93a2. Le Win+D auto au retry 1 produit un cercle vicieux quand combiné avec le VLM-first qui hallucine systématiquement (positions répétitives type 0.529/0.874 avec confidence 0.93 sans justification) : click rate (cible mal localisée par VLM) → no_screen_change → Win+D auto → minimise Easily Assure → retry click → cible plus visible (Easily masquée par Win+D) → no_screen_change → Win+D encore → boucle infernale Reproduit ce 2026-05-06 sur le workflow Urgence : 10 Win+D dispatchés en moins de 2 minutes. Régression majeure ressentie par Dom : "clic partout au pif, aucune action contrôlée". L'idée du self-healing par gesture reste valide mais demande : 1. un déclenchement plus sélectif (genre overlay/popup détecté visuellement, pas no_screen_change générique) 2. ou un Alt+Tab plutôt que Win+D (fait passer la fenêtre arrière sans minimiser l'app cible) 3. ou une vraie analyse "y a-t-il une fenêtre qui obstrue ma cible" avant de décider du gesture À retravailler post-démo avec un vrai détecteur d'obstruction. --- agent_v0/server_v1/replay_engine.py | 34 +++++------------------------ 1 file changed, 5 insertions(+), 29 deletions(-) diff --git a/agent_v0/server_v1/replay_engine.py b/agent_v0/server_v1/replay_engine.py index 47a5be132..583ae3078 100644 --- a/agent_v0/server_v1/replay_engine.py +++ b/agent_v0/server_v1/replay_engine.py @@ -1432,38 +1432,14 @@ def _schedule_retry( # Stratégie de retry selon le numéro actions_to_insert = [] - if next_retry == 1 and reason in ("verification_failed", "no_screen_change"): - # Auto-recovery par gesture : tenter Win+D ("Afficher le bureau") - # avant le 1er retry quand l'action n'a rien changé à l'écran. - # Hypothèse : une fenêtre/popup non bloquante obstrue la cible. - # Cf. gesture_catalog.win_minimize_all (agent_chat/gesture_catalog.py:84) - # et audit project-quality-guardian Cas #2 — self-healing par gesture - # archivé le 24/04 dans _archive/dead_code_20260424/, reconnecté ici - # côté serveur dans le pipeline de retry plutôt que dans la cascade - # ORALoop (qui n'est plus sur le chemin actif du replay). - actions_to_insert.append({ - "action_id": f"recovery_win_d_{uuid.uuid4().hex[:6]}", - "type": "key_combo", - "keys": ["super", "d"], - "_recovery_gesture": "win_minimize_all", - }) - # Petit wait après Win+D pour laisser l'OS terminer l'animation - actions_to_insert.append({ - "action_id": f"wait_recovery_{uuid.uuid4().hex[:6]}", - "type": "wait", - "duration_ms": 500, - }) - logger.info( - "Auto-recovery : injection Win+D avant retry %d/%d (raison: %s)", - next_retry, max_retries, reason, - ) - elif next_retry == 2: - # Retry 2 : injecter un wait de 2s avant l'action (loading possible) - actions_to_insert.append({ + if next_retry == 2: + # Retry 2 : injecter un wait de 2s avant l'action + wait_action = { "action_id": f"wait_retry_{uuid.uuid4().hex[:6]}", "type": "wait", "duration_ms": 2000, - }) + } + actions_to_insert.append(wait_action) actions_to_insert.append(retry_action)