Skip to content

Stop injecting Basecamp context into every session - #675

Open
almirsarajcic wants to merge 1 commit into
basecamp:mainfrom
almirsarajcic:fix/no-global-session-context
Open

Stop injecting Basecamp context into every session#675
almirsarajcic wants to merge 1 commit into
basecamp:mainfrom
almirsarajcic:fix/no-global-session-context

Conversation

@almirsarajcic

@almirsarajcic almirsarajcic commented Sep 2, 2026

Copy link
Copy Markdown

Problem

Installing and trusting the Basecamp plugin registers an unconditional SessionStart hook. Every new Codex or Claude Code session then receives:

Basecamp is active and OAuth is ready. Use the Basecamp skills for project work.

That context is injected even in repositories and conversations unrelated to Basecamp. It can steer the agent toward Basecamp simply because the plugin is installed.

This is separate from normal skill discovery: the Basecamp skill should remain available for natural-language requests and explicit references.

Change

  • Remove only the unconditional SessionStart hook from the shared plugin manifest.
  • Keep the silent commit-reference hooks (PreToolUse, PostToolUse, and PostToolUseFailure).
  • Update the Codex setup docs to describe those remaining hooks accurately.
  • Add a regression assertion preventing SessionStart from returning to the plugin hook manifest.

No .basecamp/config.json is required to activate the skill. Codex can continue selecting it when a request is relevant.

Verification

  • go test ./internal/release
  • go test ./internal/commands -run TestRunCodexSetupInteractiveExplainsNextSteps -count=1
  • git diff --check
  • Full make check passed vet, lint, Actionlint, and zizmor, then hit pre-existing terminal-detection failures because the Codex command runner is not recognized as an interactive terminal.

Summary by cubic

Removes the unconditional SessionStart hook so Basecamp no longer injects context into every Codex or Claude Code session. The Basecamp skill stays available for relevant requests and explicit references.

Details

  • Keeps the silent commit-reference hooks (PreToolUse, PostToolUse, PostToolUseFailure).
  • Updates Codex setup docs to describe the remaining hooks accurately.
  • Adds a regression assertion preventing SessionStart from returning to the hook manifest.

Written for commit 9b6cf0d. Summary will update on new commits.

Review in cubic

Copilot AI balanced review requested due to automatic review settings September 2, 2026 06:32
@github-actions github-actions Bot added commands CLI command implementations tests Tests (unit and e2e) docs labels Sep 2, 2026

Copilot AI left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

🟢 Approval recommended

The reviewed changes have no unresolved approval-blocking issues.

Pull request overview

Removes unconditional Basecamp context injection while retaining skill discovery and commit-reference hooks.

Changes:

  • Removes the SessionStart hook.
  • Updates Codex setup guidance.
  • Adds regression coverage preventing its restoration.
File summaries
File Description
README.md Clarifies Codex hook and skill behavior.
internal/release/manifests_test.go Prevents SessionStart from returning.
internal/commands/wizard_codex.go Removes obsolete hook commentary.
internal/commands/wizard_codex_test.go Updates setup guidance test commentary.
install.md Updates Codex installation guidance.
hooks/hooks.json Removes unconditional session context injection.
Review details
  • Files reviewed: 6/6 changed files
  • Comments generated: 0
  • Review effort level: Balanced

💡 Add a code-review agent skill or configure MCP servers for context-aware, tailored reviews. Learn more in the docs.

@cubic-dev-ai cubic-dev-ai Bot left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

No issues found across 6 files

Re-trigger cubic

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

commands CLI command implementations docs tests Tests (unit and e2e)

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants