mirror of
https://github.com/openai/codex.git
synced 2026-10-20 08:19:50 +00:00
Remove personality plumbing from the TUI (#49876)
## What changed Remove personality from TUI turn commands and cached thread session state, and stop applying personality from thread settings notifications. Send no personality override in `turn/start` requests. Forward `personality` through session configuration only when explicitly supplied as a CLI override, rather than deriving it from the effective local configuration. ## Testing Extend configuration override coverage to verify that `personality = "none"` is forwarded only when supplied through CLI overrides. GitOrigin-RevId: bd3c3bacc90e0561016c0cac557eb1b0e50d32c0
This commit is contained in:
@@ -255,7 +255,6 @@ impl App {
|
||||
/*summary*/ None,
|
||||
/*service_tier*/ None,
|
||||
/*collaboration_mode*/ None,
|
||||
/*personality*/ None,
|
||||
)));
|
||||
self.app_event_tx.send(AppEvent::InsertHistoryCell(Box::new(
|
||||
history_cell::new_info_event(
|
||||
@@ -905,7 +904,6 @@ impl App {
|
||||
/*summary*/ None,
|
||||
/*service_tier*/ None,
|
||||
/*collaboration_mode*/ None,
|
||||
/*personality*/ None,
|
||||
);
|
||||
let replay_state_op =
|
||||
ThreadEventStore::op_can_change_pending_replay_state(&op).then(|| op.clone());
|
||||
@@ -1308,7 +1306,6 @@ impl App {
|
||||
/*summary*/ None,
|
||||
/*service_tier*/ None,
|
||||
/*collaboration_mode*/ None,
|
||||
/*personality*/ None,
|
||||
);
|
||||
let replay_state_op =
|
||||
ThreadEventStore::op_can_change_pending_replay_state(&op).then(|| op.clone());
|
||||
@@ -1913,7 +1910,6 @@ enabled = false
|
||||
instruction_source_paths: Vec::new(),
|
||||
reasoning_effort: None,
|
||||
collaboration_mode: None,
|
||||
personality: None,
|
||||
message_history: None,
|
||||
network_proxy: None,
|
||||
rollout_path: Some(PathBuf::new()),
|
||||
|
||||
@@ -2384,7 +2384,6 @@ impl App {
|
||||
/*summary*/ None,
|
||||
/*service_tier*/ None,
|
||||
/*collaboration_mode*/ None,
|
||||
/*personality*/ None,
|
||||
),
|
||||
));
|
||||
self.app_event_tx.send(AppEvent::UpdateAskForApprovalPolicy(
|
||||
|
||||
@@ -53,7 +53,6 @@ pub(in crate::app) fn attach_thread(app: &mut App, thread_id: ThreadId) {
|
||||
instruction_source_paths: Vec::new(),
|
||||
reasoning_effort: None,
|
||||
collaboration_mode: None,
|
||||
personality: None,
|
||||
message_history: None,
|
||||
network_proxy: None,
|
||||
rollout_path: None,
|
||||
|
||||
@@ -198,7 +198,6 @@ use codex_protocol::ThreadId;
|
||||
use codex_protocol::config_types::CollaborationMode;
|
||||
use codex_protocol::config_types::CollaborationModeMask;
|
||||
use codex_protocol::config_types::ModeKind;
|
||||
use codex_protocol::config_types::Personality;
|
||||
use codex_protocol::config_types::SandboxMode;
|
||||
use codex_protocol::config_types::ServiceTier;
|
||||
use codex_protocol::config_types::Settings;
|
||||
@@ -3403,7 +3402,6 @@ default_permissions = "locked-down"
|
||||
summary: None,
|
||||
service_tier: None,
|
||||
collaboration_mode: None,
|
||||
personality: None,
|
||||
}
|
||||
);
|
||||
let cell = match app_event_rx.try_recv() {
|
||||
@@ -3496,7 +3494,6 @@ async fn update_feature_flags_enabling_guardian_selects_auto_review() -> Result<
|
||||
summary: None,
|
||||
service_tier: None,
|
||||
collaboration_mode: None,
|
||||
personality: None,
|
||||
})
|
||||
);
|
||||
let cell = match app_event_rx.try_recv() {
|
||||
@@ -3590,7 +3587,6 @@ async fn update_feature_flags_disabling_guardian_clears_review_policy_and_restor
|
||||
summary: None,
|
||||
service_tier: None,
|
||||
collaboration_mode: None,
|
||||
personality: None,
|
||||
})
|
||||
);
|
||||
let cell = match app_event_rx.try_recv() {
|
||||
@@ -3670,7 +3666,6 @@ async fn update_feature_flags_enabling_guardian_overrides_explicit_manual_review
|
||||
summary: None,
|
||||
service_tier: None,
|
||||
collaboration_mode: None,
|
||||
personality: None,
|
||||
})
|
||||
);
|
||||
|
||||
@@ -3729,7 +3724,6 @@ async fn update_feature_flags_disabling_guardian_clears_manual_review_policy_wit
|
||||
summary: None,
|
||||
service_tier: None,
|
||||
collaboration_mode: None,
|
||||
personality: None,
|
||||
})
|
||||
);
|
||||
assert!(
|
||||
@@ -5920,7 +5914,6 @@ async fn render_clear_ui_header_after_long_transcript_for_snapshot() -> String {
|
||||
instruction_source_paths: Vec::new(),
|
||||
reasoning_effort: Some(ReasoningEffortConfig::High),
|
||||
collaboration_mode: None,
|
||||
personality: None,
|
||||
message_history: None,
|
||||
network_proxy: None,
|
||||
rollout_path: Some(PathBuf::new()),
|
||||
@@ -6531,7 +6524,6 @@ fn test_thread_session(thread_id: ThreadId, cwd: PathBuf) -> ThreadSessionState
|
||||
instruction_source_paths: Vec::new(),
|
||||
reasoning_effort: None,
|
||||
collaboration_mode: None,
|
||||
personality: None,
|
||||
message_history: None,
|
||||
network_proxy: None,
|
||||
rollout_path: Some(PathBuf::new()),
|
||||
@@ -7631,7 +7623,6 @@ async fn backtrack_selection_preserves_selected_prompt_and_requests_branch() {
|
||||
instruction_source_paths: Vec::new(),
|
||||
reasoning_effort: None,
|
||||
collaboration_mode: None,
|
||||
personality: None,
|
||||
message_history: None,
|
||||
network_proxy: None,
|
||||
rollout_path: Some(PathBuf::new()),
|
||||
@@ -7705,7 +7696,6 @@ async fn backtrack_selection_preserves_selected_prompt_and_requests_branch() {
|
||||
instruction_source_paths: Vec::new(),
|
||||
reasoning_effort: None,
|
||||
collaboration_mode: None,
|
||||
personality: None,
|
||||
message_history: None,
|
||||
network_proxy: None,
|
||||
rollout_path: Some(PathBuf::new()),
|
||||
@@ -9001,7 +8991,6 @@ async fn new_session_requests_shutdown_for_previous_conversation() {
|
||||
instruction_source_paths: Vec::new(),
|
||||
reasoning_effort: None,
|
||||
collaboration_mode: None,
|
||||
personality: None,
|
||||
message_history: None,
|
||||
network_proxy: None,
|
||||
rollout_path: Some(PathBuf::new()),
|
||||
@@ -9120,7 +9109,6 @@ async fn override_turn_context_sends_thread_settings_update() {
|
||||
let thread_id = started.session.thread_id;
|
||||
let initial_model = started.session.model.clone();
|
||||
let initial_effort = started.session.reasoning_effort.clone();
|
||||
let initial_personality = started.session.personality;
|
||||
app.enqueue_primary_thread_session(started.session, started.turns)
|
||||
.await
|
||||
.expect("primary thread should be registered");
|
||||
@@ -9146,7 +9134,6 @@ async fn override_turn_context_sends_thread_settings_update() {
|
||||
/*summary*/ None,
|
||||
Some(Some(service_tier.clone())),
|
||||
Some(collaboration_mode.clone()),
|
||||
Some(Personality::Pragmatic),
|
||||
);
|
||||
|
||||
let handled = app
|
||||
@@ -9192,10 +9179,6 @@ async fn override_turn_context_sends_thread_settings_update() {
|
||||
notified_mode.settings.reasoning_effort,
|
||||
collaboration_mode.settings.reasoning_effort
|
||||
);
|
||||
assert_eq!(
|
||||
notification.thread_settings.personality, initial_personality,
|
||||
"the Pragmatic turn override should not change personality"
|
||||
);
|
||||
|
||||
app.handle_app_server_event(
|
||||
&app_server,
|
||||
@@ -9223,7 +9206,6 @@ async fn override_turn_context_sends_thread_settings_update() {
|
||||
updated_mode.settings.reasoning_effort,
|
||||
collaboration_mode.settings.reasoning_effort
|
||||
);
|
||||
assert_eq!(updated_session.personality, initial_personality);
|
||||
assert_eq!(updated_session.service_tier, Some(service_tier));
|
||||
assert_eq!(updated_session.approval_policy, AskForApproval::OnRequest);
|
||||
assert_eq!(
|
||||
@@ -9690,7 +9672,7 @@ async fn inactive_thread_settings_notification_updates_cached_collaboration_mode
|
||||
summary: None,
|
||||
collaboration_mode: collaboration_mode.clone(),
|
||||
multi_agent_mode: Default::default(),
|
||||
personality: Some(Personality::Pragmatic),
|
||||
personality: None,
|
||||
},
|
||||
};
|
||||
app.enqueue_thread_notification(
|
||||
@@ -9711,7 +9693,6 @@ async fn inactive_thread_settings_notification_updates_cached_collaboration_mode
|
||||
.clone()
|
||||
.expect("inactive session should remain cached");
|
||||
assert_eq!(cached_session.model, "gpt-test");
|
||||
assert_eq!(cached_session.personality, Some(Personality::Pragmatic));
|
||||
assert_eq!(
|
||||
cached_session.collaboration_mode.as_deref(),
|
||||
Some(&collaboration_mode)
|
||||
@@ -9731,10 +9712,6 @@ async fn inactive_thread_settings_notification_updates_cached_collaboration_mode
|
||||
app.chat_widget.current_reasoning_effort(),
|
||||
Some(ReasoningEffortConfig::High)
|
||||
);
|
||||
assert_eq!(
|
||||
app.chat_widget.config_ref().personality,
|
||||
Some(Personality::Pragmatic)
|
||||
);
|
||||
}
|
||||
|
||||
#[tokio::test]
|
||||
@@ -9761,7 +9738,6 @@ async fn clear_only_ui_reset_preserves_chat_session_state() {
|
||||
instruction_source_paths: Vec::new(),
|
||||
reasoning_effort: None,
|
||||
collaboration_mode: None,
|
||||
personality: None,
|
||||
message_history: None,
|
||||
network_proxy: None,
|
||||
rollout_path: Some(PathBuf::new()),
|
||||
|
||||
@@ -680,7 +680,6 @@ mod tests {
|
||||
instruction_source_paths: Vec::new(),
|
||||
reasoning_effort: None,
|
||||
collaboration_mode: None,
|
||||
personality: None,
|
||||
message_history: None,
|
||||
network_proxy: None,
|
||||
rollout_path: Some(PathBuf::new()),
|
||||
|
||||
@@ -746,7 +746,6 @@ impl App {
|
||||
service_tier,
|
||||
final_output_json_schema,
|
||||
collaboration_mode,
|
||||
personality,
|
||||
} => {
|
||||
let mut should_start_turn = true;
|
||||
if let Some(turn_id) = self.active_turn_id_for_thread(thread_id).await {
|
||||
@@ -912,7 +911,6 @@ impl App {
|
||||
*summary,
|
||||
service_tier.clone(),
|
||||
collaboration_mode.clone(),
|
||||
*personality,
|
||||
final_output_json_schema.clone(),
|
||||
cyber_access_program.map(Into::into),
|
||||
)
|
||||
|
||||
@@ -82,7 +82,6 @@ impl App {
|
||||
// `thread/read` does not include all thread settings, so do not carry
|
||||
// thread-scoped state from the currently active session.
|
||||
session.collaboration_mode = None;
|
||||
session.personality = None;
|
||||
session.daybreak_enabled = false;
|
||||
}
|
||||
session
|
||||
@@ -108,7 +107,6 @@ impl App {
|
||||
instruction_source_paths: Vec::new(),
|
||||
reasoning_effort: self.chat_widget.current_reasoning_effort(),
|
||||
collaboration_mode: None,
|
||||
personality: None,
|
||||
message_history: None,
|
||||
network_proxy: None,
|
||||
rollout_path: thread.path.clone(),
|
||||
@@ -193,7 +191,6 @@ mod tests {
|
||||
instruction_source_paths: Vec::new(),
|
||||
reasoning_effort: None,
|
||||
collaboration_mode: None,
|
||||
personality: None,
|
||||
message_history: None,
|
||||
network_proxy: None,
|
||||
rollout_path: Some(PathBuf::new()),
|
||||
|
||||
@@ -5,7 +5,6 @@ use crate::app_command::AppCommand;
|
||||
use crate::app_event::AppEvent;
|
||||
use crate::app_event::PermissionProfileSelection;
|
||||
use crate::app_server_session::AppServerSession;
|
||||
use crate::app_server_session::personality_opt_out_only;
|
||||
use crate::chatwidget::cyber_model_approval_reviewer;
|
||||
use crate::session_state::ThreadSessionState;
|
||||
use codex_app_server_protocol::ApprovalsReviewer as AppServerApprovalsReviewer;
|
||||
@@ -162,7 +161,6 @@ impl App {
|
||||
summary,
|
||||
service_tier,
|
||||
collaboration_mode,
|
||||
personality,
|
||||
} = op
|
||||
else {
|
||||
return;
|
||||
@@ -181,7 +179,6 @@ impl App {
|
||||
summary: *summary,
|
||||
service_tier: service_tier.clone(),
|
||||
collaboration_mode: collaboration_mode.clone(),
|
||||
personality: *personality,
|
||||
..ThreadSettingsUpdateParams::default()
|
||||
};
|
||||
self.send_thread_settings_update(app_server, params).await;
|
||||
@@ -212,9 +209,8 @@ impl App {
|
||||
pub(super) async fn send_thread_settings_update(
|
||||
&mut self,
|
||||
app_server: &mut AppServerSession,
|
||||
mut params: ThreadSettingsUpdateParams,
|
||||
params: ThreadSettingsUpdateParams,
|
||||
) -> bool {
|
||||
params.personality = personality_opt_out_only(params.personality);
|
||||
if !thread_settings_update_has_changes(¶ms) {
|
||||
return false;
|
||||
}
|
||||
@@ -266,7 +262,6 @@ fn apply_thread_settings_to_session(session: &mut ThreadSessionState, settings:
|
||||
);
|
||||
session.active_permission_profile = settings.active_permission_profile.clone().map(Into::into);
|
||||
session.set_cwd_retargeting_implicit_runtime_workspace_root(settings.cwd.clone());
|
||||
session.personality = settings.personality;
|
||||
let mut collaboration_mode = settings.collaboration_mode.clone();
|
||||
collaboration_mode
|
||||
.settings
|
||||
@@ -287,5 +282,4 @@ fn thread_settings_update_has_changes(params: &ThreadSettingsUpdateParams) -> bo
|
||||
|| params.effort.is_some()
|
||||
|| params.summary.is_some()
|
||||
|| params.collaboration_mode.is_some()
|
||||
|| params.personality.is_some()
|
||||
}
|
||||
|
||||
@@ -14,7 +14,6 @@ use codex_config::types::ApprovalsReviewer;
|
||||
use codex_protocol::ThreadId;
|
||||
use codex_protocol::approvals::GuardianAssessmentEvent;
|
||||
use codex_protocol::config_types::CollaborationMode;
|
||||
use codex_protocol::config_types::Personality;
|
||||
use codex_protocol::config_types::ReasoningSummary as ReasoningSummaryConfig;
|
||||
use codex_protocol::models::ActivePermissionProfile;
|
||||
use codex_protocol::models::PermissionProfile;
|
||||
@@ -129,7 +128,6 @@ pub(crate) enum AppCommand {
|
||||
service_tier: Option<Option<String>>,
|
||||
final_output_json_schema: Option<Value>,
|
||||
collaboration_mode: Option<CollaborationMode>,
|
||||
personality: Option<Personality>,
|
||||
},
|
||||
OverrideTurnContext {
|
||||
cwd: Option<PathBuf>,
|
||||
@@ -142,7 +140,6 @@ pub(crate) enum AppCommand {
|
||||
summary: Option<ReasoningSummaryConfig>,
|
||||
service_tier: Option<Option<String>>,
|
||||
collaboration_mode: Option<CollaborationMode>,
|
||||
personality: Option<Personality>,
|
||||
},
|
||||
ExecApproval {
|
||||
id: String,
|
||||
@@ -227,7 +224,6 @@ impl AppCommand {
|
||||
service_tier: Option<Option<String>>,
|
||||
final_output_json_schema: Option<Value>,
|
||||
collaboration_mode: Option<CollaborationMode>,
|
||||
personality: Option<Personality>,
|
||||
) -> Self {
|
||||
Self::UserTurn {
|
||||
client_user_message_id,
|
||||
@@ -242,7 +238,6 @@ impl AppCommand {
|
||||
service_tier,
|
||||
final_output_json_schema,
|
||||
collaboration_mode,
|
||||
personality,
|
||||
}
|
||||
}
|
||||
|
||||
@@ -258,7 +253,6 @@ impl AppCommand {
|
||||
summary: Option<ReasoningSummaryConfig>,
|
||||
service_tier: Option<Option<String>>,
|
||||
collaboration_mode: Option<CollaborationMode>,
|
||||
personality: Option<Personality>,
|
||||
) -> Self {
|
||||
Self::OverrideTurnContext {
|
||||
cwd,
|
||||
@@ -271,7 +265,6 @@ impl AppCommand {
|
||||
summary,
|
||||
service_tier,
|
||||
collaboration_mode,
|
||||
personality,
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
@@ -134,7 +134,6 @@ use codex_config::ConfigLayerSource;
|
||||
use codex_otel::TelemetryAuthMode;
|
||||
use codex_protocol::ThreadId;
|
||||
use codex_protocol::approvals::GuardianAssessmentEvent;
|
||||
use codex_protocol::config_types::Personality;
|
||||
use codex_protocol::config_types::SERVICE_TIER_DEFAULT_REQUEST_VALUE;
|
||||
use codex_protocol::models::ActivePermissionProfile;
|
||||
use codex_protocol::models::BaseInstructionsProvenance;
|
||||
@@ -1295,8 +1294,7 @@ impl AppServerSession {
|
||||
// method-not-found, experimental-capability-gated, or an unknown
|
||||
// request variant. Treat those as a session-level capability
|
||||
// downgrade so local TUI setting changes stay best-effort instead
|
||||
// of showing an error every time the user changes model, effort,
|
||||
// personality, or mode.
|
||||
// of showing an error every time the user changes model, effort, or mode.
|
||||
self.thread_settings_update_supported = false;
|
||||
Ok(false)
|
||||
}
|
||||
@@ -1343,7 +1341,6 @@ impl AppServerSession {
|
||||
summary: Option<codex_protocol::config_types::ReasoningSummary>,
|
||||
service_tier: Option<Option<String>>,
|
||||
collaboration_mode: Option<codex_protocol::config_types::CollaborationMode>,
|
||||
personality: Option<codex_protocol::config_types::Personality>,
|
||||
output_schema: Option<serde_json::Value>,
|
||||
cyber_access_program: Option<codex_app_server_protocol::CyberAccessProgram>,
|
||||
) -> Result<TurnStartResponse> {
|
||||
@@ -1374,7 +1371,7 @@ impl AppServerSession {
|
||||
service_tier_for_turn: None,
|
||||
effort,
|
||||
summary,
|
||||
personality: personality_opt_out_only(personality),
|
||||
personality: None,
|
||||
output_schema,
|
||||
collaboration_mode,
|
||||
multi_agent_mode: None,
|
||||
@@ -1847,11 +1844,6 @@ fn approvals_reviewer_override_from_config(
|
||||
Some(config.approvals_reviewer.into())
|
||||
}
|
||||
|
||||
// Keep the explicit Bridge opt-out while retiring Friendly/Pragmatic selection.
|
||||
pub(crate) fn personality_opt_out_only(personality: Option<Personality>) -> Option<Personality> {
|
||||
personality.filter(|personality| *personality == Personality::None)
|
||||
}
|
||||
|
||||
fn config_request_overrides_from_config(
|
||||
config: &Config,
|
||||
thread_params_mode: ThreadParamsMode,
|
||||
@@ -1874,6 +1866,7 @@ fn config_request_overrides_from_config(
|
||||
| "features"
|
||||
| "network"
|
||||
| "permissions"
|
||||
| "personality"
|
||||
| "sandbox_workspace_write"
|
||||
| "shell_environment_policy"
|
||||
| "suppress_unstable_features_warning"
|
||||
@@ -1897,10 +1890,6 @@ fn config_request_overrides_from_config(
|
||||
.as_ref()
|
||||
.map(std::string::ToString::to_string),
|
||||
);
|
||||
insert(
|
||||
"personality",
|
||||
personality_opt_out_only(config.personality).map(|personality| personality.to_string()),
|
||||
);
|
||||
// Only winning launch choices may replace server defaults or saved thread settings.
|
||||
let origins = config.config_layer_stack.origins();
|
||||
let effective = config.config_layer_stack.effective_config();
|
||||
@@ -2286,14 +2275,12 @@ async fn started_thread_from_start_response(
|
||||
async fn started_thread_from_resume_response(
|
||||
response: ThreadResumeResponse,
|
||||
local_settings: &LocalSettings,
|
||||
config: &Config,
|
||||
thread_params_mode: ThreadParamsMode,
|
||||
) -> Result<AppServerStartedThread> {
|
||||
let blocks_direct_input = thread_blocks_direct_input(&response.thread);
|
||||
let session = thread_session_state_from_thread_resume_response(
|
||||
&response,
|
||||
local_settings,
|
||||
config,
|
||||
thread_params_mode,
|
||||
)
|
||||
.await
|
||||
@@ -2358,7 +2345,6 @@ async fn thread_session_state_from_thread_start_response(
|
||||
response.runtime_workspace_roots.clone(),
|
||||
response.instruction_source_path_uris(),
|
||||
response.reasoning_effort.clone(),
|
||||
config.personality,
|
||||
local_settings,
|
||||
)
|
||||
.await?;
|
||||
@@ -2372,7 +2358,6 @@ async fn thread_session_state_from_thread_start_response(
|
||||
async fn thread_session_state_from_thread_resume_response(
|
||||
response: &ThreadResumeResponse,
|
||||
local_settings: &LocalSettings,
|
||||
config: &Config,
|
||||
_thread_params_mode: ThreadParamsMode,
|
||||
) -> Result<ThreadSessionState, String> {
|
||||
// The server owns restored rules. This legacy projection is for display only;
|
||||
@@ -2398,7 +2383,6 @@ async fn thread_session_state_from_thread_resume_response(
|
||||
response.runtime_workspace_roots.clone(),
|
||||
response.instruction_source_path_uris(),
|
||||
response.reasoning_effort.clone(),
|
||||
config.personality,
|
||||
local_settings,
|
||||
)
|
||||
.await?;
|
||||
@@ -2436,7 +2420,6 @@ async fn thread_session_state_from_thread_fork_response(
|
||||
response.runtime_workspace_roots.clone(),
|
||||
response.instruction_source_path_uris(),
|
||||
response.reasoning_effort.clone(),
|
||||
config.personality,
|
||||
local_settings,
|
||||
)
|
||||
.await?;
|
||||
@@ -2490,7 +2473,6 @@ async fn thread_session_state_from_thread_response(
|
||||
runtime_workspace_roots: Vec<AbsolutePathBuf>,
|
||||
instruction_source_paths: Vec<PathUri>,
|
||||
reasoning_effort: Option<codex_protocol::openai_models::ReasoningEffort>,
|
||||
personality: Option<codex_protocol::config_types::Personality>,
|
||||
local_settings: &LocalSettings,
|
||||
) -> Result<ThreadSessionState, String> {
|
||||
let thread_id = ThreadId::from_string(thread_id)
|
||||
@@ -2524,7 +2506,6 @@ async fn thread_session_state_from_thread_response(
|
||||
instruction_source_paths,
|
||||
reasoning_effort,
|
||||
collaboration_mode: None,
|
||||
personality,
|
||||
message_history: Some(MessageHistoryMetadata {
|
||||
log_id,
|
||||
entry_count,
|
||||
@@ -2577,7 +2558,6 @@ mod tests {
|
||||
use codex_app_server_protocol::Turn;
|
||||
use codex_app_server_protocol::TurnStatus;
|
||||
use codex_features::Feature;
|
||||
use codex_protocol::config_types::Personality;
|
||||
use codex_protocol::config_types::ReasoningSummary;
|
||||
use codex_protocol::config_types::ServiceTier;
|
||||
use codex_protocol::config_types::Verbosity;
|
||||
@@ -3427,7 +3407,6 @@ mod tests {
|
||||
config.model_reasoning_effort = Some(ReasoningEffort::High);
|
||||
config.model_reasoning_summary = Some(ReasoningSummary::Detailed);
|
||||
config.model_verbosity = Some(Verbosity::Low);
|
||||
config.personality = Some(Personality::Pragmatic);
|
||||
config
|
||||
.web_search_mode
|
||||
.set(WebSearchMode::Disabled)
|
||||
@@ -3485,7 +3464,7 @@ mod tests {
|
||||
std::fs::write(
|
||||
home.path().join("config.toml"),
|
||||
format!(
|
||||
"model_reasoning_summary = \"concise\"\nmodel_verbosity = \"low\"\nweb_search = \"disabled\"\n[projects.{}]\ntrust_level = \"trusted\"\n",
|
||||
"model_reasoning_summary = \"concise\"\nmodel_verbosity = \"low\"\nweb_search = \"disabled\"\npersonality = \"none\"\n[projects.{}]\ntrust_level = \"trusted\"\n",
|
||||
toml::Value::String(workspace.to_string_lossy().into_owned()),
|
||||
),
|
||||
)?;
|
||||
@@ -3546,6 +3525,7 @@ mod tests {
|
||||
("model_reasoning_summary".to_string(), "auto".into()),
|
||||
("model_verbosity".to_string(), "medium".into()),
|
||||
("web_search".to_string(), "live".into()),
|
||||
("personality".to_string(), "none".into()),
|
||||
]
|
||||
} else {
|
||||
Vec::new()
|
||||
@@ -3555,9 +3535,14 @@ mod tests {
|
||||
let overrides = config_request_overrides_from_config(&config, ThreadParamsMode::Remote)
|
||||
.expect("config overrides");
|
||||
assert_eq!(
|
||||
["model_reasoning_summary", "model_verbosity", "web_search"]
|
||||
.map(|key| overrides.get(key).and_then(serde_json::Value::as_str)),
|
||||
expected,
|
||||
(
|
||||
["model_reasoning_summary", "model_verbosity", "web_search"]
|
||||
.map(|key| overrides.get(key).and_then(serde_json::Value::as_str)),
|
||||
overrides
|
||||
.get("personality")
|
||||
.and_then(serde_json::Value::as_str),
|
||||
),
|
||||
(expected, cli.then_some("none")),
|
||||
);
|
||||
}
|
||||
Ok(())
|
||||
@@ -3571,7 +3556,6 @@ mod tests {
|
||||
config.model_provider_id = "configured-provider".to_string();
|
||||
config.model_reasoning_effort = Some(ReasoningEffort::Ultra);
|
||||
config.model_reasoning_summary = Some(ReasoningSummary::Detailed);
|
||||
config.personality = Some(Personality::Pragmatic);
|
||||
|
||||
let params = thread_resume_params_from_config(
|
||||
config,
|
||||
@@ -3882,66 +3866,6 @@ mod tests {
|
||||
Ok(())
|
||||
}
|
||||
|
||||
#[tokio::test]
|
||||
async fn config_request_overrides_only_forward_explicit_personality_opt_out() {
|
||||
let temp_dir = tempfile::tempdir().expect("tempdir");
|
||||
let mut config = build_config(&temp_dir).await;
|
||||
config.personality = None;
|
||||
|
||||
let implicit_overrides =
|
||||
config_request_overrides_from_config(&config, ThreadParamsMode::Remote)
|
||||
.expect("config overrides");
|
||||
|
||||
assert!(!implicit_overrides.contains_key("personality"));
|
||||
|
||||
for personality in [Personality::Friendly, Personality::Pragmatic] {
|
||||
config.personality = Some(personality);
|
||||
let ordinary_overrides =
|
||||
config_request_overrides_from_config(&config, ThreadParamsMode::Remote)
|
||||
.expect("config overrides");
|
||||
assert!(!ordinary_overrides.contains_key("personality"));
|
||||
}
|
||||
|
||||
config.personality = Some(Personality::None);
|
||||
let explicit_overrides =
|
||||
config_request_overrides_from_config(&config, ThreadParamsMode::Remote)
|
||||
.expect("config overrides");
|
||||
|
||||
assert_eq!(
|
||||
explicit_overrides.get("personality"),
|
||||
Some(&serde_json::Value::String("none".to_string()))
|
||||
);
|
||||
|
||||
for mode in [ThreadParamsMode::Embedded, ThreadParamsMode::Remote] {
|
||||
let start = thread_start_params_from_config(
|
||||
&config, mode, /*remote_cwd_override*/ None,
|
||||
/*session_start_source*/ None,
|
||||
);
|
||||
let resume = thread_resume_params_from_config(
|
||||
config.clone(),
|
||||
ThreadId::new(),
|
||||
mode,
|
||||
/*remote_cwd_override*/ None,
|
||||
ResumeModelSettings::OverrideFromCurrentConfig,
|
||||
crate::resume_permissions::ResumePermissions::CURRENT_CONFIG,
|
||||
);
|
||||
let fork = thread_fork_params_from_config(
|
||||
config.clone(),
|
||||
ThreadId::new(),
|
||||
mode,
|
||||
/*remote_cwd_override*/ None,
|
||||
);
|
||||
for overrides in [start.config, resume.config, fork.config] {
|
||||
assert_eq!(
|
||||
overrides
|
||||
.as_ref()
|
||||
.and_then(|overrides| overrides.get("personality")),
|
||||
Some(&serde_json::Value::String("none".to_string()))
|
||||
);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
#[tokio::test]
|
||||
async fn thread_fork_params_forward_instruction_overrides() {
|
||||
let temp_dir = tempfile::tempdir().expect("tempdir");
|
||||
@@ -4203,7 +4127,6 @@ mod tests {
|
||||
let started = started_thread_from_resume_response(
|
||||
response.clone(),
|
||||
&LocalSettings::from(&config),
|
||||
&config,
|
||||
ThreadParamsMode::Remote,
|
||||
)
|
||||
.await
|
||||
@@ -4258,7 +4181,6 @@ mod tests {
|
||||
let started = started_thread_from_resume_response(
|
||||
response.clone(),
|
||||
&LocalSettings::from(&embedded_config),
|
||||
&embedded_config,
|
||||
ThreadParamsMode::Embedded,
|
||||
)
|
||||
.await
|
||||
@@ -4270,7 +4192,6 @@ mod tests {
|
||||
let started = started_thread_from_resume_response(
|
||||
empty_roots_response,
|
||||
&LocalSettings::from(&config),
|
||||
&config,
|
||||
ThreadParamsMode::Remote,
|
||||
)
|
||||
.await
|
||||
@@ -4357,7 +4278,6 @@ mod tests {
|
||||
Vec::new(),
|
||||
Vec::new(),
|
||||
/*reasoning_effort*/ None,
|
||||
config.personality,
|
||||
&LocalSettings::from(&config),
|
||||
)
|
||||
.await
|
||||
@@ -4394,7 +4314,6 @@ mod tests {
|
||||
Vec::new(),
|
||||
Vec::new(),
|
||||
/*reasoning_effort*/ None,
|
||||
config.personality,
|
||||
&LocalSettings::from(&config),
|
||||
)
|
||||
.await
|
||||
|
||||
@@ -136,7 +136,6 @@ stream_max_retries = 0
|
||||
/*summary*/ None,
|
||||
/*service_tier*/ None,
|
||||
/*collaboration_mode*/ None,
|
||||
/*personality*/ None,
|
||||
/*output_schema*/ None,
|
||||
/*cyber_access_program*/ None,
|
||||
)
|
||||
|
||||
@@ -92,7 +92,6 @@ impl AppServerSession {
|
||||
config.workspace_roots.clone(),
|
||||
Vec::new(),
|
||||
thread.reasoning_effort,
|
||||
config.personality,
|
||||
local_settings,
|
||||
)
|
||||
.await
|
||||
@@ -251,7 +250,6 @@ impl AppServerSession {
|
||||
let mut started = started_thread_from_resume_response(
|
||||
response,
|
||||
local_settings,
|
||||
&config,
|
||||
self.thread_params_mode(),
|
||||
)
|
||||
.await?;
|
||||
|
||||
@@ -94,7 +94,6 @@ stream_max_retries = 0
|
||||
/*summary*/ None,
|
||||
/*service_tier*/ None,
|
||||
/*collaboration_mode*/ None,
|
||||
/*personality*/ None,
|
||||
/*output_schema*/ None,
|
||||
/*cyber_access_program*/ None,
|
||||
)
|
||||
|
||||
@@ -452,7 +452,6 @@ impl ChatWidget {
|
||||
service_tier,
|
||||
/*final_output_json_schema*/ None,
|
||||
collaboration_mode,
|
||||
/*personality*/ None,
|
||||
);
|
||||
let submitted_message = UserMessage {
|
||||
text,
|
||||
|
||||
@@ -284,7 +284,6 @@ impl ChatWidget {
|
||||
/*summary*/ None,
|
||||
/*service_tier*/ None,
|
||||
/*collaboration_mode*/ None,
|
||||
/*personality*/ None,
|
||||
)));
|
||||
tx.send(AppEvent::UpdateAskForApprovalPolicy(approval));
|
||||
tx.send(AppEvent::UpdateActivePermissionProfile(
|
||||
|
||||
@@ -476,7 +476,6 @@ impl ChatWidget {
|
||||
/*summary*/ None,
|
||||
/*service_tier*/ None,
|
||||
/*collaboration_mode*/ None,
|
||||
/*personality*/ None,
|
||||
)));
|
||||
tx.send(AppEvent::UpdateModel(switch_model_for_events.clone()));
|
||||
tx.send(AppEvent::UpdateReasoningEffort(Some(
|
||||
|
||||
@@ -110,7 +110,6 @@ impl ChatWidget {
|
||||
/*summary*/ None,
|
||||
Some(service_tier.clone()),
|
||||
/*collaboration_mode*/ None,
|
||||
/*personality*/ None,
|
||||
)));
|
||||
self.app_event_tx
|
||||
.send(AppEvent::PersistServiceTierSelection { service_tier });
|
||||
|
||||
@@ -153,7 +153,6 @@ impl ChatWidget {
|
||||
}
|
||||
}
|
||||
self.config.approvals_reviewer = session.approvals_reviewer;
|
||||
self.config.personality = session.personality;
|
||||
self.status_line_project_root_name_cache = None;
|
||||
let forked_from_id = session.forked_from_id;
|
||||
let default_model = session.model.clone();
|
||||
|
||||
@@ -481,7 +481,6 @@ impl ChatWidget {
|
||||
Constrained::allow_only(settings.approval_policy.to_core());
|
||||
}
|
||||
self.set_approvals_reviewer(settings.approvals_reviewer.to_core());
|
||||
self.config.personality = settings.personality;
|
||||
|
||||
let permission_profile = PermissionProfile::from_legacy_sandbox_policy_for_cwd(
|
||||
&settings.sandbox_policy.to_core(),
|
||||
@@ -735,7 +734,6 @@ impl ChatWidget {
|
||||
/*summary*/ None,
|
||||
/*service_tier*/ None,
|
||||
Some(self.effective_collaboration_mode()),
|
||||
/*personality*/ None,
|
||||
),
|
||||
});
|
||||
}
|
||||
|
||||
@@ -139,7 +139,6 @@ pub(super) use codex_protocol::approvals::GuardianRiskLevel;
|
||||
pub(super) use codex_protocol::approvals::GuardianUserAuthorization;
|
||||
pub(super) use codex_protocol::config_types::CollaborationMode;
|
||||
pub(super) use codex_protocol::config_types::ModeKind;
|
||||
pub(super) use codex_protocol::config_types::Personality;
|
||||
pub(super) use codex_protocol::config_types::SERVICE_TIER_DEFAULT_REQUEST_VALUE;
|
||||
pub(super) use codex_protocol::config_types::ServiceTier;
|
||||
pub(super) use codex_protocol::models::ActivePermissionProfile;
|
||||
|
||||
@@ -38,7 +38,7 @@ fn thread_settings_for_test(
|
||||
},
|
||||
},
|
||||
multi_agent_mode: Default::default(),
|
||||
personality: Some(Personality::Pragmatic),
|
||||
personality: None,
|
||||
},
|
||||
}
|
||||
}
|
||||
@@ -63,7 +63,6 @@ fn configured_thread_session(thread_id: ThreadId) -> crate::session_state::Threa
|
||||
instruction_source_paths: Vec::new(),
|
||||
reasoning_effort: None,
|
||||
collaboration_mode: None,
|
||||
personality: None,
|
||||
message_history: None,
|
||||
network_proxy: None,
|
||||
rollout_path: None,
|
||||
@@ -669,7 +668,6 @@ async fn thread_settings_updated_updates_visible_state_without_transcript() {
|
||||
.id,
|
||||
codex_protocol::models::BUILT_IN_PERMISSION_PROFILE_READ_ONLY
|
||||
);
|
||||
assert_eq!(chat.config_ref().personality, Some(Personality::Pragmatic));
|
||||
assert_eq!(chat.active_collaboration_mode_kind(), ModeKind::Plan);
|
||||
assert!(
|
||||
drain_insert_history(&mut rx).is_empty(),
|
||||
|
||||
@@ -439,7 +439,6 @@ async fn submission_preserves_text_elements_and_local_images() {
|
||||
instruction_source_paths: Vec::new(),
|
||||
reasoning_effort: Some(ReasoningEffortConfig::default()),
|
||||
collaboration_mode: None,
|
||||
personality: None,
|
||||
message_history: None,
|
||||
network_proxy: None,
|
||||
rollout_path: Some(rollout_file.path().to_path_buf()),
|
||||
@@ -550,7 +549,6 @@ async fn submission_includes_configured_active_permission_profile() {
|
||||
instruction_source_paths: Vec::new(),
|
||||
reasoning_effort: Some(ReasoningEffortConfig::default()),
|
||||
collaboration_mode: None,
|
||||
personality: None,
|
||||
message_history: None,
|
||||
network_proxy: None,
|
||||
rollout_path: Some(rollout_file.path().to_path_buf()),
|
||||
@@ -607,7 +605,6 @@ async fn submission_omits_active_permission_profile_for_legacy_snapshot() {
|
||||
instruction_source_paths: Vec::new(),
|
||||
reasoning_effort: Some(ReasoningEffortConfig::default()),
|
||||
collaboration_mode: None,
|
||||
personality: None,
|
||||
message_history: None,
|
||||
network_proxy: None,
|
||||
rollout_path: Some(rollout_file.path().to_path_buf()),
|
||||
@@ -654,7 +651,6 @@ async fn submission_with_remote_and_local_images_keeps_local_placeholder_numberi
|
||||
instruction_source_paths: Vec::new(),
|
||||
reasoning_effort: Some(ReasoningEffortConfig::default()),
|
||||
collaboration_mode: None,
|
||||
personality: None,
|
||||
message_history: None,
|
||||
network_proxy: None,
|
||||
rollout_path: Some(rollout_file.path().to_path_buf()),
|
||||
@@ -756,7 +752,6 @@ async fn enter_with_only_remote_images_submits_user_turn() {
|
||||
instruction_source_paths: Vec::new(),
|
||||
reasoning_effort: Some(ReasoningEffortConfig::default()),
|
||||
collaboration_mode: None,
|
||||
personality: None,
|
||||
message_history: None,
|
||||
network_proxy: None,
|
||||
rollout_path: Some(rollout_file.path().to_path_buf()),
|
||||
@@ -827,7 +822,6 @@ async fn shift_enter_with_only_remote_images_does_not_submit_user_turn() {
|
||||
instruction_source_paths: Vec::new(),
|
||||
reasoning_effort: Some(ReasoningEffortConfig::default()),
|
||||
collaboration_mode: None,
|
||||
personality: None,
|
||||
message_history: None,
|
||||
network_proxy: None,
|
||||
rollout_path: Some(rollout_file.path().to_path_buf()),
|
||||
@@ -870,7 +864,6 @@ async fn enter_with_only_remote_images_does_not_submit_when_modal_is_active() {
|
||||
instruction_source_paths: Vec::new(),
|
||||
reasoning_effort: Some(ReasoningEffortConfig::default()),
|
||||
collaboration_mode: None,
|
||||
personality: None,
|
||||
message_history: None,
|
||||
network_proxy: None,
|
||||
rollout_path: Some(rollout_file.path().to_path_buf()),
|
||||
@@ -913,7 +906,6 @@ async fn enter_with_only_remote_images_does_not_submit_when_input_disabled() {
|
||||
instruction_source_paths: Vec::new(),
|
||||
reasoning_effort: Some(ReasoningEffortConfig::default()),
|
||||
collaboration_mode: None,
|
||||
personality: None,
|
||||
message_history: None,
|
||||
network_proxy: None,
|
||||
rollout_path: Some(rollout_file.path().to_path_buf()),
|
||||
@@ -959,7 +951,6 @@ async fn submission_prefers_selected_duplicate_skill_path() {
|
||||
instruction_source_paths: Vec::new(),
|
||||
reasoning_effort: Some(ReasoningEffortConfig::default()),
|
||||
collaboration_mode: None,
|
||||
personality: None,
|
||||
message_history: None,
|
||||
network_proxy: None,
|
||||
rollout_path: Some(rollout_file.path().to_path_buf()),
|
||||
@@ -1508,7 +1499,6 @@ async fn interrupted_turn_restore_keeps_active_mode_for_resubmission() {
|
||||
match next_submit_op(&mut op_rx) {
|
||||
Op::UserTurn {
|
||||
collaboration_mode: Some(CollaborationMode { mode, .. }),
|
||||
personality: None,
|
||||
..
|
||||
} => assert_eq!(mode, expected_mode),
|
||||
other => {
|
||||
|
||||
@@ -1499,7 +1499,6 @@ async fn bang_shell_enter_while_task_running_submits_run_user_shell_command() {
|
||||
instruction_source_paths: Vec::new(),
|
||||
reasoning_effort: Some(ReasoningEffortConfig::default()),
|
||||
collaboration_mode: None,
|
||||
personality: None,
|
||||
message_history: None,
|
||||
network_proxy: None,
|
||||
rollout_path: Some(rollout_file.path().to_path_buf()),
|
||||
|
||||
@@ -38,7 +38,6 @@ async fn resumed_initial_messages_render_history() {
|
||||
instruction_source_paths: Vec::new(),
|
||||
reasoning_effort: Some(ReasoningEffortConfig::default()),
|
||||
collaboration_mode: None,
|
||||
personality: None,
|
||||
message_history: None,
|
||||
network_proxy: None,
|
||||
rollout_path: Some(rollout_file.path().to_path_buf()),
|
||||
@@ -156,7 +155,6 @@ async fn restored_conversation_ultra_remains_selected_after_switching_to_plan()
|
||||
instruction_source_paths: Vec::new(),
|
||||
reasoning_effort: Some(ReasoningEffortConfig::Ultra),
|
||||
collaboration_mode: None,
|
||||
personality: None,
|
||||
message_history: None,
|
||||
network_proxy: None,
|
||||
rollout_path: None,
|
||||
@@ -445,7 +443,6 @@ async fn replayed_user_message_preserves_text_elements_and_local_images() {
|
||||
instruction_source_paths: Vec::new(),
|
||||
reasoning_effort: Some(ReasoningEffortConfig::default()),
|
||||
collaboration_mode: None,
|
||||
personality: None,
|
||||
message_history: None,
|
||||
network_proxy: None,
|
||||
rollout_path: Some(rollout_file.path().to_path_buf()),
|
||||
@@ -519,7 +516,6 @@ async fn replayed_user_message_preserves_remote_image_urls() {
|
||||
instruction_source_paths: Vec::new(),
|
||||
reasoning_effort: Some(ReasoningEffortConfig::default()),
|
||||
collaboration_mode: None,
|
||||
personality: None,
|
||||
message_history: None,
|
||||
network_proxy: None,
|
||||
rollout_path: Some(rollout_file.path().to_path_buf()),
|
||||
@@ -627,7 +623,6 @@ async fn session_configured_syncs_widget_config_permissions_and_cwd() {
|
||||
instruction_source_paths: Vec::new(),
|
||||
reasoning_effort: Some(ReasoningEffortConfig::default()),
|
||||
collaboration_mode: None,
|
||||
personality: None,
|
||||
message_history: None,
|
||||
network_proxy: None,
|
||||
rollout_path: None,
|
||||
@@ -702,7 +697,6 @@ async fn session_configured_preserves_profile_workspace_roots() {
|
||||
instruction_source_paths: Vec::new(),
|
||||
reasoning_effort: Some(ReasoningEffortConfig::default()),
|
||||
collaboration_mode: None,
|
||||
personality: None,
|
||||
message_history: None,
|
||||
network_proxy: None,
|
||||
rollout_path: None,
|
||||
@@ -751,7 +745,6 @@ async fn session_configured_external_sandbox_keeps_external_runtime_policy() {
|
||||
instruction_source_paths: Vec::new(),
|
||||
reasoning_effort: Some(ReasoningEffortConfig::default()),
|
||||
collaboration_mode: None,
|
||||
personality: None,
|
||||
message_history: None,
|
||||
network_proxy: None,
|
||||
rollout_path: None,
|
||||
@@ -794,7 +787,6 @@ async fn replayed_user_message_with_only_remote_images_renders_history_cell() {
|
||||
instruction_source_paths: Vec::new(),
|
||||
reasoning_effort: Some(ReasoningEffortConfig::default()),
|
||||
collaboration_mode: None,
|
||||
personality: None,
|
||||
message_history: None,
|
||||
network_proxy: None,
|
||||
rollout_path: Some(rollout_file.path().to_path_buf()),
|
||||
@@ -856,7 +848,6 @@ async fn replayed_user_message_with_only_local_images_renders_history_cell() {
|
||||
instruction_source_paths: Vec::new(),
|
||||
reasoning_effort: Some(ReasoningEffortConfig::default()),
|
||||
collaboration_mode: None,
|
||||
personality: None,
|
||||
message_history: None,
|
||||
network_proxy: None,
|
||||
rollout_path: Some(rollout_file.path().to_path_buf()),
|
||||
@@ -1212,7 +1203,6 @@ async fn replayed_reasoning_item_preserves_summary_parts_and_hides_raw_reasoning
|
||||
instruction_source_paths: Vec::new(),
|
||||
reasoning_effort: None,
|
||||
collaboration_mode: None,
|
||||
personality: None,
|
||||
message_history: None,
|
||||
network_proxy: None,
|
||||
rollout_path: None,
|
||||
@@ -1265,7 +1255,6 @@ async fn replayed_reasoning_item_shows_raw_reasoning_when_enabled() {
|
||||
instruction_source_paths: Vec::new(),
|
||||
reasoning_effort: None,
|
||||
collaboration_mode: None,
|
||||
personality: None,
|
||||
message_history: None,
|
||||
network_proxy: None,
|
||||
rollout_path: None,
|
||||
|
||||
@@ -787,7 +787,6 @@ async fn required_windows_sandbox_setup_defers_configured_initial_prompt() {
|
||||
instruction_source_paths: Vec::new(),
|
||||
reasoning_effort: None,
|
||||
collaboration_mode: None,
|
||||
personality: None,
|
||||
message_history: None,
|
||||
network_proxy: None,
|
||||
rollout_path: Some(PathBuf::new()),
|
||||
@@ -1000,7 +999,6 @@ async fn approvals_popup_navigation_skips_disabled() {
|
||||
ev,
|
||||
AppEvent::CodexOp(Op::OverrideTurnContext {
|
||||
approval_policy: Some(AskForApproval::OnRequest),
|
||||
personality: None,
|
||||
..
|
||||
})
|
||||
)),
|
||||
@@ -1011,7 +1009,6 @@ async fn approvals_popup_navigation_skips_disabled() {
|
||||
ev,
|
||||
AppEvent::CodexOp(Op::OverrideTurnContext {
|
||||
approval_policy: Some(AskForApproval::Never),
|
||||
personality: None,
|
||||
..
|
||||
})
|
||||
)),
|
||||
@@ -1232,7 +1229,6 @@ async fn permissions_selection_marks_auto_review_current_after_session_configure
|
||||
instruction_source_paths: Vec::new(),
|
||||
reasoning_effort: None,
|
||||
collaboration_mode: None,
|
||||
personality: None,
|
||||
message_history: None,
|
||||
network_proxy: None,
|
||||
rollout_path: Some(PathBuf::new()),
|
||||
@@ -1287,7 +1283,6 @@ async fn permissions_selection_marks_auto_review_current_with_custom_workspace_w
|
||||
instruction_source_paths: Vec::new(),
|
||||
reasoning_effort: None,
|
||||
collaboration_mode: None,
|
||||
personality: None,
|
||||
message_history: None,
|
||||
network_proxy: None,
|
||||
rollout_path: Some(PathBuf::new()),
|
||||
@@ -1405,7 +1400,6 @@ async fn permissions_selection_sends_approvals_reviewer_in_override_turn_context
|
||||
summary: None,
|
||||
service_tier: None,
|
||||
collaboration_mode: None,
|
||||
personality: None,
|
||||
}
|
||||
);
|
||||
|
||||
|
||||
@@ -33,7 +33,6 @@ fn plan_test_session(thread_id: ThreadId) -> crate::session_state::ThreadSession
|
||||
instruction_source_paths: Vec::new(),
|
||||
reasoning_effort: Some(ReasoningEffortConfig::default()),
|
||||
collaboration_mode: None,
|
||||
personality: None,
|
||||
message_history: None,
|
||||
network_proxy: None,
|
||||
rollout_path: None,
|
||||
@@ -251,7 +250,6 @@ async fn submit_user_message_with_mode_sets_coding_collaboration_mode() {
|
||||
mode: ModeKind::Default,
|
||||
..
|
||||
}),
|
||||
personality: None,
|
||||
..
|
||||
} => {}
|
||||
other => {
|
||||
@@ -788,7 +786,6 @@ async fn submit_user_message_with_mode_allows_same_mode_during_running_turn() {
|
||||
mode: ModeKind::Plan,
|
||||
..
|
||||
}),
|
||||
personality: None,
|
||||
..
|
||||
} => {}
|
||||
other => {
|
||||
@@ -818,7 +815,6 @@ async fn submit_user_message_with_mode_submits_when_plan_stream_is_not_active()
|
||||
match next_submit_op(&mut op_rx) {
|
||||
Op::UserTurn {
|
||||
collaboration_mode: Some(CollaborationMode { mode, .. }),
|
||||
personality: None,
|
||||
..
|
||||
} => assert_eq!(mode, expected_mode),
|
||||
other => {
|
||||
@@ -1280,7 +1276,6 @@ async fn submit_user_message_emits_structured_plugin_mentions_from_bindings() {
|
||||
instruction_source_paths: Vec::new(),
|
||||
reasoning_effort: Some(ReasoningEffortConfig::default()),
|
||||
collaboration_mode: None,
|
||||
personality: None,
|
||||
message_history: None,
|
||||
network_proxy: None,
|
||||
rollout_path: Some(rollout_file.path().to_path_buf()),
|
||||
|
||||
@@ -4366,7 +4366,6 @@ async fn session_configured_clears_goal_status_footer() {
|
||||
instruction_source_paths: Vec::new(),
|
||||
reasoning_effort: Some(ReasoningEffortConfig::default()),
|
||||
collaboration_mode: None,
|
||||
personality: None,
|
||||
message_history: None,
|
||||
network_proxy: None,
|
||||
rollout_path: Some(rollout_file.path().to_path_buf()),
|
||||
|
||||
@@ -621,7 +621,6 @@ fn session_configured_event(model: &str) -> ThreadSessionState {
|
||||
instruction_source_paths: Vec::new(),
|
||||
reasoning_effort: None,
|
||||
collaboration_mode: None,
|
||||
personality: None,
|
||||
message_history: None,
|
||||
network_proxy: None,
|
||||
rollout_path: Some(PathBuf::new()),
|
||||
|
||||
@@ -8,7 +8,6 @@ use std::path::PathBuf;
|
||||
use codex_app_server_protocol::AskForApproval;
|
||||
use codex_protocol::ThreadId;
|
||||
use codex_protocol::config_types::CollaborationMode;
|
||||
use codex_protocol::config_types::Personality;
|
||||
use codex_protocol::models::ActivePermissionProfile;
|
||||
use codex_protocol::models::PermissionProfile;
|
||||
use codex_utils_absolute_path::AbsolutePathBuf;
|
||||
@@ -53,7 +52,6 @@ pub(crate) struct ThreadSessionState {
|
||||
pub(crate) instruction_source_paths: Vec<PathUri>,
|
||||
pub(crate) reasoning_effort: Option<codex_protocol::openai_models::ReasoningEffort>,
|
||||
pub(crate) collaboration_mode: Option<Box<CollaborationMode>>,
|
||||
pub(crate) personality: Option<Personality>,
|
||||
pub(crate) message_history: Option<MessageHistoryMetadata>,
|
||||
pub(crate) network_proxy: Option<SessionNetworkProxyRuntime>,
|
||||
pub(crate) rollout_path: Option<PathBuf>,
|
||||
|
||||
Reference in New Issue
Block a user