fix(cli): list remote machine projects without daemon - #587
Merged
Merged
Conversation
Model: gpt-5.6-sol Signed-off-by: Dante <duanjl.china@gmail.com>
Dante-dan
marked this pull request as ready for review
September 10, 2026 22:41
Codex Review SummaryThis comment shows the latest Codex review activity on this pull request.
ℹ️ About Codex in GitHubYour team has set up Codex to review pull requests in this repo. Reviews are triggered when you
Codex reacts with 👀 while any review is running, comments if it has suggestions, and reacts with 👍 once all reviews finish with no findings. |
Contributor
|
@Dante-dan, this pull request needs updates before review. It is marked If the PR remains invalid for 7 days, it will be closed and marked Policy findings |
Contributor
|
LGTM |
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.
Related issue
Closes #582
Problem / pressure
lody project listalways uses local-daemon IPC, even though authenticated session creation can already synchronize and read a selected remote machine's local-project catalog. A headless client with credentials but no daemon can therefore dispatch work to a remote machine only if it already knows a project selector; it cannot list the available projects through a stable CLI contract.Summary
Add
--workspaceand--machineselectors tolody project list. Selector-free calls retain the existing local-daemon behavior, while an explicit selector uses the authenticated one-shot workspace path, resolves the selected machine, synchronizes its Flock document, and returns the same merged local-project catalog used by session creation.The remote path verifies machine and per-project access before returning paths. It fails closed on authorization or synchronization errors, supports machine ids and unique names, and preserves JSON and terminal-table response behavior. The CLI reference and bilingual Agent Note document the resulting boundary.
Visual explanation
flowchart TD A[lody project list] --> B{workspace or machine selector?} B -- no --> C[Existing local-daemon IPC] B -- yes --> D[Authenticated one-shot workspace manager] D --> E[Resolve authorized machine] E --> F[Sync target machine Flock] F --> G[Read merged local-project catalog] G --> H[Filter project access] H --> I[JSON or terminal table]Before / after
project listrequires a daemon on the client machine.session createerror.local-project/listresponse.Test plan
corepack pnpm --filter lody exec vitest run src/lib/remote-local-project-list.test.ts— 4 tests passed.corepack pnpm --filter lody run typecheck— passed.corepack pnpm --filter lody run format:check— passed.node scripts/docs/main.mjs check— passed with existing translation and Agent-instruction size warnings.git diff --check upstream/main...HEAD— passed.Context handoff
Instructions for reviewing agents
apps/cli/src/commands/project.tsand the sync/access order inremote-local-project-list.ts.Authoring context
lody project listrequires the local daemon; there is no daemon-free way to list a remote machine's local projects (whichsession create --local-projectalready resolves via the backend) #582 asks for a supported daemon-free remote project-list command; Dante-dan authorized the tracker to investigate eligible issues and publish validated fixes under each repository's current rules.Original user prompt
Show original prompt