Libra CodeHub

CedarCopilot/cedar-mail

Branch: staging

Tasks board drag, draft identity, Slack health, 2FA policy, calendar tab icon

merged#2633CedarCopilot

CedarCopilot wants to merge 5 commits into staging from feat/calendar-tab-icon

Live on prod, no production signal yetTimeline and evidence
  1. Opened
    Aug 31, 2026, 1:43 AM
  2. Merged
    Aug 31, 2026, 10:09 AM
  3. Live on staging
    Aug 31, 2026, 10:09 AM
  4. Live on prod
    Aug 31, 2026, 10:09 AM
  5. Observed 0 hours
    Aug 31, 2026, 10:09 AM
  6. Unobserved

    Live on prod, no production signal yet

    Aug 31, 2026, 10:09 AM
  7. Pipelines steady after this deploy
    Aug 31, 2026, 10:09 AM
  8. Pipelines steady after this deploy
    Aug 31, 2026, 10:09 AM
  9. Aug 31, 2026, 10:44 AM

Behaviors Libra is checking

Slack integration behavior from timeline/SlackThreadDisplay.tsx, cron/process-buffered-slack-webhook-events.ts, slack/slack-connection-health.ts keeps working in staging.Degradedlow confidence

Strict CloudWatch fallback found 3 recent prod failure log lines for [processIncomingSlackChannelData] Error processing channel (No valid connection tokens found for user <id>), but the same failure had 4 log lines in the comparable pre-deploy baseline. Libra is not blaming.

staging, checked Sep 3, 2026, 9:41 AM
Authentication and access behavior from lib/auth-providers.ts, lib/auth.ts, drafting/draft-session-store.ts keeps working in staging.Inconclusivelow confidence

Strict CloudWatch fallback found 3 recent prod failure log lines for [processIncomingSlackChannelData] Error processing channel (No valid connection tokens found for user <id>), but the same failure had 4 log lines in the comparable pre-deploy baseline. Libra is not blaming.

staging, checked Sep 2, 2026, 10:42 AM
Calendar sync behavior from calendar/page.tsx, hooks/use-calendar-favicon.ts, calendar/day-1.svg keeps working in staging.Inconclusivelow confidence

Strict CloudWatch fallback saw 1,446 success-shaped log lines matching calendar, meeting, meetings, but no tied operation was present, so Libra is not calling this working.

staging, checked Sep 2, 2026, 11:42 AM
Chat workflow behavior from chat/ChatDropZone.tsx keeps working in staging.Inconclusivelow confidence

Verification reached its 120s wall-clock budget before a tied verdict. Libra is keeping this intent verifying until the next check.

staging, checked Sep 2, 2026, 12:44 PM
CRM integration behavior from crm/conversations.ts, routes/crm.ts keeps working in staging.Inconclusivelow confidence

Strict CloudWatch fallback saw 776 success-shaped log lines matching crm, hubspot, salesforce, deal, deals, but no tied operation was present, so Libra is not calling this working.

staging, checked Sep 2, 2026, 1:42 PM
Data model behavior from migrations/user_tasks_sort_order.sql keeps working in staging.Inconclusivelow confidence

Verification reached its 120s wall-clock budget before a tied verdict. Libra is keeping this intent verifying until the next check.

staging, checked Sep 2, 2026, 2:44 PM

Failures attributed to this change

No prod customers are affected while this is only in staging. If promoted, prod impact is unknown because Libra still needs a concrete exception, route, and failed user action before assigning severity. 4 hits · no retained affected-user count · no retained trace sample.Introducedmedium confidence

internal_only

staging, first seen Aug 31, 2026, 10:51 AM
No prod customers are affected while this is only in staging. If promoted, prod impact is unknown because Libra still needs a concrete exception, route, and failed user action before assigning severity. 4 hits · no retained affected-user count · no retained trace sample.Introducedmedium confidence

internal_only

staging, first seen Aug 31, 2026, 11:36 AM

Libra has verdicts on 0 of 8 tracked behaviors on prod; 8 are still being checked. Libra checks hourly for 3 days after each deploy.

