stablyai/orca · error · RuntimeClientError
invalid_argument
invalid_argument
Error message
Pass either <id> or --current, not both
What it means
Thrown by buildSaveIssueRequest (the save-issue-specific target resolver) when BOTH an explicit issue `<id>` AND `--current` are supplied. save-issue must target one issue; supplying both is ambiguous. This mirrors the buildWriteTargetRequest guard but lives in the save-issue builder because save-issue accepts additional fields (title, state, etc.).
Source
Thrown at src/cli/linear-save-issue-request.ts:26
buildLinearCurrentContext,
getDueDateFlag,
getOptionalWriteId,
getPriorityFlag,
readLinearBody,
rejectAllWorkspaceForWrite
} from './linear-request-builders'
import { RuntimeClientError } from './runtime-client'
export async function buildSaveIssueRequest(
flags: Map<string, string | boolean>,
cwd: string,
remote: boolean
): Promise<LinearSaveIssueRequest> {
rejectAllWorkspaceForWrite(flags)
const input = getOptionalStringFlag(flags, 'id')
const current = flags.get('current') === true
if (input && current) {
throw new RuntimeClientError('invalid_argument', 'Pass either <id> or --current, not both')
}
const body = await readLinearBody(flags, cwd, { required: false })
const description = getOptionalStringFlag(flags, 'description')
if (body !== undefined && description !== undefined) {
throw new RuntimeClientError('invalid_argument', 'Use either --description or --body, not both')
}
return {
input,
current,
workspaceId: getOptionalStringFlag(flags, 'workspace'),
context: buildLinearCurrentContext(cwd, remote),
team: getOptionalStringFlag(flags, 'team'),
title: getOptionalStringFlag(flags, 'title'),
description: description ?? body,
state: getOptionalStringFlag(flags, 'state'),
assignee: getNullableStringFlag(flags, 'assignee'),
priority: flags.has('priority') ? getPriorityFlag(flags, 'priority') : undefined,
estimate: getOptionalNullableNumberFlag(flags, 'estimate'),View on GitHub (pinned to 1136503c6a)
Solutions
- Drop `--current` and keep `<id>` to update a known issue.
- Or drop `<id>` and keep `--current` to save against the branch-linked issue.
- Remove stray `--current` injection from aliases and wrapper scripts.
Example fix
// before linear save-issue LIN-123 --current --state "In Progress" // after linear save-issue LIN-123 --state "In Progress"
Defensive patterns
Strategy: validation
Validate before calling
const input = flags.get('id')
const current = flags.get('current') === true
if (input && current) {
throw new Error('save-issue: pass either <id> or --current, not both')
} Type guard
function hasExactlyOneSaveIssueTarget(flags: Map<string, string | boolean>): boolean {
const hasId = Boolean(flags.get('id'))
const hasCurrent = flags.get('current') === true
return hasId !== hasCurrent
} Prevention
- Standardize on one targeting mode per save-issue workflow.
- Strip `--current` from aliases whenever an explicit id is passed.
When it happens
Trigger: Running `linear save-issue LIN-123 --current ...` or any save-issue call where both `flags.get('id')` is truthy and `flags.get('current') === true`.
Common situations: Transitioning a script from id-based to context-based targeting and leaving the id in place. Aliases that inject `--current` unconditionally. Mistakenly believing `--current` is a modifier rather than an alternative target.
Related errors
- linear_issue_required
- invalid_argument
- invalid_argument
- linear_invalid_workspace
- linear_invalid_write_id
AI-assisted analysis of stablyai/orca@1136503c6a (2026-08-12).
Data as JSON: /api/errors/500f4e69cfd541c3.
Report an issue: GitHub.