stablyai/orca · warning
Hermes cron requires a prompt.
Error message
Hermes cron requires a prompt.
What it means
Thrown by normalizeHermesCronMutationInput() after trimming when input.prompt is empty. A Hermes cron job runs a prompt on a schedule, so a non-empty prompt is mandatory. The guard fires only for create/edit of Hermes crons (provider check at 756 runs first).
Source
Thrown at src/main/automations/external-manager.ts:420
return 'rm'
}
}
function normalizeHermesCronMutationInput(input: ExternalAutomationCreateInput): {
name: string
prompt: string
schedule: string
workdir: string | null
} {
if (input.provider !== 'hermes') {
throw new Error('Only Hermes cron creation and editing are supported.')
}
const name = input.name.trim()
const prompt = input.prompt.trim()
const schedule = input.schedule.trim()
const workdir = input.workdir?.trim() || null
if (!prompt) {
throw new Error('Hermes cron requires a prompt.')
}
if (!schedule) {
throw new Error('Hermes cron requires a schedule.')
}
return {
name: name || prompt.slice(0, 50).trim() || 'Hermes cron',
prompt,
schedule,
workdir
}
}
function hermesCronCreateArgs(input: {
name: string
prompt: string
schedule: string
workdir: string | null
}): string[] {View on GitHub (pinned to 1136503c6a)
Solutions
- Require and validate a non-empty prompt in the UI/form before submitting create/update.
- Coerce undefined to '' explicitly and show a validation error rather than calling the API.
- For programmatic callers, assert input.prompt.trim() is non-empty upstream.
Example fix
// before
createExternalAutomation({ provider: 'hermes', prompt: ' ', schedule: '0 * * * *', ... }) // throws
// after
const prompt = rawPrompt.trim()
if (!prompt) throw new UserError('Prompt is required.')
createExternalAutomation({ provider: 'hermes', prompt, schedule: '0 * * * *', ... }) Defensive patterns
Strategy: validation
Validate before calling
function isNonEmptyPrompt(v: unknown): boolean {
return typeof v === 'string' && v.trim().length > 0
}
if (input.provider === 'hermes' && !isNonEmptyPrompt(input.prompt)) {
throw new UserError('Hermes cron needs a prompt.')
}
createExternalAutomation(input) Type guard
function isNonEmptyString(v: unknown): v is string {
return typeof v === 'string' && v.trim().length > 0
} Try / catch
try {
await createExternalAutomation(input)
} catch (e) {
if ((e as Error).message === 'Hermes cron requires a prompt.') {
throw new UserError('Please enter a prompt for the cron job.')
}
throw e
} Prevention
- Require the prompt field in the create/edit form and disable submit until non-empty.
- Trim input client-side and show inline validation before calling the API.
- For programmatic callers, assert input.prompt?.trim() is truthy upstream.
When it happens
Trigger: Creating or editing a Hermes cron with a blank/whitespace-only prompt field; a form that submits an empty prompt; a script defaulting prompt to '' or undefined.
Common situations: User clicks create without entering a prompt; a template failed to interpolate and produced an empty string; UI sends the field as undefined which trims to ''.
Related errors
- Hermes cron requires a schedule.
- Invalid external automation job ID.
- coordinate action requires a visible window and coordinates
- {name} must be a positive integer
- Only Hermes cron creation and editing are supported.
AI-assisted analysis of stablyai/orca@1136503c6a (2026-08-12).
Data as JSON: /api/errors/bb96b30aba6e6acd.
Report an issue: GitHub.