Skip to content

Conversation

@gtrrz-victor
Copy link
Contributor

@gtrrz-victor gtrrz-victor commented Feb 6, 2026

No prev sessions:
image

With prev sessions:
image


Note

Medium Risk
Changes hook output and the concurrent-session strategy interface, which can affect agent hook behavior and any downstream implementations relying on the old warning/disable flag.

Overview
Adds a session-start informational message that always tells users the conversation will be linked to the next commit, and (for strategies implementing ConcurrentSessionChecker) appends a count of other active conversations in the same workspace.

Removes the old multi-session conflict warning flow: deletes the --disable-multisession-warning enable flag and related settings helpers, replaces the strategy interface method from returning a conflicting session to returning a count, and updates/refactors hook JSON response handling and integration tests to match the new behavior.

Written by Cursor Bugbot for commit 564c989. This will update automatically on new commits. Configure here.

@gtrrz-victor gtrrz-victor requested a review from a team as a code owner February 6, 2026 03:26
Copilot AI review requested due to automatic review settings February 6, 2026 03:26
Copy link
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

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

Pull request overview

This PR refactors the concurrent session detection feature from a blocking warning system to an informational message system. Instead of warning users and asking them to make a choice when multiple sessions are active, the session-start hook now always displays an informational message that Entire is enabled, with an optional count of other concurrent conversations when applicable. The PR also removes the --disable-multisession-warning flag and all associated configuration options.

Changes:

  • Changed ConcurrentSessionChecker interface from returning session state to returning a count
  • Updated session-start hook to always show "Powered by Entire" message with optional concurrent session count
  • Removed --disable-multisession-warning flag and all related configuration handling
  • Updated tests to verify informational messages instead of warning prompts

Reviewed changes

Copilot reviewed 9 out of 9 changed files in this pull request and generated 2 comments.

Show a summary per file
File Description
cmd/entire/cli/strategy/strategy.go Updated ConcurrentSessionChecker interface to return count instead of session state
cmd/entire/cli/strategy/manual_commit_session.go Renamed method from HasOtherActiveSessionsWithCheckpoints to CountOtherActiveSessionsWithCheckpoints and changed return type
cmd/entire/cli/setup.go Removed --disable-multisession-warning flag and all configuration handling for it
cmd/entire/cli/settings/settings.go Removed IsMultiSessionWarningDisabled() helper method
cmd/entire/cli/hooks.go Replaced warning logic with informational message that always shows, optionally including concurrent session count
cmd/entire/cli/config.go Removed IsMultiSessionWarningDisabled() helper function
cmd/entire/cli/integration_test/session_conflict_test.go Updated tests to verify informational messages and added new test for no-concurrent-sessions case
cmd/entire/cli/manual_commit_test.go Updated comment to be more generic after checkConcurrentSessions removal
cmd/entire/cli/setup_test.go Updated test function calls to remove disableMultisessionWarning parameter

@khaong khaong merged commit d746f95 into main Feb 6, 2026
4 checks passed
@khaong khaong deleted the gtrrz-victor/prompt-entire-enable-and-multi-session branch February 6, 2026 03:51
toothbrush added a commit that referenced this pull request Feb 6, 2026
Entire-Checkpoint: 1b8e9b9a1c07
toothbrush added a commit that referenced this pull request Feb 6, 2026
* Strict settings parsing

  1. loadFromFile - Now uses json.NewDecoder with DisallowUnknownFields() instead of json.Unmarshal
  2. mergeJSON - Added strict validation at the start that decodes into a temp struct with DisallowUnknownFields() before doing the field-by-field merge

  Also added settings_test.go with three tests:
  - TestLoad_RejectsUnknownKeys - verifies main settings file rejects unknown keys
  - TestLoad_AcceptsValidKeys - verifies all valid keys are accepted
  - TestLoad_LocalSettingsRejectsUnknownKeys - verifies local override file also rejects unknown keys

Entire-Checkpoint: c4a4c0bba140

* All lint issues fixed and tests pass.

Changes made:
  - Removed output_filter from test JSON and assertions (field was removed from struct)
  - Replaced os.Chdir() with t.Chdir() which handles cleanup automatically

Entire-Checkpoint: b703660e28ea

* more strict settings parsing.

* Unify settings parsing to single source of truth

Previously, settings were parsed in three separate places:
- settings/settings.go (the dedicated package)
- config.go (duplicated EntireSettings struct and Load/Save logic)
- strategy/hooks.go and push_common.go (ad-hoc JSON parsing)

This consolidates all settings parsing into the settings package:

1. settings/settings.go now contains:
   - The canonical EntireSettings struct
   - Load(), Save(), SaveLocal(), LoadFromFile() functions
   - Helper methods: IsSummarizeEnabled(), IsMultiSessionWarningDisabled(),
     IsPushSessionsDisabled()

2. config.go now delegates to settings package:
   - EntireSettings is a type alias to settings.EntireSettings
   - LoadEntireSettings() calls settings.Load()
   - SaveEntireSettings() calls settings.Save()
   - Removed ~200 lines of duplicated parsing code

3. strategy/hooks.go:
   - isLocalDev() now uses settings.Load().LocalDev
   - Removed ad-hoc JSON parsing

4. strategy/push_common.go:
   - isPushSessionsDisabled() now uses settings.Load().IsPushSessionsDisabled()
   - Removed readPushSessionsFromFile() and 50+ lines of ad-hoc parsing

Benefits:
- Single place to update when adding new settings fields
- Consistent strict parsing (DisallowUnknownFields) everywhere
- Easier to maintain and test

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>

* Update cmd/entire/cli/settings/settings_test.go

Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>

* don't hand-roll strings.Contains

Entire-Checkpoint: d9e47174f862

* Sigh, these re-exports are to avoid renaming a million 'settings' variables.

Entire-Checkpoint: d82cce910879

* IsMultiSessionWarningDisabled: removed in #161.

Entire-Checkpoint: 1b8e9b9a1c07

---------

Co-authored-by: Claude Opus 4.5 <noreply@anthropic.com>
Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Development

Successfully merging this pull request may close these issues.

2 participants