fix(agent-display): remove ZWSP from agent sort prefixes (fixes #3337)#3374
fix(agent-display): remove ZWSP from agent sort prefixes (fixes #3337)#3374MoerAI wants to merge 1 commit intocode-yeongyu:devfrom
Conversation
|
I have read the CLA Document and I hereby sign the CLA |
There was a problem hiding this comment.
No issues found across 2 files
Confidence score: 5/5
- Automated review surfaced no issues in the provided summaries.
- No files require special attention.
Requires human review: Removing ZWSP sort prefixes changes the UI sort order for agents (e.g., Atlas moves from 4th to 1st), which constitutes a functional regression in sorting logic.
There was a problem hiding this comment.
💡 Codex Review
Here are some automated review suggestions for this pull request.
Reviewed commit: 56e02e2ad3
ℹ️ About Codex in GitHub
Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you
- Open a pull request for review
- Mark a draft as ready
- Comment "@codex review".
If Codex has suggestions, it will comment; otherwise it will react with 👍.
Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".
| sisyphus: "", | ||
| hephaestus: "", | ||
| prometheus: "", | ||
| atlas: "", |
There was a problem hiding this comment.
Restore non-visible runtime prefixes for core agent ordering
Setting all core entries in AGENT_LIST_SORT_PREFIXES to empty strings removes the only runtime signal used to keep Sisyphus/Hephaestus/Prometheus/Atlas in canonical order when consumers sort by name (src/plugin-handlers/AGENTS.md documents Agent.list() using localeCompare on name). With these values empty, getAgentRuntimeName() now emits plain display names, so any name-based sort will reorder core agents alphabetically (Atlas first) instead of the required sisyphus → hephaestus → prometheus → atlas order.
Useful? React with 👍 / 👎.
|
CI: 4578 pass, 2 fail. The 2 failures are in |
56e02e2 to
7adbc44
Compare
Summary
Problem
Agent names display incorrectly in TUI on terminals that don't render ZWSP (
\u200B) characters properly. TheAGENT_LIST_SORT_PREFIXESmap prepends 1-4 ZWSP characters to core agent display names for list ordering, but many terminals (WezTerm, Linux terminal emulators) render these as visible artifacts or truncate the agent name.Fix
Set all
AGENT_LIST_SORT_PREFIXESvalues to empty strings. The invisible character stripping utilities (stripInvisibleAgentCharacters,stripAgentListSortPrefix) are preserved for backward compatibility with old sessions that may still contain ZWSP-prefixed names.Changes
src/shared/agent-display-names.tssrc/shared/agent-display-names.test.tsFixes #3337
Also resolves #3307 and #3347 (same root cause)
Summary by cubic
Remove zero‑width space sort prefixes from core agent display names to fix terminal rendering issues. Keeps stripping helpers for backward compatibility. Fixes #3337; also resolves #3307 and #3347.
Written for commit 7adbc44. Summary will update on new commits.