Skip to content

fix(skills): stage SVGs that capture wrote into capture/assets/svgs/ - #3336

Merged
miguel-heygen merged 1 commit into
mainfrom
fix/stage-captured-svgs
Aug 20, 2026
Merged

fix(skills): stage SVGs that capture wrote into capture/assets/svgs/#3336
miguel-heygen merged 1 commit into
mainfrom
fix/stage-captured-svgs

Conversation

@miguel-heygen

Copy link
Copy Markdown
Collaborator

What

stageAssets now searches capture/assets/svgs/, so an SVG that hyperframes capture extracted can be staged into assets/ like any other captured asset.

Why

capture writes inline SVGs to capture/assets/svgs/ (packages/cli/src/capture/assetDownloader.ts), and the capture manifest advertises them to the agent as assets/svgs/<name>.svg. So a frame names one in asset_candidates exactly the way it names a screenshot.

The staging search list covered capture/{assets,assets/videos,screenshots} only. Every captured SVG resolved to nothing: logged as a non-fatal anomaly, and the frame 404'd the brand mark it had been told to use. Found running /product-launch-video end to end.

How

One entry added to captureDirs.

lib/assets.mjs is byte-identical across product-launch-video, faceless-explainer and pr-to-video, so the fix lands in all three.

Not covered: the triplication itself. Folding lib/assets.mjs into hyperframes-core/scripts/lib/, where frame-packets-core.mjs already lives, is a separate change and not in this PR.

Test plan

New skills/product-launch-video/scripts/stage-assets.test.mjs, covering both the captured-SVG case and an asset that genuinely exists nowhere (so the anomaly path is still exercised).

Verified it fails on the parent commit and passes here.

Manual: a fixture project with a captured SVG, a screenshot and a root capture asset, all three named by one frame.

  • Before: ✓ staged 2/3 asset(s) into assets/ plus asset "brand-mark.svg" named by a frame but not found under capture/

  • After: ✓ staged 3/3 asset(s) into assets/

  • Unit tests added/updated

  • Manual testing performed

  • Documentation updated (if applicable)

miga-heygen
miga-heygen previously approved these changes Aug 19, 2026

@miga-heygen miga-heygen left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Approve — one-line fix applied identically across all three triplicated copies. The new capture/assets/svgs/ entry sits naturally alongside the existing capture/assets/videos/ subdir entry, the comment is updated to match, and the test covers both the positive case (SVG + screenshot staged together) and the negative (absent asset still surfaces an anomaly). No issues.

— Miga

@miga-heygen
miga-heygen dismissed their stale review August 19, 2026 20:28

Stamp removed — was posted prematurely

`hyperframes capture` extracts inline SVGs into capture/assets/svgs/, and the
capture manifest advertises them to the agent as `assets/svgs/<name>.svg`, so a
frame names one in `asset_candidates` exactly the way it names a screenshot.
stageAssets searched only capture/{assets,assets/videos,screenshots}, so every
captured SVG resolved to nothing: logged as a non-fatal anomaly, and the frame
404'd the brand mark it had been told to use.

Add the directory to the search list, and cover it with a test that fails
without the fix.

lib/assets.mjs is byte-identical across product-launch-video,
faceless-explainer and pr-to-video, so the fix lands in all three. Folding it
into hyperframes-core/scripts/lib/, where frame-packets-core.mjs already lives,
is a separate change.

Co-Authored-By: anikam13 <22992075+anikam13@users.noreply.github.com>
@miguel-heygen
miguel-heygen force-pushed the fix/stage-captured-svgs branch from 2af9681 to 036349f Compare August 20, 2026 20:13
@miguel-heygen
miguel-heygen merged commit c66c9a4 into main Aug 20, 2026
45 checks passed
@miguel-heygen
miguel-heygen deleted the fix/stage-captured-svgs branch August 20, 2026 20:22
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants