168 Commits
Author SHA1 Message Date
FredApps b0acbbe121 CLI: regression tests for render --progress (#1778) and template media values (#1787)
- render --progress with a piped stderr writes well-formed
  `progress <done> <total> <elapsed> <left|->` lines, one per change, and
  the same render without the flag writes none.
- A template's Media Replacement control takes {"path"|"file"|"media": …},
  is found by name ignoring case, and a path that cannot be imported fails
  with an error naming the control and the path.
2026-10-18 16:46:06 +02:00
Brandon Thomas 043eb5a157 Merge pull request #1787 2026-10-18 09:35:35 -04:00
Brandon Thomas 692feb7925 Merge pull request #1778 2026-10-18 09:35:35 -04:00
Brandon Thomas 869ce1db39 Merge pull request #1752 2026-10-18 09:35:35 -04:00
Brandon Thomas 436f826c3d Merge pull request #1712 2026-10-18 09:35:35 -04:00
Brandon Thomas fc3d228616 Merge pull request #1688 2026-10-18 09:35:34 -04:00
Brandon Thomas cb76329b72 Merge pull request #1648 2026-10-18 09:35:34 -04:00
Brandon Thomas 0728169fc9 Merge pull request #1384 2026-10-18 09:35:33 -04:00
MarekSpodBiedry c74e67ca32 Let render --template --values fill a media replacement control with a file path (#1780) 2026-10-18 13:53:15 +02:00
ArchersIntelandClaude Sonnet 5.5 c6b700fe83 feat(cli): render --progress reports frames on stderr when it is not a terminal
A terminal already gets a live `[1/1] frame 16/180 ... ~14.2s left` line while
`effectcraft-cli render` runs. A program that starts the CLI (FilmCraft runs it to
render a composition for a clip) reads stderr through a pipe, so it saw nothing
until the render ended.

`--progress` prints one line per update instead, at most four a second:

    progress <frames done> <frames total> <seconds elapsed> <seconds left, or - when unknown>

It has no effect on a terminal, which keeps its live line. Without the flag
nothing changes.

Documented in the usage text, the module header and docs/agents.md.

Tests: cargo fmt --check and cargo clippy --all-targets -D warnings pass; the
effectcraft-cli tests pass except render_out_is_relative_to_the_working_directory,
which already fails on Windows (it compares a canonicalize()d `\?\` path with the
path the CLI prints) and is unrelated to this change.

Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
2026-10-18 02:17:33 -05:00
Madhav AgarwalandDeepSeek V4.1 Flash Free b113278a1c Fix #1275: open the commands' file dialogs without blocking the frame on Linux
rfd's Linux backend goes through the XDG desktop portal, and a blocking
`rfd::FileDialog` leaves the main thread waiting on the portal's answer
without pumping winit's events: while the Open dialog is up the window stops
answering the compositor, which offers to force-quit the app ("EffectCraft is
not responding"), until a file is picked.

The non-blocking host hook for the commands' dialogs (`rfd::AsyncFileDialog`
on a worker thread, run when the dialog closes) was macOS-only since #511.
Install it on Linux too. Windows keeps the blocking pickers (its dialog pumps
its own messages), and the panel buttons' pickers (Settings, effect file
pickers) are unchanged.

Checked headlessly against a mock XDG portal: with the hook the main thread
stays in the event loop while a worker blocks in the portal wait, `ui.inspect`
still answers 7.5 s after the dialog opened, and an answered dialog runs
File ▸ Import; without it the main thread itself blocks in the portal wait and
the app answers nothing until the dialog closes.

Co-Authored-By: DeepSeek V4.1 Flash Free <noreply@deepseek.com>
2026-10-18 00:48:08 +05:30
MarekSpodBiedry 351f2591fd Fall back to the page's thread when new Worker throws in a sandboxed iframe (#1586) 2026-10-17 07:47:33 +02:00
Matej Kozlovský f8bd967861 gpu: honour wgpu env overrides in headless/CLI (with_env, WGPU_ADAPTER_NAME, WGPU_POWER_PREF)
GpuContext::request() now applies InstanceDescriptor::with_env() (WGPU_BACKEND,
WGPU_DX12_COMPILER, WGPU_VALIDATION, WGPU_DEBUG, ...), the same variables the
desktop app honours via egui-wgpu, and requests PowerPreference::from_env(),
defaulting to HighPerformance (an unknown WGPU_POWER_PREF logs a warning).

WGPU_ADAPTER_NAME (CLI/headless only; the desktop ignores it) picks the first
adapter whose name contains the trimmed value, case-insensitively. Empty or
blank counts as unset. Only the name is matched (backend via WGPU_BACKEND). A non-matching name is an
error that says so and lists each distinct adapter once as 'name (backend)', instead of wgpu::util::initialize_adapter_from_env's panic;
no adapters at all gets its own message.
2026-10-16 20:12:35 +02:00
krinry f13429010f #1582, #1585: guard web serviceWorker against SecurityError in opaque contexts
In sandboxed iframes without allow-same-origin (or other opaque origin contexts), accessing `navigator.serviceWorker` throws a SecurityError synchronously.

- Guard `info().serviceWorker` evaluation with try/catch to return `false` on SecurityError (#1585)
- Guard PWA serviceWorker registration with try/catch to let the web app load rather than hanging (#1582)
- Add contributor credit entry for @krinry in `contributors/people.toml`
2026-10-16 18:09:38 +05:30
BFlat 901d54c55f Merge pull request #1594 from rahal/fix/script-host-files
fix(web): scripts can open files in browser storage; stored footage isn't reported missing (#1593)
2026-10-16 19:04:06 +07:00
BFlat 16c6180d91 Merge pull request #1391 from sanyamsingh001/fix/cli-render-empty-r49
Honor --empty when rendering from the CLI
2026-10-16 19:03:09 +07:00
BFlat 67f3a0513c Merge pull request #1313 from sanyamsingh001/fix/cli-input-preservation-r48
Preserve CLI template inputs when output is a hard link
2026-10-16 19:02:58 +07:00
BFlat c3cb658be1 Merge pull request #1432 from marcoarnulfo/fix/render-queue-failed-exit
CLI: a failed render under run/exec exits 1, like render --queue
2026-10-16 18:59:52 +07:00
bflatasticandClaude Opus 5.5 3725c321a6 CLI: drop a debug print from the --empty render test
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-10-16 18:39:06 +07:00
bflatasticandClaude Opus 5.5 ced1857637 Templates: the hard-link check covers every Unix, not only Linux
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-10-16 18:39:03 +07:00
BFlat a2c2a1078a Merge pull request #1357 from iannitram/upstream-pr/cli-args-os
CLI: an argument that is not Unicode is a usage error, not a panic
2026-10-16 18:09:16 +07:00
rahal 228ceb308e fix(web): scripts can open files in browser storage; stored footage isn't reported missing
In the browser editor a .jsx script couldn't open any file, even one the
page holds next to the project: File.open("r") returned false with "File
not found" and File.exists was false. The footage check after File > Open
also marked imported media as missing.

Both asked whether a file exists on the local disk (std::fs), which has no
files on wasm32:
- scripts read files through Session.services but checked existence with
  std::fs (File.open's access check, File.exists, Folder.exists); they now
  ask services.exists / services.is_dir, after the folder check;
- WebServices kept the default exists (std::fs); it now looks in the file
  table.

Desktop and CLI are unchanged (FsServices keeps the std::fs defaults).
Tests: script tests_services (a host with in-memory files), web smoke
step hostFiles (a script reads a stored file, footage check finds stored
media).
2026-10-15 17:08:01 +01:00
Marco Arnulfo e26dd21af7 CLI: a failed render under run/exec exits 1, like render --queue (part of #1426) 2026-10-14 13:47:08 +02:00
sanyamsingh001andCodex fc3643ad17 Honor --empty when rendering from the CLI
Keep ordinary --empty renders from loading the demo. Preserve explicit
project, template, and demo selection, and cover them with real GIF renders.
Sort the relative-footage test's expected paths consistently with its output.

Co-authored-by: Codex <codex@openai.com>
2026-10-14 12:43:53 +10:00
tylerjenningsw f61f8c9958 Web: remembering and forgetting Media Browser folders waits for the commit too (#1242) 2026-10-13 21:38:54 -04:00
tylerjenningsw fa6c9ffccd Web: IndexedDB puts and deletes resolve when their transaction commits (#1242) 2026-10-13 21:38:54 -04:00
iannitramandClaude Opus 5.5 7c1e839603 CLI: an argument that is not Unicode is a usage error, not a panic
effectcraft-cli read its command line with std::env::args, which panics
on an argument that is not valid Unicode (a Latin-1 file name on Linux,
for example). `effectcraft-cli $'\xff'` or
`effectcraft-cli render-frame --out $'caf\xe9.png'` printed a panic from
std's env.rs and exited 101.

It now reads std::env::args_os and refuses such an argument as a usage
error (exit 2) that names it, before anything runs, like an unknown
option. A lossy copy is not used: every argument is a string here, and
`caf\u{fffd}.png` would read or write another file than the one named.
FilmCraft moved its CLI to args_os too (storytold/filmcraft#850).

Tests: a unit test for the conversion and a process test that runs the
CLI with a non-Unicode `--out` path (both unix-only). Before the fix the
process test fails (exit 101, not 2).

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-10-13 15:45:23 -06:00
sanyamsingh001andCodex e52ce29579 Preserve CLI template inputs when output is a hard link
Compare device and inode on Linux alongside existing path checks. Cover
template and values aliases with input-preservation and diagnostic checks.
Sort the existing footage test's expected paths for temporary-directory portability.

Co-authored-by: Codex <codex@openai.com>
2026-10-14 02:14:42 +10:00
vangel76andClaude Sonnet 5.5 89ae151c03 #1221: two path-format test failures on Windows
Problem: on Windows two tests failed on main although the app is fine; they assumed
macOS/Linux path formats.

Fix: the CLI test strips the verbatim path prefix that canonicalize adds on Windows (a
child's current_dir() never reports it); the host sink test uses a drive-letter path on
Windows (a path rooted without a drive is joined to the home drive by the engine, the test
expected the current drive). Test code only.

Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
2026-10-13 14:25:42 +02:00
Brandon ThomasandClaude Opus 5.5 3ac283eee4 Review fixes for the landed batch
- Cryptomatte (#1183): planes shorter than the image read as empty instead of panicking.
- layer.addMarker (#1180): a comp marker no longer replaces one at the same time.
- Desktop (#1005): ignore macOS's -psn_ argument instead of refusing to launch.
- Doc comments put back on their own items (#1153, #1037).

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-10-13 04:47:52 -04:00
Brandon Thomas f096470dec Merge pull request #1153 from fabian-co/fix/intel-metal-indirect-validation 2026-10-13 04:33:47 -04:00
Brandon Thomas 4574fb62bc Merge pull request #792 from vangel76/gap-object-matte
# Conflicts:
#	crates/ui-egui/src/i18n/ui.rs
#	docs/gaps.md
#	docs/target-app-parity.md
2026-10-13 04:30:49 -04:00
fabian-coandClaude Opus 5.5 41f7736959 macOS: open the window on Intel Metal by skipping indirect-call validation
wgpu validates indirect draw and dispatch arguments with a compute shader it
compiles when the device is created. Metal on an Intel Iris Pro (MacBookPro11,3,
macOS 12.7.6) fails to compile it ("Compiler encountered an internal error" in
MTLCompilerService), the device is lost, and the window never opens.

EffectCraft draws and dispatches nothing indirectly, so leave the check out of the
instance flags. WGPU_VALIDATION_INDIRECT_CALL=1 turns it back on. VectorCraft
does the same (storytold/vectorcraft#651).

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-10-12 17:45:45 -05:00
vangel76andClaude Sonnet 5.5 925760c9c8 Web disk cache: handle the Matte kind (mattes/ folder)
Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
2026-10-12 19:08:21 +02:00
RealtaNuaandClaude Opus 5.5 649ba2e8cf Desktop: an unknown option or a bad --control port stops the launch (#997)
The desktop app imported any argument it didn't know as a file (writing it to Recent Footage)
and dropped a missing or non-numeric --control value, starting without a control server.
parse_args now returns an error for an unknown option, a --control value that isn't a port from
1 to 65535, or a bad EFFECTCRAFT_CONTROL_PORT (checked only when --control isn't given); main
prints it and exits with status 1 before anything starts. --control=<port> works, and -- ends
the options so a file named -x can still be opened.

Tests: parse_args unit tests, and tests/args.rs runs the binary with its own settings folder
and checks the exit, the message and that nothing was written.

Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com>
2026-10-12 17:40:15 +07:00
Brandon Thomas 6ace9f7b0e Merge pull request #923 from itrycodinganditsbad/rotating-log
Desktop: write log records to standard error and a rotating log file
2026-10-12 04:20:56 -04:00
Fabio LussiandClaude Opus 5.5 16d9d7d30b Desktop: write log records to standard error and a rotating log file
A launch from the Dock, the Start menu or a launcher has no terminal, and
without RUST_LOG nothing reached standard error anyway, so start-up and
GPU warnings were lost unless Help > Enable Logging was already on.

The logger now writes EffectCraft's info records and everyone's warnings
to standard error and to Logs/effectcraft.log in the settings folder.
Each launch keeps the previous two runs' logs; the file is capped at
16 MiB. RUST_LOG still overrides the filter. Help > Reveal Logging File
shows this run's log unless Enable Logging is on.

Ported from storytold/pdfcraft#239.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-10-11 22:37:27 +02:00
pravdomilandClaude Opus 5.5 04e087ae58 Window: remember the window's size and position between launches
The window opened at a fixed 1680 × 1020 wherever the system put it. Its size, position
and maximized state are now saved to window.json in the config directory (when they change,
and on exit) and restored on the next launch, moved onto a monitor that is still connected.
The first launch fits the window to its screen. Agent-driven runs (--control) restore the
saved window but don't overwrite it.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-10-11 15:54:29 +02:00
skylar taylor-barrick 83ae6218ef UI.9: retain shared docking across upstream workspace changes 2026-10-10 19:25:49 -06:00
ClaudeandDennis M. Francis cb37c2511c App: a lost graphics device tells the user why the window closes and where the recovery copy is (#591)
Ported from #673: a native error dialog names the auto-saved recovery copy before the window
closes; agent runs through the control channel skip it. The UI calls Hooks::device_lost once.

Co-Authored-By: Dennis M. Francis <44986763+didpublishing@users.noreply.github.com>
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01QiAJeFttZp83Fh7YuzAR5f
2026-10-10 23:36:52 +00:00
skylar taylor-barrick 3dba472943 UI.9: share docking transactions and preserve viewer lifecycle
Preserve legacy selection repair, modifier routing, viewer lifecycle and workspace persistence through the shared docking integration. Qualify the complete workspace gate by refreshing the 18 stale Audio Spectrum hashes for the existing linear renderer, with an independent synthetic-tone regression.
2026-10-10 17:14:12 -06:00
Claude 8fb4281632 MCP: --automation-read-root / --automation-write-root confine the agent's file access (#500)
`effectcraft-cli mcp` had no way to keep an agent's file access to a folder;
the flags were unknown options. Both now take a folder (repeatable, as in
PhotoCraft): with either given, files are read only under a read or write root
and written only under a write root (none: no writes). Defaults are unchanged.

automation::confine::Confinement checks every engine command the backend runs
(execute_command, command_run, open/save_project, each engine.batch step), in
both headless and bridge mode, before it runs: the file parameters of the
commands that read or write files must be absolute paths inside the roots
(symbolic links resolved through the longest existing ancestor, `..` refused),
as must any other absolute path in a command's parameters. Commands that write
where they aren't told are checked against the target they would write: Save /
Increment and Save the open project's file, renderQueue.render every queued
output (renderQueue.list). Scripts, Execute File, Reveal in Finder, Open Recent
by index, `$N` file-path references in a batch, render_frame/screenshot paths
outside a write root and the bridge's UI-driving tools are refused while
confined. docs/mcp.md describes it.

Test: a confined headless server opens and saves inside its roots and is refused
outside them, for a relative path, `..`, a batch step, a `$N` path, Save to a
read-only root's project, the Render Queue's default output there, a symbolic
link out of the write root, and scripts; the unconfined server still writes
anywhere.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01QiAJeFttZp83Fh7YuzAR5f
2026-10-10 22:54:57 +00:00
Claude aaf23aa5f8 macOS: File menu dialogs open as sheets, so a drag over the window can't abort the app (#511)
The file dialogs were blocking rfd::FileDialog calls made inside eframe's frame,
that is inside winit's event handler. On macOS the dialog runs a nested modal
event loop there; a file dragged over the window while it was open reached
winit's handler again, which refuses re-entry with a panic across the
Objective-C boundary, aborting the app (Import with Cmd+I, then a drag).

Hooks gains file_dialog_async: a host that sets it shows a command's file dialog
(Import, Open, Save As, Save Frame As, presets, guides, templates, Collect Files,
Relink...) without blocking, and the command runs with the answer on a later
frame (menus::dialog_answered, drained at the start of each frame); a cancelled
dialog runs nothing. The macOS app implements it with rfd::AsyncFileDialog, a
sheet on the window answered when it closes, outside the frame. Other platforms
keep the blocking dialogs (winit queues their re-entrant events), as do the few
panel buttons that pick a file in place (Settings paths, shortcut import/export,
effect file pickers).

Test: with a non-blocking hook, Save As and Save Frame As return at once without
the blocking dialog, the save happens when the answer arrives from another
thread, and a cancelled dialog writes nothing. The macOS sheet itself needs a
manual check (Cmd+I, drag a file over the window, pick or cancel).

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01QiAJeFttZp83Fh7YuzAR5f
2026-10-10 22:54:56 +00:00
Claude ff56c5ad24 Audio: the short preview buffer is Linux-only and within the device's range (#614 follow-up)
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01QiAJeFttZp83Fh7YuzAR5f
2026-10-10 18:50:32 +00:00
Claude a3cc4d04b0 Merge pull request #614 from vbasky/fix/554-linux-audio-preview 2026-10-10 18:49:52 +00:00
Vikram Bhaskaran 139ff9a4e3 Start Linux audio preview after the first mixed samples, on a short device buffer.
Pulse and PipeWire were opening a large default period and playing silence until the feeder caught up, so the picture ran while the sound started late. The stream now waits for queued samples and requests about 10 ms of buffering.
2026-10-11 03:50:22 +11:00
Claude 4de3354806 Merge pull request #589 from JeremyYao/fix/amd-vulkan-launch-guard
The two test-only conflicts keep main's versions, which already carry the
same fixes.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01QiAJeFttZp83Fh7YuzAR5f
2026-10-10 16:29:06 +00:00
Jeremy YaoandClaude Fable 5.1 2a404f6226 MCP: the auto-save recovery tests look for the JSON-quoted path
automation autosave_is_durable_before_reply_and_queries_do_not_rotate
and the CLI's mcp_autosave_survives_kill_and_restart_without_touching_
desktop_settings asserted that the initialize instructions contain the
previous session's auto-save path as raw text. The instructions embed
the auto-save info as JSON, so on Windows the path's backslashes are
escaped and the raw match can never succeed (both failed on every
Windows run; the server's reply is right). They now look for the path
as serde_json prints it, which also matches on Linux and macOS.

Co-Authored-By: Claude Fable 5.1 <noreply@anthropic.com>
2026-10-10 09:37:00 -04:00
Jeremy YaoandClaude Fable 5.1 d86c4aff52 Startup: a launch that stops as its window is shown switches the next to OpenGL
On an ASUS G513QY (Radeon RX 6800M, Adrenalin 26.9.2, Windows 11) every
launch died with STATUS_ACCESS_VIOLATION inside amdvlk64.dll, on a
driver worker thread, a moment after the first frame: eframe shows the
window it created hidden, the resulting resize re-creates the swapchain,
and the driver crashes there (same offset on two driver versions, with
the OBS/Steam/Epic Vulkan layers disabled, and with FIFO, immediate and
latency-1 presentation). DirectX 12 and OpenGL open the window fine.

A crash in a driver can't be caught, and the launch guard (#243) removed
its marker at the first frame, so this looked like a successful launch
every time and Window Graphics never switched. The marker now stays
until the window has kept drawing for SETTLE (3 s) or the app quits
normally before that; frame_drawn returns the time left and the app
asks for a repaint then, so an idle window settles too. The notice,
the Settings note and docs/preferences.md describe the new rule.

Verified on that machine with a scratch settings folder: launch 1
(Vulkan) crashed and left the marker, launch 2 switched to OpenGL with
the notice and closed with exit code 0, launch 3 stayed on OpenGL
without the notice.

Tests: effectcraft launch_guard
a_launch_that_stops_after_its_first_frame_switches_the_next_to_opengl
(a first frame then drop: the next launch gets GL and the notice; a
normal quit in that time leaves no marker), and the existing test now
asserts that the first frames don't settle a launch (marker present at
SETTLE/2, gone at SETTLE).

Co-Authored-By: Claude Fable 5.1 <noreply@anthropic.com>
2026-10-10 09:36:59 -04:00
Claude 00e9e37c0a UI: the drop hint and drop errors go through the interface catalog; the Wayland notice points to the README (#447 follow-up)
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01QiAJeFttZp83Fh7YuzAR5f
2026-10-10 12:55:10 +00:00