Summary

A broad branch across the task board, drafting, integrations and auth. Highlights:

  • Task board drag-and-drop , Linear's two gestures (drop files the card; hold ⌘ to place it). The drop lane and slot are resolved from the raw pointer against lane rects and midpoints captured on entry, deliberately not from dnd-kit's over, whose collision detection resolves against droppables this component's own output moves. Escape abandons the drag. Board sort_order gains a concurrency-safe placement trigger plus a headless audit/repair/stress CLI.
  • Draft identity , a draft gets one identity across pods via a durable draftSessionId ↔ draftId store, and a body fingerprint so the agent can tell its own draft from one the rep has edited. Sends sweep the sibling drafts they obsolete; deleting the last draft on a thread retires the thread.
  • Slack connection health , the rep is told once, on the worked→broke transition, with the edge claimed in SQL so concurrent drains cannot double-send.
  • 2FA , enforcement moves off a hardcoded user-id list onto TWO_FACTOR_REQUIRED_USER_IDS, and the settings page is reachable again.
  • Drive , drive.readonly is withheld from new consent screens pending Google's restricted-scope verification, without downgrading users who already granted it.
  • Chat composer , rebuilt controls, one meaning for "New chat", and a send/stop/queue glyph that is static SVG geometry rather than an animated morph.
  • Calendar tab icon , the favicon shows today's date.

Review fixes in this branch

A pre-merge review found and this branch fixes:

  • The drop path stopped calling endDrag, so every successful drop left the board live , re-arranging itself under a mouse with no button held.
  • putDraftSession replaced rather than merged, so a rep's first save erased the agent's body fingerprint; matchesRecordedAgentBody fails open on a record with no hash, so the next run would rewrite their edits in place. Now merged, asserted in both writer orders.
  • Eight failing tests: three tRPC suites whose vi.mock('@/trpc/trpc') did not export the newly-imported cedarAdminProcedure, and a ComposerActionButton suite still asserting the removed framer-motion implementation.
  • Dead code left by the drag rewrite (resolveDropColumn, placeDroppedCard), an orphaned doc comment, and an oxlint no-useless-spread denial in the new sort-order CLI verb.

Test plan

  • pnpm run autofix:local green on the merged tree: oxlint --deny-warnings, deps:check, 312 mail suites / 2,943 tests, 764 server files / 8,364 tests.
  • pnpm --filter @zero/mail run types and pnpm --filter @zero/server run types both clean.
  • Merged origin/staging; resolved an import conflict in integrations.ts and a semantic conflict where both sides had independently fixed taskUpdated placement carrying , staging's version kept, ours removed.

🤖 Generated with Claude Code

Greptile Summary

The PR adds task-board ordering, durable draft identity, Slack health notifications, environment-driven 2FA policy, Drive consent changes, chat-composer updates, and calendar favicons. The current fixes still leave:

  • concurrent first draft saves able to create duplicate provider drafts;
  • destination placement affected by unrelated task groups;
  • Slack lapse claims vulnerable to duplicate delivery and stale completion.

Confidence Score: 2/5

The PR does not appear safe to merge until duplicate draft creation, task misplacement, and non-exclusive Slack notification claims are fixed.

Concurrent first saves can still create separate provider drafts before publishing their shared identity, task placement collision checks include unrelated lanes, and Slack's provisional claim remains immediately reclaimable by concurrent drains while its completion update can stamp a newer lapse.

Files Needing Attention: apps/server/src/services/mail/sen

Show production surfaces and changed-file mapping

Production surfaces

Libra has not measured any production surfaces for this change yet.

