Repository navigation
feat(chat): archived DMs are unpinned (CHE-1801) - #275
Merged
congvc-dev merged 4 commits intoOct 16, 2026
Merged
Conversation
congvc-dev
marked this pull request as ready for review
October 16, 2026 04:12
congvc-dev
deleted the
agent/x99-claude-sonnet/che-1801-archive-unpins
branch
October 16, 2026 04:12
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Status
Layer L1c of the CHE-1755 stack (stage 1, Addendum A2). Based on
mainatf37d08ba1f61610d2266a05ee3ee4a353bf94157. No predecessor.Author: x99-claude-sonnet (Anthropic). A different-lab reviewer must sign before ready (RGS-1).
Agent-side scope is complete at head
a55221e86f43a8546dfbb4d7c8d7465fe4f41783. Independent review and exact-range OCR are recorded below. Cheese retains the merge gate.Change
SetChatSessionArchived). Unarchive leaves it unpinned.ArchiveContinuedChatSession). The new DM keeps the copied pin.PATCH /api/chat/sessions/{id}/pinwithpinned: trueon an archived DM returns 409. Unpin on an archived DM still succeeds. The guard is in the SQLWHERE, so it holds against a concurrent archive.627_unpin_archived_chat_sessionssetspinned_at = NULLfor archived rows that still carry a pin. The down migration is a no-op because the cleared pins are not recoverable.chat:session:updatedevents for archive and continue now carrypinned, so other open clients drop the pin without a refetch.Conditions
TestContinueChatSessionPreservesPinasserted the old behavior (source keeps its pin). It is changed in its own tests-only commit to expect an unpinned source, as Addendum A2 requires.Evidence
Test-First Gate: commits
1824b8843186ee8d7847f3917eee0d269703c177and6f63a0eea1d0543c7b7de8420e7263b5132ce399hold tests only and fail against the parent code. Commita55221e86f43a8546dfbb4d7c8d7465fe4f41783implements and turns them green.Red output, new tests (
go test ./internal/handler -run <new tests>, parent code):Red output, changed test (
-run TestContinueChatSessionPreservesPin, parent code):Two of the new tests pass on the parent on purpose. They guard that unpin on an archived DM and pin on an active DM keep working.
Green, on the implementation head, X99, throwaway pgvector/pg17:
TestContinueChatSessionPreservesPinpass.go test ./internal/handler -run 'Chat|Pin|Archiv',./cmd/server,./cmd/migrateand./pkg/db/...: ok.go test ./internal/handleronce: one failure,TestUpdateComment_GovernanceFlagOn_ProviderSucceeds_ResponseUnaffected(governance receipt, aRESTY ... context deadline exceededlog). It passes 3 of 3 when run alone. It touches no chat code.go vetandgofmtare clean for the changed files.make sqlcoutput is committed.Review and CI attribution
gpt-6-luna, OpenAI), different-lab from Sonnet/Anthropic. Scoped APPROVE at the unchanged base/head above: CHE-1801 comment01a1418f-9920-7ea5-8c33-a5c27622cee5.01a14188-c5ed-7944-90e9-2cb2301f25d0. Delegation covered all eight changed files with zero exclusions. No P0/P1 remains.cmd/serverfailures remain historical evidence. The green rerun is not a waiver.ON DELETE SET NULL. PR feat(chat): archived DMs are unpinned (CHE-1801) #275 does not change those tests or the sweeper.gemini-3.8-flash-high, Google), independent non-author opposite Sonnet/Anthropic. Signed non-OCR fallback PASS: CHE-1810 comment01a14221-4696-7135-a049-c9abeb802bba.f37d08ba1f61610d2266a05ee3ee4a353bf94157, head758c5cecd0e33dd9cf111e1e658e3f2ffd96e140. Base failed 6/12 full-package-raceruns. The test-only fix passed 6/6. OCR on PR fix(runtime): stop chat-usage test stranding active tasks that flip sweeper tests (CHE-1810) #278 is NOT-RUN/unavailable with a recorded fallback, not a clean OCR result.Changelog: none
Closes CHE-1801