Compare commits

...

2 Commits

Author SHA1 Message Date
b8726d03b6 Merge branch 'main' into fix/code-review-mode-alias 2026-06-21 04:00:10 +00:00
root
5625df924f fix(modes): accept code_review as alias for codereview
External callers (lakehouse observer.ts) escalate to /api/run with mode
"code_review" (underscored), but the canonical registered mode is "codereview",
so those calls hit the unknown-mode 400 and silently dropped. Normalize the alias
right after reading the mode so it validates and dispatches via RUNNERS.

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
2026-06-20 22:47:07 -05:00

View File

@ -10780,6 +10780,11 @@ def run_team():
return jsonify({"error": "Request body required"}), 400 return jsonify({"error": "Request body required"}), 400
mode = config.get("mode", "") mode = config.get("mode", "")
# Alias: external callers (e.g. lakehouse observer.ts) escalate to the underscored
# `code_review`, but the canonical registered mode is `codereview` — normalize so
# those calls dispatch via RUNNERS instead of silently failing the 400 below.
if mode == "code_review":
mode = "codereview"
if not mode: if not mode:
return jsonify({"error": "Mode is required"}), 400 return jsonify({"error": "Mode is required"}), 400