diff --git a/codex-launcher_3.10.9_all.deb b/codex-launcher_3.10.9_all.deb index 0687184..530e047 100644 Binary files a/codex-launcher_3.10.9_all.deb and b/codex-launcher_3.10.9_all.deb differ diff --git a/src/translate-proxy.py b/src/translate-proxy.py index 0eaf6e2..19d6c44 100755 --- a/src/translate-proxy.py +++ b/src/translate-proxy.py @@ -4385,19 +4385,19 @@ def _antigravity_normalize_context(input_data): if msg_item is not input_data[latest_user_idx]: result.append(msg_item) - latest_hash = hashlib.sha256(" ".join(latest_user.strip().split()).encode()).hexdigest() + latest_norm = " ".join(latest_user.strip().split())[:200].lower() already_present = False for r in result: if isinstance(r, dict) and r.get("type") == "message" and r.get("role") == "user": c = r.get("content", "") if isinstance(c, str): - rh = hashlib.sha256(" ".join(c.strip().split()).encode()).hexdigest() + rn = " ".join(c.strip().split())[:200].lower() elif isinstance(c, list): combined = " ".join(p.get("text", p.get("input_text", "")) for p in c if isinstance(p, dict)) - rh = hashlib.sha256(" ".join(combined.strip().split()).encode()).hexdigest() + rn = " ".join(combined.strip().split())[:200].lower() else: - rh = "" - if rh == latest_hash: + rn = "" + if rn == latest_norm: already_present = True break diff --git a/translate-proxy.py b/translate-proxy.py index 0eaf6e2..19d6c44 100755 --- a/translate-proxy.py +++ b/translate-proxy.py @@ -4385,19 +4385,19 @@ def _antigravity_normalize_context(input_data): if msg_item is not input_data[latest_user_idx]: result.append(msg_item) - latest_hash = hashlib.sha256(" ".join(latest_user.strip().split()).encode()).hexdigest() + latest_norm = " ".join(latest_user.strip().split())[:200].lower() already_present = False for r in result: if isinstance(r, dict) and r.get("type") == "message" and r.get("role") == "user": c = r.get("content", "") if isinstance(c, str): - rh = hashlib.sha256(" ".join(c.strip().split()).encode()).hexdigest() + rn = " ".join(c.strip().split())[:200].lower() elif isinstance(c, list): combined = " ".join(p.get("text", p.get("input_text", "")) for p in c if isinstance(p, dict)) - rh = hashlib.sha256(" ".join(combined.strip().split()).encode()).hexdigest() + rn = " ".join(combined.strip().split())[:200].lower() else: - rh = "" - if rh == latest_hash: + rn = "" + if rn == latest_norm: already_present = True break