Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
23 changes: 14 additions & 9 deletions crates/goose/src/agents/agent.rs
Original file line number Diff line number Diff line change
Expand Up @@ -1112,15 +1112,20 @@ impl Agent {
let provider = self.provider().await?;
let session_manager = self.config.session_manager.clone();
let session_id = session_config.id.clone();
let manager_for_spawn = session_manager.clone();
tokio::spawn(async move {
if let Err(e) = manager_for_spawn
.maybe_update_name(&session_id, provider)
.await
{
warn!("Failed to generate session description: {}", e);
}
});
let naming_disabled = Config::global()
.get_goose_disable_session_naming()
.unwrap_or(false);
if !naming_disabled {
let manager_for_spawn = session_manager.clone();
tokio::spawn(async move {
if let Err(e) = manager_for_spawn
.maybe_update_name(&session_id, provider)
.await
{
warn!("Failed to generate session description: {}", e);
}
});
}
Comment on lines +1118 to +1128
Copy link

Copilot AI Feb 6, 2026

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This new config-gated branch changes whether a background naming task is spawned, but there’s no test coverage validating that session naming is skipped when the flag is enabled; add a unit/integration test that sets GOOSE_DISABLE_SESSION_NAMING and asserts maybe_update_name is not invoked.

Copilot uses AI. Check for mistakes.

let working_dir = session.working_dir.clone();
Ok(Box::pin(async_stream::try_stream! {
Expand Down
1 change: 1 addition & 0 deletions crates/goose/src/config/base.rs
Original file line number Diff line number Diff line change
Expand Up @@ -967,6 +967,7 @@ config_value!(GOOSE_PROVIDER, String);
config_value!(GOOSE_MODEL, String);
config_value!(GOOSE_PROMPT_EDITOR, Option<String>);
config_value!(GOOSE_MAX_ACTIVE_AGENTS, usize);
config_value!(GOOSE_DISABLE_SESSION_NAMING, bool);
config_value!(GEMINI3_THINKING_LEVEL, String);

/// Load init-config.yaml from workspace root if it exists.
Expand Down
Loading