jackwener/OpenCLI · error · ArgumentError
${capabilities.plan || 'current'} plan does not support HD v
Error message
${capabilities.plan || 'current'} plan does not support HD video; use --video-resolution sd What it means
assertActionPlan checks the caller's Midjourney plan capabilities before allowing HD video operations. If videoResolution is 'hd', the operation is a video action, and planCapabilities(account).canHdVideo is false, it throws this ArgumentError telling the user to fall back to sd.
Source
Thrown at clis/midjourney/capabilities.js:320
return GPU_COST_MINUTES[`video${videoResolution === 'hd' ? 'Hd' : 'Sd'}${batchSize}`];
}
if (sourceUsesOmni && ['rerun', 'vary-subtle', 'vary-strong'].includes(operation)) {
return GPU_COST_MINUTES.omni;
}
if (Object.prototype.hasOwnProperty.call(ACTION_COSTS, operation)) return ACTION_COSTS[operation];
if (['animate-low', 'animate-high', 'loop-low', 'loop-high', 'extend-low', 'extend-high'].includes(operation)) {
if (!['sd', 'hd'].includes(videoResolution)) throw new ArgumentError('--video-resolution must be sd or hd');
if (![1, 2, 4].includes(batchSize)) throw new ArgumentError('--batch-size must be 1, 2, or 4');
return GPU_COST_MINUTES[`video${videoResolution === 'hd' ? 'Hd' : 'Sd'}${batchSize}`];
}
throw new ArgumentError(`No cost model is defined for action "${operation}"`);
}
export function assertActionPlan(account, operation, { videoResolution = 'sd' } = {}) {
const capabilities = planCapabilities(account);
if (videoResolution === 'hd' && !capabilities.canHdVideo
&& ['animate-low', 'animate-high', 'loop-low', 'loop-high', 'extend-low', 'extend-high'].includes(operation)) {
throw new ArgumentError(`${capabilities.plan || 'current'} plan does not support HD video; use --video-resolution sd`);
}
return capabilities;
}
export function buildEffectivePrompt(prompt, plan, args, remoteReferences = {}) {
let result = String(prompt || '').trim();
const imageUrls = remoteReferences.image || [];
if (imageUrls.length) result = `${imageUrls.join(' ')} ${result}`.trim();
const additions = [];
if (!promptParamValue(result, ['v', 'version']) && !promptParamValue(result, ['niji']) && args.model && args.model !== 'auto') {
if (String(args.model).startsWith('niji')) additions.push(`--niji ${String(args.model).slice(4)}`);
else additions.push(`--v ${String(args.model).replace(/^v/, '')}`);
} else if (plan.routingReason === 'omni_reference_requires_v7' && !promptParamValue(result, ['v', 'version'])) {
additions.push('--v 7');
}
if (!promptHasFlag(result, ['sd', 'hd']) && args.resolution && args.resolution !== 'auto') additions.push(`--${args.resolution}`);
if (!promptHasFlag(result, ['fast', 'relax', 'turbo']) && args.speed && args.speed !== 'auto') additions.push(`--${args.speed}`);View on GitHub (pinned to 49907e53dc)
Solutions
- Re-run with --video-resolution sd
- Upgrade the Midjourney subscription to a plan that supports HD video
- Verify planCapabilities(account) is populated correctly (plan name/entitlements loaded, not defaulted)
- Gate HD options in the CLI behind the account's detected plan before presenting them
Example fix
// before
assertActionPlan(account, 'animate-high', { videoResolution: 'hd' });
// after
const caps = planCapabilities(account);
const res = caps.canHdVideo ? 'hd' : 'sd';
assertActionPlan(account, 'animate-high', { videoResolution: res }); Defensive patterns
Strategy: validation
Validate before calling
import { planCapabilities, assertActionPlan } from './clis/midjourney/capabilities.js';
const caps = planCapabilities(account);
if (!caps.canHdVideo) {
console.warn('Plan does not support HD video; falling back to sd');
videoResolution = 'sd';
}
assertActionPlan(account, operation, { videoResolution }); Type guard
function planSupportsHd(account) {
return Boolean(planCapabilities(account)?.canHdVideo);
} Try / catch
try {
assertActionPlan(account, operation, { videoResolution: 'hd' });
} catch (err) {
if (err instanceof ArgumentError && err.message.includes('does not support HD video')) {
console.error('Retry with --video-resolution sd or upgrade your Midjourney plan');
} else throw err;
} Prevention
- Inspect planCapabilities(account) before offering HD flags to users
- Fall back to 'sd' automatically when canHdVideo is false
- Warn users in --help that HD requires a higher plan tier
- Verify account/plan metadata loaded correctly to avoid false rejections
When it happens
Trigger: assertActionPlan(account, 'animate-high', { videoResolution: 'hd' }) for an account whose plan lacks HD video (e.g. basic/standard tiers).
Common situations: Users on lower Midjourney subscription tiers running HD animation/loop/extend commands; accounts whose plan metadata failed to load so canHdVideo defaults to false; scripts hardcoded to hd.
Related errors
- Video jobs support video-raw, video-social, or gif downloads
- Midjourney generation requires an active subscription.
- Could not write Midjourney media ${filePath}: ${errorMessage
- Midjourney manual video composer did not expose the End Fram
- Midjourney CDN reported ${media.mime || 'unknown'} for ${url
AI-assisted analysis of jackwener/OpenCLI@49907e53dc (2026-08-29).
Data as JSON: /api/errors/6aeb70a053dbfabb.
Report an issue: GitHub.