Repository navigation
Conversation
ApprovabilityVerdict: Approved at Macroscope's review found this PR approvable — This is a focused server-side bug fix that preserves canonical Codex titles, repairs only recognized legacy placeholders, and protects repairs from concurrent renames or regeneration. The new file reads and command fields are bounded and backward-compatible, with extensive regression coverage. You can add or adjust custom eligibility rules. Learn more. |
|
Navigate logical layers of code changes, visualize relationships, and explore their blast radius. No actionable comments were generated in the recent review. 🎉 ℹ️ Recent review info⚙️ Run configurationConfiguration used: Repository: pingdotgg/t3code/.coderabbit.yaml Review profile: CHILL Plan: Advanced Run ID: 📒 Files selected for processing (8)
Included review availability: This review used your included allowance. Your plan provides up to 10 included reviews per hour; 9 remain after this review. 📝 WalkthroughWalkthroughCodex imports now use session-index titles or derive titles from transcript content. Eligible legacy imported threads can be renamed using guarded metadata updates that reject stale title or regeneration-request values. ChangesCodex title discovery
Guarded legacy title repair
Priority: ➖ Normal Estimated code review effort: 3 (Moderate) | ~25 minutes Change: Bug fix · Severity of issue fixed: Medium Sequence Diagram(s)sequenceDiagram
participant AgentSessionScanner
participant AgentSessionImporter
participant Orchestrator
AgentSessionScanner->>AgentSessionImporter: provide canonical title or imported thread
AgentSessionImporter->>Orchestrator: dispatch guarded metadata update
Suggested reviewers: Merge Risk: ⚪ Minimal · up to Codex import titles and guarded legacy-title repair have no identified merge-blocking issue. The change is ready to merge after normal checks. Security Architecture ReviewSecurity architecture risk: 🔵 Low · up to The change is limited to imported chat titles and adds safeguards against concurrent renaming and title generation. No privilege expansion or new security vulnerability was established. Commit-time provider eligibility and broader integration coverage remain partly unresolved. Retained concerns Security review detailsSecurity Blast Radius
Trust Boundaries and Controls
Resilience and Maintainability Implications
Hardening Proposals
🚥 Pre-merge checks | ✅ 4 | ❌ 1❌ Failed checks (1 warning)
✅ Passed checks (4 passed)
✨ Finishing Touches🧪 Generate unit tests (beta)
Comment |
Problem
Importing a Codex session whose first user record contains injected setup can still name the thread
<recommended_plugins>,<environment_context>, or an AGENTS instruction heading on Orchestrator V2. Codex shows the saved chat name for the same session. Existing imports retain those placeholders when their transcripts have not changed.Change
Read the configured Codex home's
session_index.jsonland prefer its saved title, matched by the authoritative session ID from transcript metadata. Reads are bounded to 16 MiB and 5,000 index entries; malformed or unavailable indexes fall back to the first actual user request after recognized leading Codex context. Imported message text is preserved.Repair recognized placeholders on existing imports through V2's normal metadata command. Two optional command preconditions protect concurrent manual renames and title regeneration. Repair failures leave import bookkeeping intact. Eligibility checks preserve custom titles and exclude other projects, provider instances, deleted threads, and native V2 history. Normal V2 metadata updates advance the thread's metadata timestamp; conversation and settled timestamps remain unchanged.
Scope and approval
Closes #10513, the accepted bug report.
Replaces #11919 after the maintainer requested a fresh implementation on current V2 main. Rebuilt on
bf7121d; the V1 dispatch and projection APIs from the old PR are not used.Verification
Node 24.19.0 on macOS. Regression tests reproduced wrong canonical/fallback titles and unsafe stale title writes before the fixes.
vp test run apps/server/src/project/AgentSessionScanner.test.ts: 95 passed; the existingexcludes sandboxes reached through a symlink into the worktrees dirtest fails identically on clean baseb4d3d51on this machine. Independent diagnosis confirmed that macOS resolves the candidate from/var/folders/...to/private/var/folders/..., while configured exclusion roots retain/var/...; that pre-existing path-canonicalization mismatch is outside this title fix. No test was disabled or changed to hide the failure. New title/index/context regressions passed, including filename/session-ID disagreement, account isolation, malformed/duplicate entries, index growth, and preserved history.vp test run apps/server/src/project/AgentSessionImporter.test.ts apps/server/src/orchestration-v2/Orchestrator.control-reads.test.ts apps/server/src/orchestration-v2/ThreadTitleRegenerationService.test.ts packages/contracts/src/orchestrationV2.test.ts: 66 passed. Covers existing-import repair, manual-title preservation, regeneration and rename races, and continued tracking after repair failure.tsc --noEmitfor server and contracts: passed.Orchestrator.ts.Implemented with GPT-6.1-Sol through the Codex harness in T3 Code.