microsoft/playwright · error · Error
Cannot fast-forward to the past
Error message
Cannot fast-forward to the past
What it means
Error "Cannot fast-forward to the past" thrown in microsoft/playwright.
Source
Thrown at packages/injected/src/clock.ts:286
await this._innerPause();
try {
await fn();
} finally {
this._innerResume();
}
}
async fastForward(ticks: number) {
this._replayLogOnce();
await this._runWithDisabledRealTimeSync(async () => {
await this._innerFastForwardTo(shiftTicks(this._now.ticks, ticks | 0));
});
}
private async _innerFastForwardTo(to: Ticks) {
if (to < this._now.ticks)
throw new Error('Cannot fast-forward to the past');
for (const timer of this._timers.values()) {
if (to > timer.callAt)
timer.callAt = to;
}
await this._runTo(to);
}
addTimer(options: { func: TimerHandler, type: TimerType, delay?: number | string, args?: any[] }): number {
this._replayLogOnce();
if (options.type === TimerType.AnimationFrame && !options.func)
throw new Error('Callback must be provided to requestAnimationFrame calls');
if (options.type === TimerType.IdleCallback && !options.func)
throw new Error('Callback must be provided to requestIdleCallback calls');
if ([TimerType.Timeout, TimerType.Interval].includes(options.type) && !options.func && options.delay === undefined)
throw new Error('Callback must be provided to timer calls');
let delay = options.delay ? +options.delay : 0;View on GitHub (pinned to c8fc3bf8d3)
When it happens
Trigger: Thrown at packages/injected/src/clock.ts:286 when the library encounters an invalid state.
Common situations: See trigger scenarios.
AI-assisted analysis of microsoft/playwright@c8fc3bf8d3 (2026-08-12).
Data as JSON: /api/errors/b0dccb39807679bd.
Report an issue: GitHub.