You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@maka.apache.org by "Phoenix500526 (via GitHub)" <gi...@apache.org> on 2026/09/11 08:08:20 UTC

[PR] refactor(ui): remove dead rail unarchive [maka]

Phoenix500526 opened a new pull request, #5190:
URL: https://github.com/apache/maka/pull/5190

   ## Summary
   
   Remove the unreachable task-rail Unarchive path. Archived sessions are
   excluded before rail projection, so `SessionRowActions.onUnarchive` and its
   rendering branch could not run in production.
   
   Keep the active restore paths unchanged: Settings > Archived Tasks, the
   session controller and IPC boundary, archived projects, and Work Board.
   
   Fixes #5189
   
   ## Verification
   
   - `npm exec biome lint -- <9 changed files>` — passed
   - `npm run format:check` — passed (2,075 files)
   - `npm --workspace @maka/ui run build` — passed
   - `npm --workspace @maka/ui run test:dist` — passed (430 tests)
   - `npm --workspace @maka/desktop run typecheck` — passed
   - Storybook smoke was not run; this removes an unreachable rail branch and
     does not change a rendered reachable state.
   
   ## AI use
   
   Select exactly one:
   
   - [ ] No generative tool made a substantive contribution
   - [x] Generative tooling made a substantive contribution
   
   Tool(s) and scope: OpenAI Codex analyzed reachability, implemented the cleanup,
   updated fixtures, ran verification, and drafted this pull request.
   
   ## Checklist
   
   - [ ] Tests cover the change and fail without it
   - [x] Lint, format, typecheck and the affected suites pass locally
   
   Does this PR entail a change in behavior?
   
   - [ ] Yes — described under Summary above
   - [x] No
   


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: commits-unsubscribe@maka.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscribe@maka.apache.org
For additional commands, e-mail: commits-help@maka.apache.org


Re: [PR] refactor(ui): remove dead rail unarchive [maka]

Posted by "Astro-Han (via GitHub)" <gi...@apache.org>.
Astro-Han merged PR #5190:
URL: https://github.com/apache/maka/pull/5190


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: commits-unsubscribe@maka.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscribe@maka.apache.org
For additional commands, e-mail: commits-help@maka.apache.org


Re: [PR] refactor(ui): remove dead rail unarchive [maka]

Posted by "Phoenix500526 (via GitHub)" <gi...@apache.org>.
Phoenix500526 commented on PR #5190:
URL: https://github.com/apache/maka/pull/5190#issuecomment-5854213913

   > # PR 5190 Review
   > ## 结论
   > APPROVE 删除的 rail unarchive 路径确为死代码:`sessionMatchesRail`(`apps/desktop/src/renderer/features/session-navigation/model/session-nav-filter.ts:31`)在投影前过滤掉 `isArchived`,rail 上的行永远不会 `isArchived===true`,`onUnarchive` 分支不可达;全仓 grep 确认 `SessionRowActions.onUnarchive` 无其他消费者(work-board 的 `onUnarchive` 是不同接口、使用 desktop 自己的 `locales/conversation-copy.ts`,未动)。`ConversationCopy.sessions.unarchive` 的移除也与之配套(无残留引用)。
   
   Rebased. 


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: commits-unsubscribe@maka.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscribe@maka.apache.org
For additional commands, e-mail: commits-help@maka.apache.org


Re: [PR] refactor(ui): remove dead rail unarchive [maka]

Posted by "Astro-Han (via GitHub)" <gi...@apache.org>.
Astro-Han commented on code in PR #5190:
URL: https://github.com/apache/maka/pull/5190#discussion_r4115133713


##########
packages/ui/src/session-history-list.tsx:
##########
@@ -1553,14 +1552,10 @@ function SessionItemActions(props: {
                 // reachable only for a task already archived, which is the step
                 // that makes the intent deliberate.
                 {
-                  label: props.session.isArchived ? copy.unarchive : copy.archive,
-                  icon: props.session.isArchived ? ArchiveRestore : Archive,
+                  label: copy.archive,
+                  icon: Archive,

Review Comment:
   The menu now assumes the row it is drawn for is not archived — the branch that used to answer `isArchived` with "Unarchive" is gone, so an archived row reaching this list would be offered "Archive" again. That holds today because the rail's `deriveSessionRail` `include` predicate drops archived sessions (`apps/desktop/src/renderer/features/session-navigation/ui/session-navigation-provider.tsx:125`), but the precondition now lives a package away from the assumption. A one-line note here, or on `SessionRowActions`, would keep it visible to whoever next wires a list into this component.
   
   Not a defect in this change; the removal is correct as far as I can trace it.
   



-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: commits-unsubscribe@maka.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscribe@maka.apache.org
For additional commands, e-mail: commits-help@maka.apache.org