格式化 AGC Agent 既有代码

修正 generation 与 runtime_state 两个文件的 rustfmt 布局,使工作区格式门禁可通过。
This commit is contained in:
2026-09-02 14:27:08 +08:00
parent 2e15289264
commit 529a1a0a77
2 changed files with 13 additions and 14 deletions
@@ -24,8 +24,7 @@ pub(crate) use canvas_generation::{
ExternalGenerationInitialResponse,
};
pub(in crate::agent) use canvas_generation::{
commit_prepared_platform_art_asset_at,
commit_prepared_platform_art_asset_strict_slices_at,
commit_prepared_platform_art_asset_at, commit_prepared_platform_art_asset_strict_slices_at,
generate_platform_art_asset_with_retained_runtime_options_at,
generate_platform_art_asset_with_runtime_options_at,
platform_art_generation_error_result_unknown, register_existing_platform_art_slices_at,
@@ -3343,18 +3343,18 @@ fn append_unique_game_creator_agent_runtime_task_with_initial_state(
// strict/legacy profiles preserves their existing recovery behavior.
if !autonomous_relaxed_run_profile(&record.run_profile) {
if let Err(error) = ensure_autonomous_completion_contract_for_task_at(root, &record) {
let public_error = redact_agent_runtime_project_paths(root, &error, 500);
let failed = AgentRuntimeTaskRecord {
status: "failed".to_string(),
phase: "completion-contract-failed".to_string(),
current_action: "自主构建完成合同未能建立,任务未执行".to_string(),
terminal_detail: Some(public_error.clone()),
error: Some(public_error),
updated_at: unix_timestamp(),
..record.clone()
};
append_game_creator_agent_runtime_task_record_unlocked(root, &failed)?;
return Err(format!("自主构建完成合同建立失败,任务未执行:{error}"));
let public_error = redact_agent_runtime_project_paths(root, &error, 500);
let failed = AgentRuntimeTaskRecord {
status: "failed".to_string(),
phase: "completion-contract-failed".to_string(),
current_action: "自主构建完成合同未能建立,任务未执行".to_string(),
terminal_detail: Some(public_error.clone()),
error: Some(public_error),
updated_at: unix_timestamp(),
..record.clone()
};
append_game_creator_agent_runtime_task_record_unlocked(root, &failed)?;
return Err(format!("自主构建完成合同建立失败,任务未执行:{error}"));
}
}
Ok(record)