feat: prepare 2.2.0 with UI and execution fixes
Add dark theme, richer Markdown and readable plugin results. Improve Android input evidence, response integrity and diagnostics. Unify lifecycle, guidance receipts and evidence sources across clients. Keep direct action dispatch without an added AI quota approval layer. Align version metadata at 2.2.0 and bundle Helper 1.2.2. Validation: 3063 backend tests before the version bump; 44 after. Frontend: 317 tests and production build passed.
This commit is contained in:
1 parent
83bcfd54d5
commit
fac4ccb760
146 files changed
+5689
-2033
No files matched your search
@@ -34,6 +34,7 @@ from artemis.runtime import (
|
||||
trace_store,
|
||||
)
|
||||
from artemis.runtime.process_probe import pid_is_alive
|
||||
from artemis.runtime.task_progress import progress_snapshot
|
||||
from artemis.runtime.task_control import (
|
||||
add_instruction,
|
||||
control_dir,
|
||||
@@ -427,6 +428,18 @@ def mobile_manage_task(
|
||||
"stdout_log": os.path.join(trace_dir, "stdout.log"),
|
||||
"stderr_log": os.path.join(trace_dir, "stderr.log"),
|
||||
}
|
||||
lifecycle_db = _find_data_engine_db()
|
||||
if lifecycle_db:
|
||||
from apps.admin_console.services.task_lifecycle import task_lifecycle
|
||||
|
||||
try:
|
||||
response["lifecycle"] = task_lifecycle(trace_id, db_path=lifecycle_db)
|
||||
except (sqlite3.Error, OSError, ValueError) as exc:
|
||||
logger.warning("Could not read lifecycle for %s: %s", trace_id, exc)
|
||||
if "lifecycle" not in response:
|
||||
response["lifecycle"] = progress_snapshot(
|
||||
session={**status_data, "status": current_status}, control=read_state(trace_id)
|
||||
)
|
||||
# Which UI-hierarchy source served the run ("helper" or "uiautomator"),
|
||||
# plus any mid-run switch; written by the agent once the device connects.
|
||||
if status_data.get("hierarchy_backend"):
|
||||
@@ -599,7 +612,10 @@ def mobile_manage_task(
|
||||
return response
|
||||
|
||||
elif action == "guidance_history":
|
||||
return {"trace_id": trace_id, "instructions": list_instructions(trace_id)}
|
||||
return {
|
||||
"trace_id": trace_id,
|
||||
"instructions": list_instructions(trace_id, task_status=current_status),
|
||||
}
|
||||
|
||||
elif action == "pause":
|
||||
if current_status == "pausing":
|
||||
@@ -748,7 +764,13 @@ def mobile_manage_task(
|
||||
}
|
||||
|
||||
try:
|
||||
add_instruction(trace_id, instruction, release_loop=release_loop, source="mcp")
|
||||
guidance = add_instruction(
|
||||
trace_id,
|
||||
instruction,
|
||||
release_loop=release_loop,
|
||||
source="mcp",
|
||||
instruction_id=request_id,
|
||||
)
|
||||
if (
|
||||
current_status == "task_paused"
|
||||
or (control_dir(trace_id) / "pause.request").exists()
|
||||
@@ -758,7 +780,11 @@ def mobile_manage_task(
|
||||
return {
|
||||
"trace_id": trace_id,
|
||||
"status": current_status,
|
||||
"message": f"Guidance accepted and current model step interrupted{suffix}; check guidance_history for consumption.",
|
||||
"guidance": {
|
||||
**guidance,
|
||||
"status": "consumed" if guidance.get("consumed_at") else "pending",
|
||||
},
|
||||
"message": f"Guidance accepted for the next safe checkpoint{suffix}; consumption before task completion is not guaranteed. Check guidance_history.",
|
||||
}
|
||||
except Exception as e:
|
||||
return {
|
||||
|
||||
Reference in new issue
Block a user