@remotion/studio: Remove timeline sequence hashes - #9701
Conversation
There was a problem hiding this comment.
Important
A stale rootId reference in packages/gif/src/test/Gif.test.tsx will cause a TypeScript error after removing rootId from TimelineContextValue.
Reviewed changes — removes the timeline sequence hashing and rootId deduplication system now that Studio has a single active preview root, and renames the remaining track types for clarity.
- Remove
rootIdfromTSequenceandTimelineContextValue— no longer passed inSequence.tsx,useMediaInTimeline,TimelineContextProvider,Player, orThumbnail. - Delete
getTimelineSequenceHash— the deduplication-by-hash logic and theuniqueTracksloop incalculate-timelineare removed since every sequence now maps to exactly one track. - Simplify
getTimelineSequenceSortKey— drops the hash-based parent lookup in favor of directparentfield traversal;nonceRanksis now a required parameter. - Rename types —
TrackWithHash→TimelineTrackData,TrackWithHashAndOriginalTimings→TimelineTrackWithOriginalTimings,Track(inner) → exportedTimelineTrackData. - Update all consumers across 34 files in core, player, studio, and test-utils, plus inline test fixture removals for
rootIdandhashfields.
⚠️ Stale rootId in packages/gif test — will not compile
packages/gif/src/test/Gif.test.tsx constructs a TimelineContextValue (via React.ContextType<typeof Internals.TimelineContext>) with a now-removed rootId property. The PR updated core, player, studio, and test-utils but missed this consumer in the gif package.
Technical details
# Stale `rootId` in `packages/gif` test
## Affected sites
- `packages/gif/src/test/Gif.test.tsx:97` — `rootId: 'test-root'` on a `TimelineContextValue` typed object
## Required outcome
- Remove the `rootId` line from the `timelineContext` object literal in `Gif.test.tsx`
## Suggested approach
Delete line 97 (`rootId: 'test-root',`) — identical to the cleanups performed in `packages/core/src/test/nested-sequences.test.tsx`, `series.test.tsx`, `wrap-sequence-context.tsx`, and `test-utils/src/timeline-context.ts`.Note: 1 inline comment(s) dropped because they did not anchor to lines inside the PR diff:
packages/gif/src/test/Gif.test.tsx:97(RIGHT) — file not in PR diff
DeepSeek Pro (free via Pullfrog for OSS) (Claude Opus not used — the program covers this model; add its provider key to run your pick) | 𝕏
11bae82 to
1af3d04
Compare
dac7632 to
2bfcfff
Compare

Summary
rootIdfrom timeline contexts and sequence registrations now that Studio has one active preview rootTesting
bun testfor the affected Studio timeline suites (188 tests)bun testfor the affected core sequence suites (52 tests)bun run buildbun run stylecheck