* fix(engine): keep Chrome's sandbox on for local renders where the host supports it
Chrome launched with --no-sandbox on every host. Keep the sandbox on
macOS, Windows and non-root Linux outside containers; drop it as root,
in Docker/Podman/Kubernetes, on Lambda and Cloud Run, and where Linux
restricts unprivileged user namespaces. --no-zygote now ships only with
--no-sandbox, since Chrome refuses it while sandboxed. A sandboxed Linux
launch that fails at startup retries once without the sandbox and warns.
HYPERFRAMES_CHROME_SANDBOX=1|0 overrides the choice.
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
* test(cli): cover the Linux sandbox retry in managed browser launches
The off-macOS closed-pipe case now passes --no-sandbox, so it still
pins "no seatbelt relaunch" rather than the new Linux sandbox retry,
which gets its own case.
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
* fix(engine): honor HYPERFRAMES_CHROME_SANDBOX=1 and latch the fallback on clear evidence only
With the override set to 1, a sandboxed launch Chrome refuses now fails
instead of retrying unsandboxed. A bare startup exit (TargetCloseError)
retries that launch without the sandbox but only latches the sandbox off
after a second one, so a single unrelated early kill no longer disables
it for the rest of a long-lived process. Chrome naming the sandbox in its
error still latches at once.
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
---------
Co-authored-by: Claude Opus 5.5 <noreply@anthropic.com>
A mover that moves further than its own width between frames leaves gaps in a
trail built from whole-frame blur-off poses; the shutter's smear lands in them and
read as a leak outside the trail (nightly seed 63098). The mask now adds the
shutter's sub-frame poses, captured in time order. Seed 63098 joins the default
seeds as the regression case.
Co-authored-by: Claude Opus 5.5 <noreply@anthropic.com>
* fix(cli): check hears a WAV whose header misstates its byte rate, as render plays it
A PCM WAV whose header byte rate is wrong (some speech generators write 2x) sent the silence decode's input seek past the file's end, so every clip past the middle was reported audio_clip_silent. Render already cuts such a file by decoded time (#7541); the byte-rate rule now lives in parsers and the CLI decoder seeks after decoding starts for those files.
* test(cli): keep the misstated byte-rate case with the other single-clip checks
* style(cli): format the WAV test helper
* style(parsers): keep the byte-rate rule's comment within the line limit
* chore: release v0.9.37
* docs(release): add #7576 to v0.9.37 notes
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
---------
Co-authored-by: Claude Opus 5.5 <noreply@anthropic.com>
* chore: release v0.9.35
* docs(release): note the render stop and container 403 from #7563 in v0.9.35
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
---------
Co-authored-by: Claude Opus 5.5 <noreply@anthropic.com>
* fix(cli,parsers): take helper programs only from install locations, never the project folder
FFmpeg, FFprobe, whisper-cli, parakeet-mlx, Python and system Chrome are now
found through one shared rule: an absolute PATH entry outside the working
directory, or a fixed install dir. A relative PATH entry and any folder
inside the working directory are skipped, on every platform. Windows walks
PATH itself instead of asking `where`, which lists the working directory
first.
FFmpeg discovery no longer falls back to `.hyperframes/bin` or to an
installer package in the project's node_modules; an installer package
installed next to HyperFrames still works. The env overrides are unchanged.
The CLI skill reference stops suggesting the project-local folder.
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
* test(cli): give the PATH-lookup tests a fixed PATH on Windows
Windows now walks PATH instead of running `where`, so tests that faked
`where` output found the runner's real python and cmake. Both tests now set
PATH to a temp folder holding only the programs they expect.
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
* fix: report a missing helper program instead of running it by bare name
When no trusted FFmpeg or FFprobe is found, the engine, the producer's
probes and Studio's waveform, peak and audio-track helpers now report
"not found" with the HYPERFRAMES_FFMPEG_PATH / HYPERFRAMES_FFPROBE_PATH hint
instead of handing the bare name to the OS lookup. Callers that degraded
on a missing binary still do: runFfmpeg returns a spawn_error result, the
GPU and version probes report none, and Studio's audio helpers fail soft.
The Lambda handler names its bundled ffmpeg and ffprobe by path, since
they live under the task root, which is the working directory.
brew, git and cmake for the whisper.cpp install, and the clipboard tool
for `hyperframes add`, run by the absolute path the trusted lookup
approved. The media-use engine gets a PATH holding only trusted folders.
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
* fix(engine): fail a missing FFmpeg the way a failed spawn always has
Throwing from getFfmpegBinary turned every caller's missing-binary path
into a synchronous throw: the streaming encoder's "failure result, not a
throw" contract broke, and unit lanes that run without FFmpeg crashed at
module load. With no trusted copy the getters now return an absolute path
inside HyperFrames' own install that is never created, named for the
override to set. Spawning it fails with ENOENT exactly as before, and the
OS still never looks the bare name up. The call-site guards and fixture
changes that the throw needed are reverted.
The whisper install tests match git and cmake by name and skip the brew
case on Windows, where the lookup walks the real PATH.
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
* test(engine): pin the found FFmpeg before the HDR test looks it up as macOS on Windows
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
---------
Co-authored-by: Claude Opus 5.5 <noreply@anthropic.com>
* feat(producer): fail a render whose variables the page does not declare
* chore(producer): keep the comment share and the dead-code audit clean for the variables check
The test checks that clips read from a URL are not held to the CPU-sized
prepare limit. On 32 or more cores that limit reaches the URL limit of 16,
so the test could not pass there. It now fixes the core count at 8.
* feat(cli): share rendered videos through unified reviews (#7135)
* feat(share): attach editable project sources to reviews (#7137)
* feat(share): measure local sharing outcomes (#7138)
* feat(cli): stage the sixty-day publish transition (#7136)
* feat(studio): share review pages from local preview (#7140)
Advertise the CLI sharing bridge before bootstrapping it so standalone Studio does not
request unsupported routes. Preserve origin and session checks.
Budget the intended sharing artifact: clean main packs at 8,060,519 bytes versus
8,162,979 with sharing (8,169,168 in CI). Required policy and Unicode tables, bundled
sharing code, and Studio controls account for the growth. Set the packed-only budget
to 8,577,627, following the 5% headroom convention; retain the unpacked cap and all
package checks.
* fix(share): persist refusals and improve CLI retry feedback
* fix(ci): restore render diagnostics and include sharing workspace
* fix(cli): keep sharing owner error codes stable
* fix(share): clarify update feedback and align audience changes
* fix(share): clarify updates and avoid scratch-file rerenders
* fix(cli): report active shares and preserve update channels
* fix(cli): resolve update channel when checking registry
* fix(ci): refresh sharing package budgets after rebase
* fix(share): require consent before uploading project files
* perf(engine): check still frames once per page and share the result with later sessions
* perf(producer): the probe skips the still-frame check unless its session captures
* chore(engine): keep the comment share of the deferred still-frame check files at their base
* fix(producer): the probe session's deferred still-frame check counts as stall-watcher activity
* docs(engine): the still-frame spot-check range is the task's span, not only its own frames
* fix(engine): a reused fast-capture probe session keeps still-frame reuse
* fix(engine): offset clips from a WAV with a wrong byte rate play the right sound to their end
A WAV header that states twice its real byte rate sent the mixer's input seek
to twice the clip's in-point: the clip played later words, then silence. Such a
source is now cut by decoded timestamps instead of by a byte seek.
* refactor(engine): let the byte-rate flag's name carry the seek rule
Long caption overlays plan thousands of verification screenshots, so the
verification budget clamped at its 300 s ceiling in every render worker. That
equals the producer's 300 s first-frame and session-init stall floor, so the
stall always won and the render failed before its first frame. Verification
fails closed on exhaustion (dedup is disabled for unverified runs and normal
capture proceeds), so a lower ceiling costs only some frame reuse.
Co-authored-by: Claude Sonnet 5.5 <noreply@anthropic.com>
* feat(engine): decouple transparent background from png capture format
PNG capture used to imply a cleared page background. A new
CaptureOptions.transparentBackground lets lossless opaque PNG capture
(4:4:4 MP4 output) keep the page background. Absent, it still follows
format === "png", so alpha output and motion blur are unchanged.
Opaque PNG skips drawElement, whose verification and worker-encode
paths are JPEG-only.
Refs #5555
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
* feat(engine): add 4:4:4 chroma option to getEncoderPreset
getEncoderPreset takes an optional chromaSubsampling ("420" by
default). "444" returns yuv444p for SDR MP4, so libx264 encodes the
High 4:4:4 Predictive profile and odd sizes need no even padding.
WebM, MOV and HDR presets ignore it. The ChromaSubsampling type is
exported for the producer.
Refs #5555
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
* feat(producer): chromaSubsampling render option with lossless png capture
RenderConfig.chromaSubsampling ("420" by default) opts an SDR MP4
render into 4:4:4. "444" encodes libx264 yuv444p and captures every
frame as opaque PNG: Chrome's quality-100 JPEG is already 4:2:0 on
beginFrame and screenshot capture, and drawElement can fall back to
screenshot mid-render, so PNG is the only capture that keeps the
colour. drawElement is turned off for these renders.
The probe and main capture options share resolveCaptureSurface, so
they cannot disagree on format, quality or background.
Formats other than mp4, GPU encoding and HDR output are rejected
before any work starts, auto-detected HDR sources fail before capture,
and distributed requests refuse 444. The default render is unchanged.
Refs #5555
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
* feat(producer,studio-server): accept chromaSubsampling on render routes
The shared parseEncoderOptions validates chromaSubsampling and answers
400 for "444" with a non-mp4 format, gpu, or force-hdr, so a request
that would come back 4:2:0 never starts a render. The Studio render
route, both Studio adapters and the producer HTTP server forward it.
The producer server also refuses "444" with outputDynamicRange "hdr",
which parseEncoderOptions cannot see.
No Studio UI control; the option is route-level like crf and hdrMode.
Refs #5555
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
* feat(cli): add --chroma-subsampling flag
`hyperframes render --chroma-subsampling 444` opts an SDR MP4 render
into full-resolution chroma (yuv444p with lossless PNG capture). The
default stays 420. The plan rejects 444 with a non-mp4 format, --gpu
or --hdr before anything renders, with a usage error that names the
conflicting flag.
The value reaches the local render request and, only when it is 444,
the Docker argv, so default Docker invocations are unchanged.
Refs #5555
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
* docs: document 4:4:4 chroma subsampling
Add a "4:4:4 masters" section to the rendering guide: when to use
--chroma-subsampling 444, why it captures PNG, the measured chroma gain
(large for text and UI, none for footage and gradients), its limits,
and a player compatibility table to be filled in from testing.
Document the flag in the CLI reference, the built-in rendering docs and
the hyperframes-cli skill reference (with the regenerated skills
manifest), and the chromaSubsampling option in the producer docs.
Refs #5555
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
* docs: add 4:4:4 player compatibility results
Fill the 4:4:4 compatibility table from testing H.264 High 4:4:4
Predictive output. Chrome 155, Edge 155, VLC 3.0, Safari on iOS 26.6
and Safari 26.6 on macOS play it, and so does AVFoundation on macOS
26.6, the framework QuickTime Player plays through. Firefox 157 on
Windows and both Windows media players do not.
Refs #5555
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
* docs: note the measured render cost of 4:4:4 output
Replace the vague "slower capture" note with measured numbers: a text
and UI composition rendered in about twice the default time, full-frame
footage in about three and a half times, because PNG encoding cost grows
with image detail.
Refs #5555
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
* fix(producer): reject chromaSubsampling 444 in distributed render config
Distributed configs have no chroma field and validateDistributedRenderConfig
ignored unknown keys, so a JS caller passing chromaSubsampling: "444" to the
Lambda or Cloud Run SDK got a 4:2:0 file with no error. Reject it, and make
the rendering guide say so precisely.
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
* test(producer): check a 444 render reaches the encoder as yuv444p
Every helper had tests, but nothing checked the orchestrator passes
chromaSubsampling through, so dropping it from the encoder preset or capture
surface would turn 444 renders back into 4:2:0 with all tests green. Render a
small fixture with "444" and with the default and check pix_fmt with ffprobe.
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
* refactor(producer): move the 444 drawElement gate into a helper
Keeps runCompileStage under the fallow complexity threshold.
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
* chore: keep comment share at or below the merge-base
comment-ratchet failed on 11 files this PR touched. Keep the 4:4:4
rationale once in chromaSubsampling.ts, move the distributed-render
reason into its error message, and cut the rest.
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
* test(producer): check a 444 render captures full-resolution chroma
The encoder check alone passes when chromaSubsampling is dropped from the
capture surface: frames are captured as JPEG and encoded yuv444p with
4:2:0 colour. Put a red/blue edge at an odd x, inside a 4:2:0 chroma
pair, and require the two pixels to differ in Cb.
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
* chore(producer): trim the chromaSubsampling.ts header to the package comment share
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
* fix: finish switching to capturesAlpha from #6262
The merge that adopted main's transparent / capturesAlpha left these files
uncommitted, so resolveCaptureSurface still returned transparentBackground.
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
* refactor(engine): use transparent / capturesAlpha from #6262
main added CaptureOptions.transparent and capturesAlpha (#6262), which do
what this PR's transparentBackground did. Use them, keep the PNG check in
drawElementWorkerEncodeEligible, and re-pin test-classification.mjs and
the skills manifest against current main.
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
* chore(producer): cut the 4:4:4 comment blocks to one to three lines
The reasoning lives in the PR description with the measurements.
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
* refactor: reconcile 4:4:4 chroma with latest main
Keep main's video-layer capture overrides, template entry resolution,
ProRes profile parsing and blur-differential tests alongside the chroma
option, and fold the encoder sub-parsers into one loop.
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
* chore: keep main's compile-stage tests and regenerate the skills manifest
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
---------
Co-authored-by: Claude Opus 5.5 <noreply@anthropic.com>
* fix(lint): flag a script that calls gsap before GSAP loads, and say so when a render fails on it
* fix(lint): judge the first gsap call by when it runs, so a listener after a deferred GSAP passes
* fix(lint): keep the gsap timing helper's comment to two lines
* fix(producer): build the render job before taking a render slot
A request whose options fail the strict render-request validator now gets
a 400 on both the blocking and streaming routes, and its inline project
directory is removed. Validate workers up front like the other overrides.
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
* fix(producer): write compiled sub-compositions only inside the compiled directory
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
* fix(engine): keep media work files inside their directory for any element id
Map a media element id to one plain path segment before it names a frame
directory or an intermediate audio file. Ids that already are one plain
segment map to themselves, so existing paths stay the same; the producer
and the distributed plan derive the same segment.
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
* fix(engine): listen on loopback by default in the engine file server
The file server feeds the co-located capture browser, which loads it from
localhost. A caller that wants another interface passes hostname.
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
* fix(producer): refuse cross-origin browser posts to the standalone render server
A web page on another origin can no longer start a render or lint through
the server's POST routes. Requests without an Origin header (CLI tools,
server-to-server callers) and same-origin pages are unchanged.
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
* chore(engine): trim comments on the media path segment and file server host
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
* fix(producer): trust the browser's Sec-Fetch-Site verdict for render server posts
A same-origin page behind a reverse proxy that rewrites the Host header sent an
Origin that no longer matched Host, so the cross-origin guard refused it. The
guard now uses Sec-Fetch-Site when the browser sends it and falls back to the
Origin and Host comparison only for browsers that do not.
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
* fix(engine): keep generated media path names apart from plain ids and within filename limits
A plain media id that already ends like a generated name now takes the hashed
branch too, so it can no longer share frame folders or audio work files with
the unsafe id that produced that name. The readable part of a generated name
is capped at 64 UTF-8 bytes before the digest, so long or multibyte ids that
contain separators stay within the 255-byte filename limit.
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
---------
Co-authored-by: Claude Opus 5.5 <noreply@anthropic.com>
* test(engine): split the frame extractor tests so each file stays under the flake gate budget
* test(engine): cut the comments the frame extractor test split carried over
* fix(engine): a clip shows a new source frame on every output frame it covers
* refactor(engine): shorten the frame count doc to two lines
* style(engine): collapse the single-pass ffmpeg call the formatter wants on one line
* fix(engine): short clips from Apple-encoded videos keep their last frame
* refactor(engine): name the end-of-source hold and frame bound instead of commenting them
* fix(engine): frame ranges past a source's end stay empty with the held final frame
* test(engine): move the final-frame test into its own file
* test(engine): nightly motion blur run over generated compositions
A seeded generator of text-free compositions combines 19 features (nested
canvas, overflow, clip path, scroll container, callbacks, a last-child rule)
and checks the two pixel invariants on auto: outside the trail at two holds
and at a moving time, inside the trail at a moving time. The runtime lane
runs seeds 1 to 3; motion-blur-nightly.yml runs 200 a day on the Chrome 153
pin and on stable, and opens one issue per failing seed.
Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
* test(engine): the nightly records every failure, ignores noisy references, caps its issues
A crash, a timeout or a launch failure is recorded before the job goes red; a
failing check whose blur-off reference disagrees with itself is reported as
unstable instead of failing; the report job moves into a tested script that
fetches open titles once, caps first, and opens one systemic issue above 5 seeds.
Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
* test(engine): the nightly report resists injected failure text and keeps a crashed leg's record
Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
* fix(engine): nightly report escapes backslashes, test strips tags to a fixpoint
Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
---------
Co-authored-by: Claude Sonnet 5.5 <noreply@anthropic.com>
* fix(cli): staging folders beside a project path no longer fail past 260 characters on Windows
mkdtemp does not get the long-path prefix that mkdir does, so every staging folder
made beside a project or output path failed once its full path passed 260 characters.
They now come from one helper, createStagingDir in @hyperframes/core/atomic-file, and a
scan test fails on a new mkdtemp beside a path.
* fix(cli): give mkdtemp the long-path form instead of replacing it
CodeQL treats mkdtemp as the safe way to make a folder under the system temp dir and
flagged every file written into a folder from the mkdir-based helper. createStagingDir
now calls mkdtemp with the long-path form of the path on Windows, so both hold.
* fix(cli): leave non-Windows paths alone when making a staging folder
The long-path form is now chosen by the shape of the path, not process.platform,
so tests that pretend to be Windows keep working and the comment share does not rise.
* fix(core): a staging folder keeps a Windows path that already names its namespace
* fix(core): a staging folder keeps a Windows device path as the caller gave it
* fix(core): the staging folder helper's comment fits the line limit
* fix(engine): hlg footage with a large header sei also tone-maps at hlg's white
* fix(engine): say in the read's own doc line why it streams
* test(engine): the header-SEI HLG fixture encodes without b-frames, so it muxes on windows
* fix(producer): page timers during a render run on film time
* test(producer): a regression film whose timer bars must follow film time
* test(producer): schedule the timers regression film in CI shards
* fix(producer): keep setup timers on the wall clock until the page reports ready
* fix(producer): keep the renderer's own waits and deadlines on the wall clock
* test(engine): fail CI on a bare timer in code the engine runs in the page
* fix(core): type the wall-clock timers like the global timers they replace
* chore(engine): drop the comment on the shim's window type