Skip to content

fix(profiles): apply startup profile to named sessions - #3584

Merged
barbatdev merged 2 commits into
mainfrom
fix/3417-bug-profiles-a-session-started-with-name
Nov 27, 2026
Merged

barbatdev merged 2 commits into
mainfrom
fix/3417-bug-profiles-a-session-started-with-name

Conversation

@barbatdev

@barbatdev barbatdev commented Nov 26, 2026 •

Copy link
Copy Markdown
Contributor

Refs #3417

Summary

  • Ignore session_info when determining whether a session is starting fresh, so --name does not suppress the worktree profile switch or startup notice.
  • Keep the existing guards against reapplying the startup profile to conversations with history, resumed sessions, or forks.

Verification

  • Session profile extension suite: 56 passed, including the regression (failed before the fix).
  • Isolated CLI smoke test: named and unnamed sessions both applied and announced the same worktree profile and thinking level.
  • Typecheck, runtime module check, package resource verification, and packed-package E2E passed.
  • Local pnpm test was not green: the relay test failed identically on base and candidate with inherited homes and passed on both with isolated homes; the background-job notification test failed in the full run and passed in isolation on both. GitHub Actions results are pending.

Summary by CodeRabbit

  • Bug Fixes
    • Fresh named sessions now correctly recognize repository profile pins, apply the selected profile’s orchestrator, and announce it. Session metadata no longer prevents startup model or thinking-level changes from being treated as permitted startup changes.

@coderabbitai

coderabbitai Bot commented Nov 26, 2026 •

Copy link
Copy Markdown

Explain Change →

Important

Review skipped

Review was skipped as selected files did not have any reviewable changes.

Run configuration

  • Source mode: Auto
  • Repository: Unavailable
  • Branch: Unavailable
  • File: No configuration file from this repository applied
  • Commit: Unavailable
  • Layers: Repository UI
  • Review profile: ASSERTIVE
  • Plan: Advanced
  • Run ID: 35bb7ee4-c352-4a7a-92d3-d70cee4472a9
Commits

Reviewing files that changed from the base of the PR and between b9732ce and 5e23bbb.

You can disable this status message by setting the reviews.review_status to false in the CodeRabbit configuration file.

Use the checkbox below for a quick retry:

  • Trigger review

No actionable comments were generated in the recent review.

Walkthrough

The own-start check now ignores session_info entries. Tests add named-session fixture support and verify that a repository profile pin applies and announces the selected profile for a fresh named session.

Changes: Profile startup

Layer / File(s) Summary
Named session own-start and profile test
extensions/gentle-ai.ts, tests/session-profile-extension.test.ts
isSessionOwnStart skips session_info entries. The test fixture accepts a session name, and tests cover profile selection and announcement for a fresh named session. The existing-session startup test now uses a name.

Estimated code review effort: 2 (Simple) | ~7 minutes

Change: Bug fix

Possibly related issues

Suggested reviewers: alan-thegentleman, decode2

Merge Risk: Minimal · previous review b9732

Named sessions now apply and announce the worktree profile the same way unnamed sessions do. The change is small and has a regression test, so the risk of merging is minimal.

Pre-merge checks: Passed 4

Check name Status Explanation
Description Check Passed Check skipped - CodeRabbit’s high-level summary is enabled.
Title check Passed The title "fix(profiles): apply startup profile to named sessions" matches the main change. The change makes the session extension ignore session_info entries when deciding whether a session is fresh.…
Linked Issues check Passed Check skipped because no linked issues were found for this pull request.
Out of Scope Changes check Passed Check skipped because no linked issues were found for this pull request.
Full details: Title check

Explanation

The title "fix(profiles): apply startup profile to named sessions" matches the main change. The change makes the session extension ignore session_info entries when deciding whether a session is fresh. As a result, starting a session with a name still applies the startup profile and announces its orchestrator. The added regression test covers a fresh named session with a repository profile pin.

Finishing Touches

Generate unit tests (beta)

  • Commit to this branch
  • Create a new PR
  • Autofix · Keep fixing CodeRabbit findings and required CI, and resolving merge conflicts
Recent review info

Run configuration

  • Source mode: Auto
  • Repository: Unavailable
  • Branch: Unavailable
  • File: No configuration file from this repository applied
  • Commit: Unavailable
  • Layers: Repository UI
  • Review profile: ASSERTIVE
  • Plan: Advanced
  • Run ID: a29d99f1-cc9b-4456-9e6d-7116a34746ed
Commits

Reviewing files that changed from the base of the PR and between d4c88c7 and b9732ce.

Files selected for processing: 2

  • extensions/gentle-ai.ts
  • tests/session-profile-extension.test.ts

Included review availability: This review used your included allowance. Your plan provides up to 8 included reviews per hour; 7 remain after this review.

@barbatdev
barbatdev merged commit c9b59ea into main Nov 27, 2026
10 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant