* fix(producer): charge generated mount scripts and scoped styles to the expansion budget
The expansion budget charged only the source bytes of each mounted file.
The inliner wraps every inline script in kilobytes of scoping code and
prefixes every style rule with the host's scope, so tiny scripts or a long
composition id over many rules assembled a page hundreds of times larger
than its source.
The inliner now reports what it generates through a chargeEmitted option.
Each wrapped script is charged once built. Each style rule reserves an upper
bound before it is scoped and settles to its real size after, so no rule is
built past the limit. Generated output has its own 32 MB allowance.
* fix(core): reserve the separator postcss re-joins scoped selectors with
The per-rule reservation summed a bound per selector but left out the
separator. postcss's selectors setter re-joins the list with the first
separator in the authored selector, so a wide first separator over many
selectors grew the rule past its reservation before it was charged.
* test(core): give the scoper bound test the same time limit as its neighbour
* fix(studio): error events send a class, a shape and Studio's own frames, not the error's words
Error messages from the browser, a server or the project now leave as an unsalted shape of the cut first line (numbers, quotes and paths removed) plus any HTTP status, beside the error class each sender now passes. Stacks keep only frames in Studio's own scripts as fn@file:line:col; any other frame, its name included, is ?. Component stacks keep component names. A script filename is sent only when it is one of Studio's own. The resolver shadow's mismatch list no longer carries the error's words or the selector-built animation id.
* fix(studio): error shapes match across projects and bare paths are never Studio frames
Only an absolute http(s) frame on Studio's origin is kept; the message shape cuts URLs and selector ids and uses the install salt.
* feat(studio-server): let a host count the requests the API refuses with 403
* fix(studio-server): a refusal names the endpoint asked for, not the middleware that refused it
* style(studio-server): refusal reports carry their meaning in names, not comments
* fix(studio-server): a refusal the API sends through itself again is counted once
* fix(studio-server): a request sent through the API again is known before a middleware swaps it
* test(studio): Add keyframe on a sealed preview seeds from a moved layer's translate
* fix(studio): Add keyframe on a sealed preview keeps a moved layer in place
* fix(studio): a sealed keyframe seed reads the translate the frame renders, a stylesheet's too
The text-over-face pass now treats a page-named source as missing when it
is a private project file, by its name or through a link, or is not a
regular file. Before any ffprobe or ffmpeg run, it refuses a document,
pipe or playlist that names files outside its folder or private in it.
Every probe and decode then uses render's demuxer list and a 30 s limit.
measure reads files named on the command line as before.
* test(studio): a sealed preview moves and saves a layer its animation moves
* fix(studio): a sealed preview moves and saves a layer its animation moves
* test(studio): a sealed drag of a moving layer saves nothing when the preview's tweens can't be read
* fix(studio): a sealed drag of a moving layer saves nothing without the preview's tweens
* refactor(studio): keep the drag stamp's writer beside its reader
* style(studio): keep the drag stamp reader's comment on the reader
* fix(studio): analytics send path and selector facts, not the paths and selectors
Both Studio transports now shape every event's values in one place before they leave the machine: a file path becomes its extension, kind, depth and a per-install salted hash; a selector becomes its kind and the same hash; any other value that reads as a path or selector is dropped and named in dropped_fields. Save failures send the error class, a fixed error key and the server's fixed refusal code instead of the error's words. Session fields can no longer be overwritten by a caller.
* fix(studio): save failures keep their dedupe and no selector leaves in shadow mismatches
The editor's failure dedupe keys on the error's own text again, locally. The resolver shadow's animation_not_found no longer repeats the animation id inside mismatches. Error keys and path kinds read from tables; the server's full refusal list is known.
* fix(studio): a paused save queue reports codes, not the save error's words
save_queue_paused spreads the save failure's fixed codes again; its handler lives outside the persistence hook.
* test(studio): a sealed preview's motion path finds its layer's home
* fix(studio): the motion path draws and creates in a sealed preview
* test(core): a motion path's home counts a wrapper's 2D and 3D translate
* test(studio): a sealed click places a new motion path from the layer's home at the click
* test(studio): a sealed motion path refuses a bad frame reply and reads the blur root via the port
* fix(studio): a sealed click places a new motion path from the layer's home at the click
* refactor(core): a motion path home reads a matrix's translate in one small helper
* fix(figma): write .media and component outputs without following links
The figma importer's writers (index.md, manifest.jsonl, figma-bindings.jsonl,
figma-tokens.json and component files) used writeFileSync, appendFileSync and
recursive mkdirSync, which follow a link at the target or in its folders.
- Folders under the project (.media, .media/images,
compositions/components/<name>) are created one level at a time and refused
when one is a link or resolves outside the project.
- Whole-file rewrites go through replaceFileAtomically (temp file + rename),
so a link at the target is replaced rather than written through.
- Appends open with O_NOFOLLOW and refuse a link at the target.
- index.md cells collapse line breaks, matching media-use's index-gen.mjs
byte for byte, so each record stays on one line.
* chore(figma): trim added comments; check the component folder right before writing
* fix(figma): open appends first, then check the path holds that same file
appendWithoutFollowing checked the path with lstat and then opened it, leaving
a gap between check and use. It now opens with O_NOFOLLOW first and writes
through the descriptor only when lstat finds the same single-link plain file at
the path, the pattern projectRecords' appendRecord already uses.
* fix(cli): Windows process reads and Chrome cleanup no longer pass PowerShell command text
* fix(cli): a forced Chrome close on Windows ends what Chrome started
* test(cli): the forced-close test's child holds no pipe to the browser
* test(cli): the forced-close test's child outlives a dead parent, as Chrome's do
* test(cli): forced-close test waits for the kill; PowerShell starts only via processReadArgs
* fix(cli): Windows cleanup ends only a process the CLI started, never a pid it was handed
* fix(producer): bound the static media selector check by the page it walks
The pre-check matched every script selector against each media element and
bounded the work by selector length alone. A selector such as :has(...),
a positional pseudo-class or a chain of descendant combinators can walk the
whole page on each match, so the check could block the render process.
Only tags, ids, classes and attributes joined by child combinators and at
most one descendant combinator are now matched statically. Each check is
charged for the media element's ancestors and their attribute text, and
everything else is left to the browser probe.
* fix(producer): charge each selector's full text and every simple test
The selector check charged the collapsed selector shape, so a long
attribute value or whitespace run was nearly free even though the matcher
compiles the whole selector on every call. Each media element is now
charged the raw selector length per ancestor. Attribute text is charged per
simple test rather than per compound, and it is measured only once a
non-id selector needs costing.
* style(producer): shorten the selector cost comment
* test(studio): a sealed preview's new page keeps the selection drawn and draggable
* fix(studio): a selected element stays drawn and draggable after a sealed preview reloads
* test(studio): a click after two quick seeks reads GSAP values at the playhead
* fix(studio): a click after two quick seeks waits for the sealed preview's read at the playhead
* fix(cli): a project .env provider key prints a note when it is used
A provider key from a project .env is still used when no own credential
competes. Capture vision (OpenRouter, Gemini, Google and both Vertex parts),
snapshot --describe, Gemini speech and Lyria music now print one note per key
before it is first used, naming the variable and the escaped .env path, as
the ElevenLabs note does. The ignoring notes escape the path too, and the
media-use skill gets a generated copy of the CLI's terminal-text helper.
* fix(media-use): the audio scripts read a received .env by the CLI's full rule
The audio scripts judged a project .env as received only from
received-files.json at or above it. They now use a generated copy of the
CLI's rule, which also reads the host's received-state file, nested records
and the received content hashes, and treats an unreadable one as received.
A parity test runs the CLI and the copy over the same projects.
A key the CLI unset from a .env is now passed to the scripts it launches,
so they do not load it again from the same file.
* fix(media-use): match the CLI's folder walk and judge a parent .env by itself
The received-rule copy now skips folders by the CLI's exact private-path rule,
so a hidden Studio folder with an asset-like name is walked as the CLI walks
it. A .env the scripts find in a folder above the working one is judged only
by records and host state at or above that folder, so a received sibling or
a large parent folder cannot flip the person's own key. Keys the CLI unset
are matched by the folder's real path.
* fix(media-use): match the received rule's narrowed private-file check
The CLI's private-file rule now treats a hidden file as private whatever its type,
and framework build-output folders and service-account key names as private.
The media-use copy of the rule follows it, so the parity cases for hidden
asset-named Studio folders agree again.
* fix(media-use): write local generator output into private per-run folders
The codex image provider ran `codex exec` with the shared temp folder as its
project root and accepted any non-empty file at a guessable name there
(media-use-codex-<pid>-<ms>.png). On a host where the temp folder is shared
(/tmp on Linux), another account could plant AGENTS.md (and a .git marker)
for Codex to follow, or create the output file first and have it taken as
the generated image.
Codex now works in a fresh mode-0700 folder under the per-user HyperFrames
cache, with project_root_markers=[] so current Codex reads instructions only
from that folder; the folder is removed once the image is copied out. The
mflux, ltx and local Kokoro providers, which used the same guessable names,
now write into a fresh mkdtemp folder too.
* fix(media-use): remove a local generator's private output folder after resolve
Once resolve has copied a generated file into the project, the private folder
it was written in is no longer needed. Only folders privateOutputPath made are
removed; files a provider does not own, such as a bundled SFX library sound,
are left alone.
* fix(media-use): run Codex in the private temp folder too, and drop empty ones
Codex now works in the same mkdtemp folder under the system temp folder as
the other generators, with project_root_markers=[]. Every Codex release with
the image tool honours that setting for AGENTS.md (the image tool landed
months after it), so a per-user cache folder is not needed, and the cache
path no longer has to be built outside hyperframesCacheDir. A provider that
returns nothing now removes the folder it made. The helper test no longer
writes a fixed-name file in the temp folder.
* test(studio): adding a keyframe at the playhead reads a sealed preview's GSAP values
* fix(studio): GSAP keyframe and value reads work in a sealed preview
* test(studio): run the sealed keyframe test's agent on a marked Studio preview page
* test(studio): a sealed preview's GSAP reply is checked before Studio holds it
* fix(studio): hold a sealed preview's GSAP reply only when it is in shape and within bounds
* style(core): keep the snapshot limits module within the comment share
* refactor(studio): check a GSAP reply's tween in small parts
* build: raise the core packed-size budget for the sealed preview's GSAP reader
* test(core): a sealed preview's GSAP read takes a real keyframes tween
* fix(core): a sealed preview's GSAP read leaves GSAP's live objects out of a tween's vars
* fix(cli): keep files received that a host's kept record still lists
When the received-state file names a project as expected and the host
keeps its own copy of that project's record beside the state file, the
received-file checks read the record together with each entry that copy
lists whose path still holds something. A record shortened or emptied
outside the host no longer makes those files read as the person's own.
A kept copy with no list, a doubted one, a link or one that cannot be
read counts every file as received; with no kept copy, nothing changes.
* fix(cli): keep a record's own lines when the host's kept copy cannot be read
A kept copy with no list, or one that cannot be read, now counts every
file as received through its own entry, named by the kept copy's path,
instead of hiding the record's lines from Studio's rename and move
tracking. A copy found only by folder identity counts only when its
identity matches the folder, and a copy that disappears mid-read counts
as no copy.
* docs(cli): say a kept entry whose file is gone is not added back
* fix(cli): say a listed received file is gone, and drop a media file's line on rename
Follow-up to the change that keeps a deleted received page listed.
- The render warning for a listed file that no longer exists now says it
is gone and how to clear it.
- A listed file whose name was already a media name drops its old line
when renamed to another media name, so repeated renames leave no
dead lines.
- The docs say that any listed file that is not media by its first bytes
stays listed after a delete, and that the line can sit in a record
above or inside the project.
- A test restores content after a plain Studio delete and checks that
outside files stay refused.
* test(cli): match the gone-file warning without a POSIX path, for Windows
compositionSrcsIn read template.content at every nesting level. linkedom
builds that fragment by deep-cloning the template's children, so a file of
nested templates cost work and memory that grew with the square of the
depth. The scan now walks the parsed tree once and tracks whether each
element sits inside a template.
A Studio delete took a received page's line off the record, and files
created afterwards were not followed. A script in the preview could
delete every received page and create it again with new bytes, so the
project no longer counted as received and outside files were read.
A deleted page, stylesheet or script now stays listed, so whatever is
written in its place counts as received. A received page renamed to a
media name keeps its old line too. Deleted or renamed media, fonts and
images still drop off, so a media-only project keeps working.
* test(core): a hover capture page keeps a 4K clip's file instead of waiting for its copy
* fix(core): hover and thumbnail captures never wait for a 4K clip's preview copy
* fix(core): keep mediaProxy's comment share flat
* test(core): keep the capture-page test comment within 120 characters
scanExistingAssets printed the project's own file and folder names to
stderr as they are. A name holding escape sequences could rewrite or
hide terminal lines. The line now goes through terminalText, like the
rest of media-use's output.
* feat(cli): check reports text drawn over a face in a video
The layout audit reports text painted in front of an opaque video with its
word boxes and where the video's frame lands; Node finds the faces in the
video file with the detector `measure face` uses and adds a `text_over_face`
finding (info from 5% of the face covered, warning from 30%) with
`coveredFraction` and `faceRect`. `layout.faceCheck` in the report says
whether the pass looked. `data-layout-allow-on-face` waives it.
Also reads a two-token `object-position` whose first token is "50%" as the
horizontal one.
Co-Authored-By: Claude Fable 5.2 <noreply@anthropic.com>
* feat(cli): measure cuts names the shot a take resumes
A shot that returns to an earlier camera setup after at least one other
shot (a wide take, a close-up cut into it, the wide take again) carries
`continues`: the index in `shots` of the shot it resumes. It is read from
the signatures `cuts` already decodes, by the scene's edges, so a person
who has moved or an exposure that drifted does not hide the match.
Co-Authored-By: Claude Fable 5.2 <noreply@anthropic.com>
* feat(cli): measure hands follows a hand through a clip
`measure hands <video>` reports where a hand's palm (with the hand's
size), index fingertip or pinch is in each sampled frame of a stretch of
up to 15 s, from MediaPipe's hand landmarker. A frame with no such hand
is null, never filled in. The landmarker runs in the CLI's headless
Chrome on a page answered from disk; its code and model are not shipped
and are downloaded on first use, pinned by size and sha256, into the
trusted cache.
Co-Authored-By: Claude Fable 5.2 <noreply@anthropic.com>
* fix(cli): text_over_face is info only, and a stalled OpenCV download no longer stalls check
The face detector can take texture for a face, so text_over_face is
reported as info however much of the face is covered and never fails
--strict.
check passes its deadline and a 30 s limit into the detector's first-use
OpenCV download. A download that does not answer costs the face pass
only: faceCheck is { ran: false, reason }, the other findings are kept
and the process exits.
Co-Authored-By: Claude Fable 5.2 <noreply@anthropic.com>
---------
Co-authored-by: Claude Fable 5.2 <noreply@anthropic.com>
* fix: refuse framework build output and service-account files; lint skips private compositions
Review follow-ups:
- Hidden framework build-output folders (.next, .nuxt, .output, .svelte-kit,
.vercel, .netlify, .wrangler, .astro, .turbo) are private whatever the file
type, since their scripts can carry inlined server environment values.
- credentials.json and common service-account key names are private.
- Lint's compositions/ walk skips private files and folders, and an explicit
lint entry that is a private file is refused.
- New lint tests link .git/m.json, .mcp.json and a .hyperframes record as an
import map; they fail when lint's private-file check is removed.
* fix: a hidden file is private whatever its type; files in hidden folders keep the asset rule
* fix(lint): derive the root duration with the parser's timing reader
`deriveDurationFromClips` read `data-start` with a raw `Number()`, so a clip
authored at `data-start="-2"` produced an end of `-1`. `resolveCompositionDuration`
only counts positive ends, so the clip vanished from the derivation and the
composition was reported as having no duration source at all — a hard error that
blocks strict renders, even though the parser clamps the same start to zero and
renders the clip for its full length.
Read the start through `readClipTiming`, the same contract parser the renderer
uses, and keep the media-duration default for untimed images.
* fix(lint): derive the root duration with the parser's timing reader
`deriveDurationFromClips` read `data-start` with a raw `Number()`, so a clip
authored at `data-start="-2"` produced a negative end and vanished from the
derivation. Read the start through `readClipTiming`, which clamps it to zero,
and keep `readAuthoredDurationSeconds` for the authored length so a valid
`data-end` still backs an unparseable `data-duration`.
A provider key from a project .env is still used when no own credential
competes. Capture vision (OpenRouter, Gemini, Google and both Vertex parts),
snapshot --describe, Gemini speech and Lyria music now print one note per key
before it is first used, naming the variable and the escaped .env path, as
the ElevenLabs note does. The ignoring notes escape the path too, and the
media-use skill gets a generated copy of the CLI's terminal-text helper.
`subcomposition_blanks_before_host` read `data-start` and `data-duration` with a
raw `Number()`, so a mount with a reference start (`intro + 0.5`) looked like it
started at 0 and was reported as leaving a blank tail that may not exist. A
negative start was measured from the raw value, so the reported gap and the
`data-duration` fix hint were wrong in the other direction.
Read the mount through `readClipTiming`, the same contract parser the renderer
uses: a runtime-resolved start is skipped (its end cannot be known statically),
and a negative start is measured from zero.
* test(studio): a sealed preview's timeline rows bind to their elements
* fix(studio): timeline rows in a sealed preview know their element, source file and audio group
A media-proxy request with neither Sec-Fetch-Site nor a Referer naming the
host was treated as same-site. Play, the static project server and Studio now
require a positive signal and refuse the request otherwise. The check
command's own re-request of failed media sends a Referer for its origin so it
keeps working.
— Rames
Co-authored-by: Claude Opus 5.5 <noreply@anthropic.com>
* test(studio): scrubbing a sealed preview plays the music track
* fix(studio): scrubbing the playhead plays the music track in a sealed preview
* fix(core): the scrub uses the runtime's wall-clock timers and media-time writer
The blur's filter <svg> is appended to <html>, outside the body swap a
same-document re-init performs. A torn-down run left it (and
window.__hfMotionBlur) behind, so the next run's hf-mb-0 collided with
the stale id and url(#hf-mb-N) drew movers through the old filter
region, rendering them blank.
Fixes#7986
* test(studio): the edit bench measures an element inside a sealed preview
* fix(studio): the edit bench reads a sealed preview through its editing port
* fix(studio): the edit bench drops a preview reply that lands after a release or the next drag
* fix(studio): the edit bench pairs each frame's pushed geometry with the pointer at that moment
* fix(studio): the edit bench pairs Studio's outlines and the watched element by time, not arrival
* fix(studio): the edit bench starts a drag only once the preview has measured the element
* fix(producer): frames start drawing while the audio mix finishes
* fix(producer): keep the encode stage's comment share
* fix(producer): on machines with under 4 CPUs frames wait for the audio mix
* test(producer): a mix that fails during capture is reported as the audio stage's failure
* fix(producer): a mix that fails during capture names the audio stage as where the render failed
* fix(engine): the render file server never serves a project file as a service worker's script
* fix(producer): render, capture and inspector servers never serve a service worker's script
* test(studio): audio meters and group volume in a sealed preview
* fix(studio): audio meters and audio groups work in a sealed preview
* chore(inspector): raise the unpacked size budget for the preview's audio editing kinds
* test(studio): the sealed audio test serves a Studio-marked preview, as the editing port now requires
* feat(core): the preview can stream an element's geometry to the editor every frame
* refactor(core): the editing client hands unasked pushes to one function
* fix(core): geometry watches are capped per page; a lost port or failed measure stops nothing else
* fix(core): the preview measures watched geometry after the frame renders, not inside rAF
* fix(core): watched geometry is measured in the frame's resize-observer step, just before paint
* docs(core): a hidden preview's geometry pushes pause until it has a size
* test(core): keep the fake resize observer's note within the line limit
* perf(engine): check still frames on several pages at once so text films start sooner
* fix(engine): parallel still-frame check keeps its full time budget
* test(engine): give the Bun download check the minute its spawn already allows
* test(core): a held picture is drawn through a closed VideoFrame
* fix(core): a held video picture is drawn through a VideoFrame closed after the draw
* test(core): read the held frame's closed flag only once it is a VideoFrame
* test(core): the reloaded-video playhead test builds a smaller film so busy CI never times it out
* test(core): keep the playhead fixture note inside the comment line limit
A bare listSiteFiles now leaves out files and folders linked in from outside
the project; a caller that wants them passes "include". listSiteFilesForUpload
warns on the console when the caller passes no onNotice, so SDK callers learn
that files were left out. The regression harness keeps its fixtures' outside
links with "include".
— Rames
Co-authored-by: Claude Opus 5.5 <noreply@anthropic.com>