remotion-dev/remotion · error · TypeError
The "freeze" prop of <Sequence /> must be finite, but it is
Error message
The "freeze" prop of <Sequence /> must be finite, but it is ${freeze}. What it means
Thrown when the freeze prop is Infinity or -Infinity. An infinite frame index cannot map to a real frame in the video, so Remotion rejects it to prevent runtime crashes downstream.
Source
Thrown at packages/core/src/Sequence.tsx:268
`The "trimBefore" prop of <Sequence /> must be finite, but it is ${trimBefore}.`,
);
}
if (typeof freeze !== 'undefined' && freeze !== null) {
if (typeof freeze !== 'number') {
throw new TypeError(
`The "freeze" prop of <Sequence /> must be a number, but is of type ${typeof freeze}.`,
);
}
if (Number.isNaN(freeze)) {
throw new TypeError(
`The "freeze" prop of <Sequence /> must be a real number, but it is NaN.`,
);
}
if (!Number.isFinite(freeze)) {
throw new TypeError(
`The "freeze" prop of <Sequence /> must be finite, but it is ${freeze}.`,
);
}
}
const absoluteFrame = useTimelinePosition();
const videoConfig = useVideoConfig();
const effectiveRelativeFrom = from - trimBefore;
const absoluteFrom =
(parentSequence?.absoluteFrom ?? 0) + effectiveRelativeFrom;
const parentSequenceDuration = parentSequence
? Math.min(
parentSequence.durationInFrames - effectiveRelativeFrom,
durationInFrames,
)
: durationInFrames;
const actualDurationInFrames = Math.max(View on GitHub (pinned to 78fe4bb3fd)
Solutions
- Guard with Number.isFinite(freeze) before passing.
- Clamp freeze to a valid frame range: freeze={Math.min(freeze, durationInFrames - 1)}.
- Audit the source producing Infinity.
Example fix
// before
<Sequence freeze={computedFreeze} />
// after
<Sequence freeze={Number.isFinite(computedFreeze) ? Math.min(computedFreeze, durationInFrames - 1) : undefined} /> Defensive patterns
Strategy: validation
Validate before calling
const freeze = Number.isFinite(rawFreeze) ? Math.min(rawFreeze, durationInFrames - 1) : undefined;
Type guard
const isFiniteFrame = (v: unknown): v is number => typeof v === 'number' && Number.isFinite(v);
Prevention
- Clamp freeze to the composition's valid frame range.
- Avoid Infinity as a default sentinel for numeric props.
When it happens
Trigger: freeze is set from an unbounded computation (e.g. frame count from an unloaded resource), or explicitly to Infinity.
Common situations: Defaulting freeze to a sentinel like Infinity; arithmetic overflow; spreading props from a config where freeze was set to Number.POSITIVE_INFINITY.
Related errors
- The "from" prop of a sequence must be finite, but got ${from
- The "trimBefore" prop of <Sequence /> must be finite, but it
- The "freeze" prop of <Sequence /> must be a number, but is o
- The "freeze" prop of <Sequence /> must be a real number, but
- Argument passed to "${api}" for param "${param}" is ${JSON.s
AI-assisted analysis of remotion-dev/remotion@78fe4bb3fd (2026-08-12).
Data as JSON: /api/errors/c308b0b386f34f00.
Report an issue: GitHub.