Changed files → surfaces

  • apps/mail/app/(auth)/login/login-client.tsxno production surface mapped
  • apps/mail/app/(auth)/two-factor/two-factor-client.tsxno production surface mapped
  • apps/mail/app/(routes)/calendar/page.tsxno production surface mapped
  • apps/mail/app/(routes)/layout.tsxno production surface mapped
  • apps/mail/app/(routes)/settings/general/page.tsxno production surface mapped
  • apps/mail/app/(routes)/settings/security/page.tsxno production surface mapped
  • apps/mail/app/root.tsxno production surface mapped
  • apps/mail/atoms/chatAtoms.tsno production surface mapped
  • apps/mail/components/icons/icons.tsxno production surface mapped
  • apps/mail/components/ui/citations/TranscriptViewerModal.tsxno production surface mapped
  • apps/mail/components/ui/citations/quote-match.tsno production surface mapped
  • apps/mail/components/ui/citations/useMarkHighlight.tsno production surface mapped
  • apps/mail/components/ui/option-picker.tsxno production surface mapped
  • apps/mail/config/shortcuts.tsno production surface mapped
  • apps/mail/docs/chat-lifecycle.mdno production surface mapped
  • apps/mail/docs/wiki/task-board-data-flow.mdno production surface mapped
  • apps/mail/lib/hotkeys/global-hotkeys.tsxno production surface mapped
  • apps/mail/lib/site-config.tsno production surface mapped
  • apps/mail/modules/auth/components/two-factor-setup.tsxno production surface mapped
  • apps/mail/modules/calendar/hooks/use-calendar-favicon.tsno production surface mapped
  • apps/mail/modules/cedar-os/__tests__/chatInput/ComposerActionButton.test.tsxno production surface mapped
  • apps/mail/modules/cedar-os/src/cedar-os-components/chatComponents/EmbeddedCedarChat.tsxno production surface mapped
  • apps/mail/modules/cedar-os/src/cedar-os-components/chatComponents/newChatWithSameContext.tsno production surface mapped
  • apps/mail/modules/cedar-os/src/cedar-os-components/chatComponents/startNewChat.tsno production surface mapped
  • apps/mail/modules/cedar-os/src/cedar-os-components/chatComponents/welcomeShortcuts.tsno production surface mapped
  • apps/mail/modules/cedar-os/src/cedar-os-components/chatInput/ChatInput.tsxno production surface mapped
  • apps/mail/modules/cedar-os/src/cedar-os-components/chatInput/ComposerActionButton.tsxno production surface mapped
  • apps/mail/modules/cedar-os/src/cedar-os-components/chatInput/ReasoningEffortPicker.tsxno production surface mapped
  • apps/mail/modules/cedar-os/src/components/chatInput/slashCommands.tsno production surface mapped
  • apps/mail/modules/cedar-os/src/components/chatInput/useCedarEditor.tsno production surface mapped
  • apps/mail/modules/cedar-os/src/components/renderers/messageRenderers.tsxno production surface mapped
  • apps/mail/modules/cedar-os/src/store/agentConnection/responseProcessors/clientExecutionResponseProcessors.tsno production surface mapped
  • apps/mail/modules/cedar-os/src/store/messages/messageStorage.tsno production surface mapped
  • apps/mail/modules/cedar-os/src/store/messages/messagesSlice.tsno production surface mapped
  • apps/mail/modules/conversations/components/LeftSidebarContent.tsxno production surface mapped
  • apps/mail/modules/conversations/components/files/ConversationFileTree.tsxno production surface mapped
  • apps/mail/modules/conversations/components/files/DriveSection.tsxno production surface mapped
  • apps/mail/modules/conversations/components/files/FilesTab.tsxno production surface mapped
  • apps/mail/modules/conversations/components/timeline/EventDetailDialog.tsxno production surface mapped
  • apps/mail/modules/conversations/components/timeline/SlackThreadDisplay.tsxno production surface mapped
  • apps/mail/modules/conversations/utils/findOpenEmptyChat.tsno production surface mapped
  • apps/mail/modules/documents/recording/MeetingRecordingPlayer.tsxno production surface mapped
  • apps/mail/modules/documents/table/CellDisplay.tsxno production surface mapped
  • apps/mail/modules/documents/table/TableColumnMenu.tsxno production surface mapped
  • apps/mail/modules/documents/table/TypedCells.tsxno production surface mapped
  • apps/mail/modules/documents/table/constants.tsno production surface mapped
  • apps/mail/modules/drafting/components/email-composer.tsxno production surface mapped
  • apps/mail/modules/drafting/components/extensions.tsno production surface mapped
  • apps/mail/modules/files/components/chat/ChatDropZone.tsxno production surface mapped
  • apps/mail/modules/integrations/drive-reauth-card.tsxno production surface mapped
  • apps/mail/modules/meetings/detail/MeetingDetailView.tsxno production surface mapped
  • apps/mail/modules/meetings/detail/meeting-detail-model.tsno production surface mapped
  • apps/mail/modules/meetings/detail/meeting-sections.tsno production surface mapped
  • apps/mail/modules/meetings/detail/transcript-lines.tsno production surface mapped
  • apps/mail/modules/threads/threadList/store/__tests__/markDraftAsUserEdited.test.tsno production surface mapped
  • apps/mail/modules/threads/threadList/store/__tests__/mergeDraftsByUserEdited.test.tsno production surface mapped
  • apps/mail/modules/threads/threadList/store/threadSlice.tsno production surface mapped
  • apps/mail/modules/userSettings/components/two-factor-settings.tsxno production surface mapped
  • apps/mail/modules/userTasks/TASK_KANBAN_DESIGN.mdno production surface mapped
  • apps/mail/modules/userTasks/TASK_REORDERING_DESIGN.mdno production surface mapped
  • apps/mail/modules/userTasks/TASK_REORDERING_HANDOFF.mdno production surface mapped
  • apps/mail/modules/userTasks/components/TaskKanbanBoard.tsxno production surface mapped
  • apps/mail/modules/userTasks/components/TaskKanbanCard.tsxno production surface mapped
  • apps/mail/modules/userTasks/components/TaskKanbanColumn.tsxno production surface mapped
  • apps/mail/modules/userTasks/components/TaskListView.tsxno production surface mapped
  • apps/mail/modules/userTasks/components/TaskTicketView.tsxno production surface mapped
  • apps/mail/modules/userTasks/components/TasksToolbar.tsxno production surface mapped
  • apps/mail/modules/userTasks/hooks/use-meta-key-held.tsno production surface mapped
  • apps/mail/modules/userTasks/hooks/use-optimistic-task-actions.tsno production surface mapped
  • apps/mail/modules/userTasks/hooks/use-task-group-buckets.tsno production surface mapped
  • apps/mail/modules/userTasks/hooks/use-task-list-view-options.tsno production surface mapped
  • apps/mail/modules/userTasks/lib/resolve-tasks-on-send.tsno production surface mapped
  • apps/mail/modules/userTasks/lib/task-send-match.tsno production surface mapped
  • apps/mail/modules/userTasks/lib/task-status-cache.tsno production surface mapped
  • apps/mail/modules/userTasks/utils/task-drop-plan.tsno production surface mapped
  • apps/mail/modules/userTasks/utils/task-order.tsno production surface mapped
  • apps/mail/package.jsonno production surface mapped
  • apps/mail/public/icons/calendar/day-1.svgno production surface mapped
  • apps/mail/public/icons/calendar/day-10.svgno production surface mapped
  • apps/mail/public/icons/calendar/day-11.svgno production surface mapped
  • apps/mail/public/icons/calendar/day-12.svgno production surface mapped
  • apps/mail/public/icons/calendar/day-13.svgno production surface mapped
  • apps/mail/public/icons/calendar/day-14.svgno production surface mapped
  • apps/mail/public/icons/calendar/day-15.svgno production surface mapped
  • apps/mail/public/icons/calendar/day-16.svgno production surface mapped
  • apps/mail/public/icons/calendar/day-17.svgno production surface mapped
  • apps/mail/public/icons/calendar/day-18.svgno production surface mapped
  • apps/mail/public/icons/calendar/day-19.svgno production surface mapped
  • apps/mail/public/icons/calendar/day-2.svgno production surface mapped
  • apps/mail/public/icons/calendar/day-20.svgno production surface mapped
  • apps/mail/public/icons/calendar/day-21.svgno production surface mapped
  • apps/mail/public/icons/calendar/day-22.svgno production surface mapped
  • apps/mail/public/icons/calendar/day-23.svgno production surface mapped
  • apps/mail/public/icons/calendar/day-24.svgno production surface mapped
  • apps/mail/public/icons/calendar/day-25.svgno production surface mapped
  • apps/mail/public/icons/calendar/day-26.svgno production surface mapped
  • apps/mail/public/icons/calendar/day-27.svgno production surface mapped
  • apps/mail/public/icons/calendar/day-28.svgno production surface mapped
  • apps/mail/public/icons/calendar/day-29.svgno production surface mapped
  • apps/mail/public/icons/calendar/day-3.svgno production surface mapped
  • apps/mail/public/icons/calendar/day-30.svgno production surface mapped
  • apps/mail/public/icons/calendar/day-31.svgno production surface mapped
  • apps/mail/public/icons/calendar/day-4.svgno production surface mapped
  • apps/mail/public/icons/calendar/day-5.svgno production surface mapped
  • apps/mail/public/icons/calendar/day-6.svgno production surface mapped
  • apps/mail/public/icons/calendar/day-7.svgno production surface mapped
  • apps/mail/public/icons/calendar/day-8.svgno production surface mapped
  • apps/mail/public/icons/calendar/day-9.svgno production surface mapped
  • apps/mail/scripts/geist-bold-digits.jsonno production surface mapped
  • apps/mail/scripts/generate-calendar-favicons.mjsno production surface mapped
  • apps/mail/tests/components/extensions/exit-link-on-space.test.tsno production surface mapped
  • apps/mail/tests/lib/favicon-links.test.tsno production surface mapped
  • apps/mail/tests/modules/auth/twoFactorSetup.test.tsxno production surface mapped
  • apps/mail/tests/modules/chat-store/attachOnDraftChat.test.tsxno production surface mapped
  • apps/mail/tests/modules/chat-store/composerActionButton.test.tsxno production surface mapped
  • apps/mail/tests/modules/chat-store/draftChatOnArrival.test.tsno production surface mapped
  • apps/mail/tests/modules/chat-store/slashCommands.test.tsxno production surface mapped
  • apps/mail/tests/modules/chat-store/startNewChat.test.tsno production surface mapped
  • apps/mail/tests/modules/conversations/filesTabDrive.test.tsxno production surface mapped
  • apps/mail/tests/modules/conversations/filesTabHarness.tsxno production surface mapped
  • apps/mail/tests/modules/conversations/findOpenEmptyChat.test.tsno production surface mapped
  • apps/mail/tests/modules/documents/table/OptionPicker.test.tsxno production surface mapped
  • apps/mail/tests/modules/meetings/meetingSections.test.tsno production surface mapped
  • apps/mail/tests/modules/meetings/transcriptLines.test.tsno production surface mapped
  • apps/mail/tests/modules/userTasks/resolveTasksOnSend.test.tsno production surface mapped
  • apps/mail/tests/modules/userTasks/taskKanbanSorting.test.tsno production surface mapped
  • apps/mail/tests/modules/userTasks/taskOrder.test.tsno production surface mapped
  • apps/mail/tests/modules/userTasks/taskSendMatch.test.tsno production surface mapped
  • apps/mail/tests/modules/userTasks/taskTicketView.test.tsxno production surface mapped
  • apps/mail/tests/modules/userTasks/taskViewOptionsStability.test.tsxno production surface mapped
  • apps/mail/tests/modules/userTasks/upcomingDrop.test.tsno production surface mapped
  • apps/mail/tests/modules/ux/layout/coldLoadArtifactDeepLink.test.tsno production surface mapped
  • apps/server/docs/google-drive-integration.mdno production surface mapped
  • apps/server/docs/wiki/README.mdno production surface mapped
  • apps/server/docs/wiki/task-sort-order.mdno production surface mapped
  • apps/server/src/cli/__tests__/task-groups.test.tsno production surface mapped
  • apps/server/src/cli/task-groups.tsno production surface mapped
  • apps/server/src/container/aws-runtime-bindings.tsno production surface mapped
  • apps/server/src/cron/process-buffered-slack-webhook-events.tsno production surface mapped
  • apps/server/src/db/__tests__/sort-order-audit.test.tsno production surface mapped
  • apps/server/src/db/__tests__/user-tasks-sort-order.test.tsno production surface mapped
  • apps/server/src/db/migrations/user_tasks_sort_order.sqlno production surface mapped
  • apps/server/src/env.tsno production surface mapped
  • apps/server/src/lib/auth-providers.tsno production surface mapped
  • apps/server/src/lib/auth.tsno production surface mapped
  • apps/server/src/lib/driver/google.tsno production surface mapped
  • apps/server/src/lib/two-factor/README.mdno production surface mapped
  • apps/server/src/lib/two-factor/__tests__/policy.test.tsno production surface mapped
  • apps/server/src/lib/two-factor/policy.tsno production surface mapped
  • apps/server/src/mastra/tools/draft-comms/__tests__/saveDraftTool.test.tsno production surface mapped
  • apps/server/src/mastra/tools/draft-comms/saveDraftTool.tsno production surface mapped
  • apps/server/src/services/analytics/draft-analytics.tsno production surface mapped
  • apps/server/src/services/channels/adapters/index.tsno production surface mapped
  • apps/server/src/services/crm/conversations.tsno production surface mapped
  • apps/server/src/services/drafting/__tests__/create-draft-rewrite-in-place.test.tsno production surface mapped
  • apps/server/src/services/drafting/__tests__/create-draft-thread-recovery.test.tsno production surface mapped
  • apps/server/src/services/drafting/__tests__/create-draft-unowned-thread.test.tsno production surface mapped
  • apps/server/src/services/drafting/__tests__/draft-session-store.test.tsno production surface mapped
  • apps/server/src/services/drafting/__tests__/sweep-sibling-drafts.test.tsno production surface mapped
  • apps/server/src/services/drafting/draft-session-store.tsno production surface mapped
  • apps/server/src/services/drafting/drafting.tsno production surface mapped
  • apps/server/src/services/drafting/sweep-sibling-drafts.tsno production surface mapped
  • apps/server/src/services/integrations/google/__tests__/drive-access.test.tsno production surface mapped
  • apps/server/src/services/integrations/google/drive-access.tsno production surface mapped
  • apps/server/src/services/integrations/slack/__tests__/slack-connection-health.test.tsno production surface mapped
  • apps/server/src/services/integrations/slack/slack-connection-health.tsno production surface mapped
  • apps/server/src/services/mail/send/__tests__/delete-draft-phantom-thread.test.tsno production surface mapped
  • apps/server/src/services/mail/send/send.tsno production surface mapped
  • apps/server/src/services/user-tasks/sort-order-audit.tsno production surface mapped
  • apps/server/src/services/user-tasks/sort-order.tsno production surface mapped
  • apps/server/src/task-admin/cli.tsno production surface mapped
  • apps/server/src/trpc/routes/__tests__/get-task-by-id-ticket-fields.test.tsno production surface mapped
  • apps/server/src/trpc/routes/__tests__/restamp-sort-order.test.tsno production surface mapped
  • apps/server/src/trpc/routes/__tests__/user-tasks-conversation-scope.test.tsno production surface mapped
  • apps/server/src/trpc/routes/__tests__/user-tasks-task-access.test.tsno production surface mapped
  • apps/server/src/trpc/routes/crm.tsno production surface mapped
  • apps/server/src/trpc/routes/drive.tsno production surface mapped
  • apps/server/src/trpc/routes/integrations.tsno production surface mapped
  • apps/server/src/trpc/routes/mail.tsno production surface mapped
  • apps/server/src/trpc/routes/task-groups.tsno production surface mapped
  • apps/server/src/trpc/routes/user-tasks.tsno production surface mapped
  • apps/server/src/types.tsno production surface mapped
  • docs/customer-feedback/2026-08-30-A5-draft-divergence-investigation.mdno production surface mapped
  • pnpm-lock.yamlno production surface mapped