Move Epiphany notification shaping to bridge
This commit is contained in:
parent
f0cd7538a3
commit
bd3e3cbb70
5 changed files with 67 additions and 43 deletions
|
|
@ -3,6 +3,8 @@ use std::path::PathBuf;
|
|||
use codex_app_server_protocol::ThreadEpiphanyReorientFinding;
|
||||
use codex_app_server_protocol::ThreadEpiphanyRoleFinding;
|
||||
use codex_app_server_protocol::ThreadEpiphanyRoleId;
|
||||
use codex_app_server_protocol::ThreadEpiphanyStateUpdatedNotification;
|
||||
use codex_app_server_protocol::ThreadEpiphanyStateUpdatedSource;
|
||||
use codex_app_server_protocol::ThreadEpiphanyStateUpdatedField;
|
||||
use codex_app_server_protocol::ThreadEpiphanyUpdatePatch;
|
||||
use codex_core::EpiphanyStateUpdate;
|
||||
|
|
@ -99,6 +101,22 @@ pub fn state_update_from_thread_patch(
|
|||
}
|
||||
}
|
||||
|
||||
pub fn epiphany_state_updated_notification(
|
||||
thread_id: String,
|
||||
source: ThreadEpiphanyStateUpdatedSource,
|
||||
revision: u64,
|
||||
changed_fields: Vec<ThreadEpiphanyStateUpdatedField>,
|
||||
epiphany_state: codex_protocol::protocol::EpiphanyThreadState,
|
||||
) -> ThreadEpiphanyStateUpdatedNotification {
|
||||
ThreadEpiphanyStateUpdatedNotification {
|
||||
thread_id,
|
||||
source,
|
||||
revision,
|
||||
changed_fields,
|
||||
epiphany_state,
|
||||
}
|
||||
}
|
||||
|
||||
pub fn imagination_role_accept_patch_errors(patch: &ThreadEpiphanyUpdatePatch) -> Vec<String> {
|
||||
imagination_role_state_patch_policy_errors(&core_state_patch_from_protocol(patch))
|
||||
}
|
||||
|
|
|
|||
Reference in a new issue