Skip to content

Self-hosted, Self-Improving, Federated Everything App — dev management, agent orchestration, persistent mind, digital twin, second brain, and creative pipeline from a single dashboard over Tailscale to port the user into the OS

address review (codex): use quoted --author "$OWNER", not a packed OWNER_FLAG scalar

[._.]/ Adam Eivy471c58781f91
diff --git a/server/services/cosTaskGenerator.js b/server/services/cosTaskGenerator.js
index ba957f0a3a..6a56854a4c 100644
--- a/server/services/cosTaskGenerator.js
+++ b/server/services/cosTaskGenerator.js
@@ -1254,8 +1254,8 @@ export async function generateManagedAppImprovementTaskForType(taskType, app, st
// so read it from `metadata`. 'owner' (the default, matching /claim --issues)
// restricts to repo-owner-filed issues; 'any' claims any open issue.
const issueAuthorFilterBlock = (metadata.issueAuthorFilter || 'owner') === 'any'
- ? '**Author filter: any author.** Claim the next eligible open issue regardless of who filed it — do NOT pass `--author` to `gh issue list` (leave `OWNER_FLAG` empty).'
- : '**Author filter: repository owner only.** Only claim issues filed by the repository owner/creator. Resolve the owner with `gh repo view --json owner -q .owner.login` and set `OWNER_FLAG="--author <owner>"`; skip issues opened by anyone else.';
+ ? '**Author filter: any author.** Claim the next eligible open issue regardless of who filed it — omit `--author` from `gh issue list` entirely.'
+ : '**Author filter: repository owner only.** Only claim issues filed by the repository owner/creator. Resolve the owner with `OWNER="$(gh repo view --json owner -q .owner.login)"` and pass `--author "$OWNER"` (a quoted single token) to `gh issue list`; skip issues opened by anyone else.';
const description = promptTemplate
.replace(/\{appName\}/g, app.name)
diff --git a/server/services/taskPromptService.js b/server/services/taskPromptService.js
index 980626f186..09d2b74276 100644
--- a/server/services/taskPromptService.js
+++ b/server/services/taskPromptService.js
@@ -513,8 +513,13 @@ Run steps 1–5 in order.
2. List candidate open issues **oldest-first**, honoring the author filter described above. \`gh issue list\` defaults to newest-first, so order on the SERVER with \`--search "sort:created-asc"\` — a client-side \`jq\` sort would only reorder the already-truncated newest page, dropping the true oldest issues on repos with more than \`--limit\` open issues:
\`\`\`bash
git fetch --prune 2>/dev/null
- # OWNER_FLAG is "--author <owner>" for owner-only mode, or empty for any-author mode (see the author-filter block above)
- gh issue list --state open $OWNER_FLAG --search "sort:created-asc" --json number,title,author,assignees,labels,createdAt --limit 100
+ # Author filter (see the block above). Pass --author as a QUOTED single token —
+ # do NOT pack flag+value into one variable: a bare \`$VAR\` holding "--author x"
+ # is a single argv token in zsh (no word-splitting) and gh rejects it.
+ # Owner-only mode (default): resolve the owner, then add --author "$OWNER"
+ OWNER="$(gh repo view --json owner -q .owner.login)"
+ gh issue list --state open --author "$OWNER" --search "sort:created-asc" --json number,title,author,assignees,labels,createdAt --limit 100
+ # Any-author mode: run the SAME command WITHOUT the --author "$OWNER" flag.
\`\`\`
3. Build the in-flight set. Collect every branch/PR ref:
\`\`\`bash