Commit Graph
694 Commits
Author SHA1 Message Date
Miguel Ángel 73e65e2c78 fix(engine): a background image that never finishes decoding no longer stalls the frame (#6972)
* fix(engine): a background image that never finishes decoding no longer stalls the frame

* fix(engine): capture tolerates a page that returns no list of late background images

* fix(engine): a background decode timeout is reported at every caller, url redacted

* fix(engine): a relative background url keeps only its path in the decode timeout report
2026-11-04 20:41:50 +00:00
WaterrrForeverandClaude Opus 5.5 d4e4b07e3c fix(cli): a wedged render trips its 60 s watchdog, one local render at a time, and fonts the cloud can't resolve are flagged (#7168)
* fix(producer): a wedged effect scan or screenshot-session open trips the 60 s stall watchdog

The sequential streaming watchdog raced only the capture call. Session init
(where the fast-capture effect scan runs) and opening the screenshot session
for effect frames waited on CDP's protocol timeout instead, which scales with
output area up to 30 minutes, so a starved page hung a render for ~25 minutes
before the watchdog saw the next frame. The effect scan now gives up when a
chunk outlasts its 120 s budget, opening the effect-frame session gets its own
no-progress window, and session init gets a 300 s one; each trip retries on a
fresh session like any other stall.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>

* feat(cli): one local render at a time per machine; a second waits and says for whom

Renders started side by side from different sessions starve each other until
frames stop landing. `hyperframes render` now takes a machine-wide slot (a lock
file in the HyperFrames cache directory, held by pid) after its preflight and
holds it for the render or the whole batch. A second render waits and prints
the pid and project it is waiting behind; `--no-wait` fails at once instead.
A holder whose process is gone is taken over, and HYPERFRAMES_RENDER_LOCK=off
restores side-by-side renders. `--workers` is unchanged.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>

* fix(lint): flag fonts a cloud render cannot resolve, including the font shorthand

Lint read only `font-family`, so `font: 500 16px "PingFang SC", sans-serif`
passed while the renderer, which reads the shorthand too, drew the installed
Mac font locally and the cloud refused it. The shorthand now counts for
font_family_without_font_face (its parser moves to @hyperframes/parsers so
core and lint share one), and a new font_face_local_only warning names an
@font-face whose only sources are local(): it renders here and falls back in
the cloud. The rule's hint and the format reference stop recommending local()
for OS fonts.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>

* fix(cli): a cloud render that refuses a font says which project files use it

The cloud's "fonts that could not be resolved: PingFang SC" named no
composition. For a render submitted from a local project, the failure now
lists each refused family with the project files that name it, and says how
to ship the font so the cloud can use it.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>

* chore(cli): keep comment shares and exports within the gates, and split the single-render notes out of executeHeldRender

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>

* fix(parsers): read a spaced line-height slash and var() before the size in the font shorthand

`font: 16px / 1.5 Inter` was read as the family `/ 1.5 Inter`, and
`font: var(--weight) 16px Inter` as `16px Inter`, because a var() counted as
the size. The parser now follows the shorthand grammar: optional style,
variant, weight and width keywords (or var()), then a length, percentage,
keyword or calc() size, then a `/ line-height` in any spacing. When no size can
be told apart from a var(), it says so: lint skips that declaration instead of
reporting a missing font, and the renderer keeps its best guess.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>

* fix(cli): say the render slot is one per user account, not per machine

The lock lives in the account's HyperFrames cache folder, so renders by two
user accounts never queued behind each other while the messages, flag help and
docs said "this machine". They now say "per user account" and that
HYPERFRAMES_CACHE_DIR set to a shared folder shares the slot across accounts.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>

* fix(cli): reclaim a render lock or takeover file left half-written

A lock or `.break` file that exists but cannot be parsed (a crash mid-write
where hard links are unavailable) was never reclaimed: a waiting render waited
forever and --no-wait refused forever. Once such a file is older than any real
write (5 s by mtime) it counts as abandoned: the lock goes through the same
`.break` takeover as a dead holder's, and a takeover file is removed.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>

* fix(producer): opening the capture session counts against the setup stall budget

The sequential streaming attempt opened its own capture session (Chrome launch
and new page) before the setup watchdog and outside the attempt's cleanup, so a
wedged launch still waited for the protocol timeout. Opening now shares the
300 s setup window with session initialisation, a trip fails the attempt like
any other sequential stall, and a session that finishes opening after its
attempt gave up is closed instead of leaking a browser.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>

* chore(parsers): keep the shorthand result type module-private

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>

* fix(cli): reclaim an unreadable render lock only when its writer is provably gone

Where hard links are unavailable the lock is created by an exclusive open and
then written, so a contender paused between the two leaves an unreadable lock
while it is still alive. The 5 s mtime grace took such a lock over, and both
processes then held the slot. Each contender now writes an owner marker under
a name only it can take (pid plus random suffix, holding its process identity)
before it creates the lock, keeps it while it holds the slot, and removes it
otherwise. An unreadable lock or `.break` is reclaimed only when no other
contender's marker belongs to a live process; markers of dead processes, or of
a reused pid, are deleted. No reclaim is decided by time alone.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>

* refactor: split acquireRenderLock and the streaming-stage session stub under the complexity gate

acquireRenderLock hands contender setup and a single marked claim to their own
functions, and the test stub for createCaptureSession splits its held-open
cases from the fake session it builds, so neither exceeds Fallow's cognitive
or CRAP thresholds. Behaviour is unchanged.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>

* chore(ci): raise the CLI and engine size budgets for the watchdog, lock and font-lint additions

Main's CLI unpacked size was already ~0.99% over its budget; the render lock and
owner markers push it past the 1% tolerance. The CLI unpacked budget takes the same
value as #7169 and #7170 (25,159,107) so the PRs merge cleanly. The engine's packed
size grows by about 4.7 KB for the effect-scan and session-open watchdogs; its packed
budget moves to 5% above the measured 467,097, as the budget file's headroom rule sets it.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>

* fix(parsers): a var() size glued to its line height is the shorthand's size

`font: 700 var(--size)/1.1 "Inter"` read as no family at all: the token was
tested whole against var(), and the slash after it hid that it was the size,
so the renderer injected no face for Inter. A var() followed by `/ line-height`
(glued or spaced) can only be the size, and is now read as one.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>

* refactor(parsers): split the shorthand size search out of parseFontShorthand

Keeps parseFontShorthand under Fallow's cognitive-complexity gate; behaviour is unchanged.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>

* fix(cli): render lock never removes another render's takeover, knows a reused pid, works in a shared folder and on Windows

- A `.break` takeover file is removed only by the render that wrote it. One
  whose writer is gone stops the render with the file to delete, instead of
  being removed on an earlier reading, which could remove a live `.break`
  written since and let two renders hold the slot. The takeover re-reads the
  lock under its own `.break` right before replacing it.
- The lock record keeps its holder's process start time, so a pid that now
  belongs to another process (an OOM-killed render in a container with a
  persisted cache) no longer holds the slot forever.
- The `locks` folder is created writable for every account, so accounts
  sharing HYPERFRAMES_CACHE_DIR take turns instead of the second failing with
  EACCES; a folder this account cannot write in says how to fix it, and
  another account's file that cannot be removed is left, not fatal.
- Windows: no PowerShell start-time lookup per check (pid liveness only), a
  file another handle holds (EPERM/EBUSY/EACCES) reads as held, a lock that
  vanished is retried once instead of in a tight loop, and a wait stops when
  its signal aborts. The tests end every acquire they start before removing
  their folder, and the paused contender writes through its open descriptor.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>

* chore(ci): raise the lint packed size budget for the font-shorthand rule

With main's audio-attribute rule (#7169) merged in, the font-shorthand and
local()-only font findings take @hyperframes/lint's packed tarball to
181925 bytes, over the 179338 budget. The new budget is that measurement
plus the usual 5% headroom.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>

---------

Co-authored-by: Claude Opus 5.5 <noreply@anthropic.com>
2026-11-04 18:41:56 +00:00
Vance IngallsandClaude Sonnet 5.5 d36cad7985 test(engine): pixel invariants and fixtures that guard default-on capture blur (#7108)
* test(engine): pixel invariants for capture blur against blur off

Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>

* test(engine): fixtures for every capture blur failure class seen so far

Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>

* test(engine): nested canvas fixture reproduces #6975, sharp-tile fixtures have no moving times

Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>

* test(engine): capture blur must match blur off outside the trail and the shutter average inside it

Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>

* test(engine): differential tests pin known bugs by symptom, history test checks the reference frame

Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>

* test(engine): a playing preview keeps changing with blur on

Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>

* test(producer): a multi-worker blur render must match blur off outside the trail

Renders five blur fixtures through the real producer as a PNG sequence with 4
workers (contiguous blocks, three of them starting mid-film, the #6967
condition): blur off twice, blur on once. Outside the trail of everything that
moved, blur on must equal blur off in every frame with two neighbours. The
callbacks and scroll-list known differences are pinned by symptom.

Import route: a relative import of blurDifferential.ts, fixtures.ts and
thresholds.ts from packages/engine/src/services/__fixtures__. The producer
tsconfig excludes test files, so I type-checked the file with a temporary
tsconfig (rootDir widened); no error. No package subpath was needed.

RENDER_OUTSIDE_MAX_MAE: render noise is 0 (blur off, twice, bit-identical), the
rewind mutation measured 111.085 when caught, so the 1.0 floor applies.

Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>

* test(producer): render callbacks with workers that start between its calls

With 4 workers the blocks started at 0, 15, 30, 45, each on a call, so the
rewind mutation showed in a render only 3 times in 5. Seven workers over 60
frames start at 0, 9, 18, 27, 36, 45 and 54, two of them strictly between the
calls at frames 16 and 30; the mutation then fails callbacks in 8 of 8 runs
(worst MAE 97.02), the clean build in none.

A new case checks the partition with distributeFrames. The #list and #label
rects now come from the fixture's markup, and MEASURED_RENDER_REWIND_MUTATION
is 97.02.

Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>

* test(engine): blur pins bound the symptom, liveness detector reports blindness, fixtures time out

Pinned known bugs now require every bad tile inside the pinned region and a worst
MAE within half to double of the measured one. tileTouches, Rect and the band check
move into blurDifferential.ts with a dpr 2 unit test. The blank-frame census counts
canvases it cannot read and asserts none, and names both readings when no blank frame
is seen. No console.info on passing runs. Fixtures cases get a 30 s timeout.

Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>

* test(producer): scroll-list render case bounds the race, pins share the engine helpers

The scroll-list loss depends on timing per worker block, so the case now requires
frames 2..27 clean and any later bad tile inside #list, without requiring the loss.
The callbacks pin keeps requiring its symptom, bounds it to the label and to half to
double of its measured size, and its message names the entry to delete. Wording says
multi-worker, not 4-worker.

Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>

* build(engine): keep the blur test helpers out of the published tarball

Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>

* test(engine): print the worst outside tile of each arm to explain the CI text diff

Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>

* test: both arms draw grayscale text so host subpixel settings are not read as blur

Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>

* test(producer): run the multi-worker blur render alone so it cannot skew other Chrome tests

Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>

* test: re-pin the producer lane runner after splitting out the heavy blur render

Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>

* test(engine): read the blank-frame pin from a wrap observer, not an animation frame poll

The pin sampled in requestAnimationFrame, so it could miss the gap between the
wrap and the first draw. A MutationObserver now reads the output canvas the
moment the root is wrapped, which is deterministic, and every fixture must
report a wrapped root.

Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>

* test(engine): drop the blurs field no fixture could set to false

Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>

* ci: give the flake gate 60 minutes, it budgets runs by file count not time

Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>

---------

Co-authored-by: Claude Sonnet 5.5 <noreply@anthropic.com>
2026-11-04 17:55:07 +00:00
Miguel Ángel ac1948a88b fix(engine): a full disk during frame extraction says so, not that the video is broken (#7161)
* fix(engine): a full disk during frame extraction says so, not that the video is broken

* fix(engine): a pass that filled the disk is not decoded again in software
2026-11-04 14:45:56 +00:00
Miguel Ángel 67d11c0a5c fix(engine): a script the page cancelled is not a failed load (#7093) 2026-11-03 15:00:39 +00:00
Miguel Ángel dec465949b feat(engine): a script-load failure names where the script came from and why it failed (#7088)
* feat(engine): a script-load failure names where the script came from and why it failed

* fix(engine): keep the script-load cause helpers private and within the engine size budget
2026-11-03 13:54:20 +00:00
James RussoandClaude Opus 5.5 112ba53302 fix(studio): motion blur falls back for a WebGL canvas Studio reaches first (#7060)
* fix(core): motion blur notices a WebGL canvas the Studio page touched first

When a same-origin host page (Studio) reaches a preview element before the
scene does, for example through a MutationObserver record, Chrome gives that
element the host's prototype. The scene's getContext("webgl") then ran the
host's unpatched getContext, so the canvas never reached the accelerated
canvas set, capture motion blur stayed on, and the WebGL canvas froze during
preview playback.

The tracker now records a canvas in the set of the canvas's own window, and
installs itself in a same-origin parent too, compiled with the parent's own
Function. Cross-origin parents are skipped.

Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com>

* fix(studio): track accelerated canvases in Studio's window, not the embedder's

The preview runtime no longer installs the canvas tracker in its parent
window. That ran on every preview boot, so any same-origin page embedding
the player got its getContext wrapped, and a host CSP without
unsafe-eval reported a violation on each load. Studio now installs the
tracker in its own window when its Player module loads, and core
exposes it at @hyperframes/core/page-motion-blur.

Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com>

* chore: keep the comment share of the touched files from rising

Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com>

---------

Co-authored-by: Claude Opus 5.5 (1M context) <noreply@anthropic.com>
2026-11-03 03:59:23 +00:00
Miguel Ángel 81b93cf055 fix(cli): snapshot stops Chrome decoding videos it already replaces with extracted frames (#6949)
* fix(cli): snapshot stops Chrome decoding videos it already replaces with extracted frames

* fix(cli): a held video keeps its intrinsic size in snapshot, as in render

* fix(cli): shorten a comment line in the held-video hints
2026-11-03 01:14:27 +00:00
Miguel Ángel 3bb0a9a5b5 perf(engine): skip the screenshot on frames the page reports unchanged in beginframe capture (#7027)
* perf(engine): skip the screenshot on frames the page reports unchanged in beginframe capture

* fix(engine): beginframe reuse never returns a frame older than a cross-frame page change

* fix(engine): the BeginFrame reuse test gets a headless shell in the flake gate

* fix(ci): run the headless shell installer through its package

* fix(ci): install the headless shell with bunx, npx finds no bin in the workspace
2026-11-02 19:17:31 +00:00
Miguel Ángel 0bcd816d5b feat(engine): a chunk-fed encoder and the rule for which films may use it, off by default (#7029)
* feat(engine): a chunk-fed encoder and the rule for which films may use it, off by default

* test(engine): end the chunk encoder's ffprobe call with --
2026-11-02 17:53:57 +00:00
Miguel Ángel 6fd96ddd04 revert: stop releasing a WebGL context when its clip's window has ended (#7020) 2026-11-02 15:48:12 +00:00
Miguel Ángel 070780c695 fix(producer): a render stops when a capture session sees every composition script fail (#7009)
* fix(producer): a render stops when a capture session sees every composition script fail

* fix(producer): only capture workers decide a script failure; prep sessions stop without recording it

* fix(producer): a script failure in a capture worker still reports as the composition-script error

* style(producer): format the script-failure test
2026-11-02 15:46:50 +00:00
Jerrai 346f0e49fa feat(producer): report browser-computed reference backgrounds (#7007)
* feat(producer): report browser-computed reference backgrounds

Preserve one initial root/page reference across local, streamed and distributed
render results without guessing from film pixels.

— Jerrai

* fix(producer): preserve plan compatibility and optional inspection

Keep reference metadata outside the v2 manifest hash and read it from the
verified execution-plan artifact. Static planning uses a non-gating page
inspection instead of requiring render-worker capabilities.

— Jerrai

* fix(producer): poll readiness independently of animation frames

Use timed polling while the render clock parks animation frames. Cover readiness
that changes after the first check with a short real-browser regression.

— Jerrai

* fix(producer): budget measured reference metadata runtime growth

Producer adds 2,228 compressed bytes over current main. Tests, fixtures and source
maps are already absent from its dist-only tarball. Allow 7,766 bytes of headroom
above the verified 837,234-byte payload while retaining the unpacked limit.

— Jerrai
2026-11-02 14:42:18 +00:00
Miguel Ángel 26d6e3eef1 fix(engine): a scene that has ended gives up its WebGL context so the next scene is not slowed (#6984)
* fix(engine): a scene that has ended gives up its WebGL context so the next scene is not slowed

* build(engine): raise the engine package size budget for the WebGL release module

* chore(engine): shorten the WebGL release comment

* fix(engine): a scene gives up its WebGL context only when the runtime says its window ended

* chore(engine): drop a comment the type already says

* chore(engine): shorten a comment line
2026-11-02 07:50:16 +00:00
Miguel Ángel de6ec3811e fix: cache paths follow HYPERFRAMES_CACHE_DIR (#6716)
* fix: cache paths follow HYPERFRAMES_CACHE_DIR

Every place HyperFrames keeps downloaded or built files now takes its
folder from one helper, hyperframesCacheDir() in @hyperframes/core. The
default stays ~/.cache/hyperframes; HYPERFRAMES_CACHE_DIR moves it.

* fix: register the cache-dir subpath for bun and node, and build inspector from core source

* test: the cache-dir override test uses a folder that is absolute on every platform

* fix: the opencv cache follows HYPERFRAMES_CACHE_DIR

* fix(cli): npm installs run in their staging dir, so no cache path reaches a command line

* fix(cli): whisper.cpp is cloned inside its build dir, so no cache path is a git argument

* test(cli): the whisper clone test finds no system whisper on Windows either
2026-11-01 22:44:11 +00:00
Miguel Ángel d1d631f60a fix(producer): an export over the ceiling limits its peaks and keeps the mix's level (#6940) 2026-11-01 17:18:48 +00:00
Miguel Ángel 90f7fe624f fix(engine): GPU renders use the NVENC preset names the host's ffmpeg lists (#6930)
* fix(engine): GPU renders use the NVENC preset names the host's ffmpeg lists

* fix(engine): one ffmpeg stdout reader for encoder detection and preset listing

* ci(engine): raise the engine unpacked size budget for the NVENC preset reader
2026-11-01 15:46:57 +00:00
Miguel Ángel 9aaa3ae675 fix(engine): a video with no source no longer holds capture for 45 seconds (#6926) 2026-11-01 11:16:43 +00:00
Miguel Ángel 58428b44bc fix(engine): passthrough keeps frame count and accepts films whose audio outlasts the picture (#6920)
* fix(engine): passthrough output follows the page frames and holds a short video's last frame

* test(engine): a film whose audio outlasts its video still qualifies for passthrough

* test(engine): passthrough encodes one output frame per page frame when the video is shorter

* test(engine): end the ffprobe options before the file in the passthrough frame count test
2026-11-01 10:42:32 +00:00
Miguel Ángel 98520366a6 feat(producer): opt-in video layer passthrough for a lone full-canvas video (#6914)
* feat(engine): composite a source video inside the streaming encoder

* feat(engine): opt-in flag and rule for compositing a lone full-timeline video

* feat(producer): opt-in video layer passthrough for a lone full-canvas video

* feat(producer): launch the probe, drop its page and capture PNG when passthrough is on

* refactor(engine): trim the passthrough doc comments to one line

* fix(producer): refuse passthrough when a wrapper or sub-composition paints a background

* chore(producer): mark the in-page layout check as one deliberate unit

* fix(engine): a video left out of capture no longer blocks static-frame dedup

* refactor(engine): shorten two long comments in the static-frame eligibility scan
2026-11-01 05:17:00 +00:00
Miguel Ángel 94849bf1e0 refactor(engine): one builder for the video frame filter chain (#6908)
* refactor(engine): one builder for the video frame filter chain

* refactor(engine): keep the filter chain builder module-private until it has a caller
2026-11-01 00:54:54 +00:00
Miguel Ángel f486ad6d49 fix(engine): ffprobe read intervals never carry an exponent (#6909) 2026-11-01 00:53:35 +00:00
Miguel Ángel ef0007b003 test(engine): run the non-PNG probe test on a fake clock (#6907) 2026-11-01 00:16:48 +00:00
Miguel Ángel 32de0196d5 fix(producer): a failed video extraction names which clip files failed (#6905)
* fix(producer): a failed video extraction names which clip files failed

* fix(producer): the extraction source label hides scheme payloads and drive paths

* style(producer): format the extraction source label
2026-11-01 00:09:14 +00:00
Miguel Ángel f3cdf2b473 fix(engine): scale static-frame verification budget with the job (#6901)
* fix(engine): scale static-frame verification budget with the job

* fix(engine): keep comment share flat

* fix(engine): drop added comment

* fix(engine): time seek in verify budget, state the policy
2026-10-31 22:48:26 +00:00
Miguel Ángel bb3c3b2118 fix(producer): render telemetry reports beyond-viewport capture as the workers used it (#6702)
* fix(producer): render telemetry reports beyond-viewport capture as the workers used it

* fix(producer): apply the sessions' beyond-viewport value at the summary, on every capture path

* chore(engine): drop a comment so the types file's comment share does not rise
2026-10-31 21:42:26 +00:00
Miguel Ángel 47fe68562f fix(engine): nested video clips on a frame boundary export every source frame (#6893)
* fix(engine): nested video clips on a frame boundary export every source frame

* fix(engine): drop comment from ffmpeg time formatter
2026-10-31 20:08:23 +00:00
Miguel Ángel 60f711686c fix(producer): auto renders with color-graded media stay SDR instead of promoting to HDR (#6671)
* fix(producer): auto renders with color-graded media stay SDR instead of promoting to HDR

* fix(producer): keep auto renders SDR when a graded canvas is present
2026-10-31 16:16:06 +00:00
Jerrai 1116077dab fix(cli): capture treats only 192.0.0.0/24 and 192.0.2.0/24 as reserved, via one shared list (#6853)
* fix(cli): capture's public-address check uses the engine's list; 192.0/16 is not all reserved

Only 192.0.0.0/24 and 192.0.2.0/24 are special-use. The capture proxy blocked all of
192.0.0.0/16, so sites on WordPress VIP (192.0.64.0/18, e.g. nasa.gov at 192.0.66.108)
failed every capture with net::ERR_TUNNEL_CONNECTION_FAILED. isPublicIPv4 now reads the
engine's isBlockedNetworkHost, so capture and asset downloads share one list.

— Jerrai (cutroom-debug)

* refactor(engine): one special-use network list, in a light subpath capture imports

Importing all of @hyperframes/engine into capture's publicNetwork slowed the lookup child's
start-up past publicNetwork.process.test's 6 s mid-lookup exit. The list and
isBlockedNetworkHost move to engine/src/utils/networkPolicy.ts, exported as
@hyperframes/engine/network-policy; urlDownloader and the engine index read it there.

— Jerrai (cutroom-debug)

* test(engine): pin 192.0.0.0/24 and 192.0.2.0/24 blocked, the rest of 192.0/16 public

— Jerrai (cutroom-debug)

* fix(cli): alias the engine's network-policy subpath in the CLI bundle

esbuild's root alias rewrote @hyperframes/engine/network-policy to src/index.ts/network-policy;
the exact-subpath list now carries it. The publicNetwork docstring is cut to keep the file's
comment share under its base.

— Jerrai (cutroom-debug)
2026-10-30 16:21:34 +00:00
Miguel Ángel 4da50e2218 feat(telemetry): render_complete splits capture time into seek, page, screenshot and encoder wait (#6839) 2026-10-30 14:55:06 +00:00
Miguel Ángel 536209da07 fix(producer): report extract_video progress while ffmpeg extracts frames (#6822)
Frames ffmpeg has written now reach the render's stage progress, so a long source video no longer leaves the render silent between extract_video and capture.
2026-10-30 11:23:59 +00:00
Miguel Ángel 279d40dcd7 test(engine): the rotated-clip fixture builds on ffmpeg older than 6 (#6811) 2026-10-30 09:27:00 +00:00
Miguel Ángel 10a4ed56cb fix(engine): a video clip starting between frames shows its media on the right frame (#6759)
* fix(engine): a video clip starting between frames shows its media on the right frame

* chore(engine): trim the helper comment to one line

* chore(engine): drop the helper comment

* test(engine): extract once per start in the off-grid clip test

* fix(engine): a looped clip keeps its loop origin when the start is off the frame grid

* test(engine): three off-grid starts cover the failure modes and keep the flake gate under its limit
2026-10-30 09:01:21 +00:00
Miguel Ángel 47a1a92064 fix(cli): a missing registry item names the closest ones, and a blocked browser says how to allow it (#6799)
* fix(cli): a missing registry item names the closest ones, and a blocked browser says how to allow it

* fix(cli): let closestNames carry its rule in its name
2026-10-30 06:15:03 +00:00
Miguel Ángel 54c98b5906 fix(engine): a video on a non-square pixel grid renders at its display shape (#6772)
* fix(engine): a video on a non-square pixel grid renders at its display shape

* chore(engine): drop comments the names already carry

* fix(engine): a rotated clip with a non-square pixel grid keeps its display shape

* test(engine): the frame probes end their options with -- like every ffprobe call
2026-10-30 03:00:25 +00:00
Miguel Ángel 8fb08f2a7c fix(engine): a render no longer waits for a sub-composition timeline no script can register (#6764)
* fix(engine): a render no longer waits for a sub-composition timeline no script can register

* fix(engine): the timeline wait matches a twice-mounted id and a template-literal key
2026-10-30 02:56:22 +00:00
Miguel Ángel a3ff1c4902 revert(engine): late-starting videos play to their last frame (#6746)
Reverts #6736. Its end-of-clip read fails intermittently on Windows, and the fallback
then expects frames past the clip's end.
2026-10-29 14:14:21 +00:00
Miguel Ángel 22b53c0115 fix(engine): late-starting videos play to their last frame (#6736)
* fix(engine): late-starting videos play to their last frame

A video whose first frame is after timestamp 0 could end early (frozen
tail) or late: ffprobe's stream duration does not run from the first
frame in every container (fragmented MP4, Matroska). Such a video's end
is now read from its last packet, once, where its facts are probed.

* test(engine): the WebM-with-audio case measures its first frame from the file

* test(engine): the first-frame probe ends its arguments with the input file
2026-10-29 12:05:27 +00:00
Miguel Ángel e1a8c7f173 fix(engine): long films show progress during the effect check and never wait minutes on it (#6697)
* fix(engine): long films start capturing at once instead of after a full effect scan

* fix(engine): give the effect scan two minutes, under the app's stall limit

* fix(engine): show effect scan progress so a long scan reads as preparing, not stalled
2026-10-29 10:35:12 +00:00
Miguel Ángel be05c86932 perf(engine): encode high quality with the x264 fast preset (#6640)
* perf(engine): encode high quality with the x264 fast preset

* test(engine): name the NVENC p5 case by its preset, not the high tier
2026-10-29 06:40:21 +00:00
WaterrrForever cd003e2010 perf(engine): size render workers from measured heap and the container's CPU quota (#6641)
* perf(cli): give render the heap its auto workers need in small containers

Auto worker sizing caps capture workers at (V8 heap - 1024 MB) / 640 MB.
Node sizes its default heap from visible memory, so in a 10 GB container
the heap is 2,096 MB and every render captures with one worker, whatever
the core count.

When no --workers is given, no --docker, no heap was set by hand, and the
heap is the only bound holding workers back, render relaunches itself once
with --max-old-space-size set to what CPU and memory allow (capped at half
of memory). The engine exposes heapMbForAutoWorkers() for this.

* fix(cli): count a heap-relaunched render once, keep detached renders alive

The relaunched child skips the CLI's command telemetry, update and skills
notices, and app-history notice; the parent already records and prints
them. A detached render no longer gets SIGHUP forwarded, which its
default handler would treat as a kill. A heap set as --max_old_space_size
counts as set by hand.

* fix(engine): keep the desktop app's per-worker heap figure at 640 MB

Inside Electron the heap is a hard 4,192 MB cage, and that is where the
field OOM behind the old figure happened (#5149: 5 auto workers on a heavy
export). The new 320 MB figure is measured only in a system Node, so the
desktop app keeps 640 MB (4 workers there) until a heavy desktop export is
measured. Containers and plain Node keep 320.

* fix(engine): know the packaged desktop app by its client tag, which runs the CLI on plain Node
2026-10-29 06:17:07 +00:00
Miguel Ángel a5496b1887 fix(producer): a BeginFrame capture that draws no first frame in 20 s switches to screenshot (#6701)
* fix(producer): a BeginFrame capture that draws no first frame in 20 s switches to screenshot

* test(cli): cover the Chrome launch failure messages a failed render prints
2026-10-29 00:49:04 +00:00
Miguel Ángel 9830059bdb fix(engine): downloads refuse hosts that resolve to private addresses (#6571)
* fix(engine): downloads refuse hosts that resolve to private addresses

* fix(core): shorten the env proxy doc comment

* test(producer): remote-media tests stub the download fetch seam
2026-10-28 20:08:50 +00:00
Miguel Ángel 3ca1005a81 feat(producer): report which element set the film length (#6689)
* feat(producer): report which element set the film length

* fix(core): keep the duration guard and comment share in step with the length helper
2026-10-28 19:05:59 +00:00
Miguel Ángel cdc86117c7 fix(engine): a render from an app that bundles the engine stamps the engine's version (#6686)
* fix(engine): a render from an app that bundles the engine stamps the engine's version

* test(engine): the bundled-layout fixture names a generic app
2026-10-28 17:51:43 +00:00
Vance IngallsandClaude Opus 5.5 c569760a7a fix(core): grade groups resolve per composition; freeze frames keep their lane (#6685)
Co-authored-by: Claude Opus 5.5 <noreply@anthropic.com>
2026-10-28 10:51:17 -07:00
Vance IngallsandClaude Opus 5.5 09b1290474 feat(core): grade groups grade a whole lane from one hf-color-group (#6678)
An inert <hf-color-group> holds a lane's data-color-grading; <video>, <img>
and <canvas> join with data-color-group. A member's own grading overrides
its group's. The runtime discovers members, regrades them when the group's
grading or a member's data-color-group changes, and ungrades them when the
group element or its grading goes, drawing only members on screen.

Render keeps group-graded video at full size like directly graded video,
and lint accepts (and still validates) grading on hf-color-group.

Co-authored-by: Claude Opus 5.5 <noreply@anthropic.com>
2026-10-28 10:10:42 -07:00
Miguel Ángel 4db1214e7d test(engine): the multi-chunk encode test gets the 30 s the other ffmpeg tests have (#6663)
* test(engine): the multi-chunk encode test gets the 30 s the other ffmpeg tests have

* test(engine): the mixed-path concat test gets the same 30 s
2026-10-28 13:13:18 +00:00
Miguel Ángel 437784038b fix(engine): late-starting MP4 and WebM videos render every frame the preview shows (#6664)
* fix(engine): late-starting MP4 and WebM videos render every frame the preview shows

The browser counts an MP4 or WebM from timestamp 0, but FFmpeg seeks from the file's
earliest stream start. A file whose first frame comes after 0 (a fragment cut from a
longer stream, an edit-list offset, a WebM with a start offset) was extracted early and
short, so renders tripped the video coverage gate. Every video seek now maps media time
to FFmpeg's timeline, and the video begins where the browser shows it.

* fix(engine): audio from late-starting MP4 and WebM plays when the preview plays it

The mixer seeked and trimmed audio by FFmpeg's clock, which starts at the file's earliest
stream. In an MP4 or WebM whose streams all start after 0, the browser plays that audio
later, so the render heard it early by the same amount. The mixer now maps media time onto
FFmpeg's clock with the same offset frame extraction uses.

* fix(engine): a late-starting file's picture shows on the clock its audio plays on

* test(producer): vfr-screen-recording baseline shows each frame at its timestamp
2026-10-28 13:09:53 +00:00
Miguel Ángel b6eaed7cae fix(cli): a check page forces a WebGL drawing buffer but keeps no list of 2d canvases (#6650) 2026-10-28 10:41:22 +00:00