effect::tests::failed_and_missing_stages_are_deferred_with_their_reason
installed a plug-in that runs to the default instruction budget (about 51
million instructions for its input) inside a first view, whose budget is
2,000 ms of real time. Under heavy CPU load the run took longer than that,
the view's budget cut it short, and the stage was deferred for time
instead of as failed, so last_error was empty and the assertion at
effect.rs:722 failed. With the test pinned to one core beside 15 busy
loops it failed 3 runs of 3 that way.
The test now gives the plug-in a budget of 100,000 instructions, so the
run ends in an instruction-budget failure long before the view's budget
runs out, and it checks that the error is the instruction budget. The
same test passes 5 runs of 5 beside 15 busy loops and 5 of 5 beside 100.
The plug-in runtime keeps main's JavaScript plug-ins beside the web worker's module bytes and checked loads: a JavaScript plug-in's bundle is kept for the worker like a module, and load_checked loads it from its bundle.
A stored plug-in that didn't install, for example because its load
panicked or its module is broken, was only written to the log. The
person could not see it or load it again without restarting.
- plugin.list gains failed: [{file, error, from}], the plug-in files
that didn't load in this process: those of the Plug-ins folder, and
those the folder report of the Additional Plug-ins Folder (or the
folder plugin.reload loaded last) lists as failed. Disabled plug-ins,
files turned off since they failed, and modules skipped because
another install or removal of their id came first are left out. A
file that both loads list is listed once, as a stored file. A
plugin.reload replaces only the folder's rows. Installing or removing
a plug-in whose module is in a stored file that failed, or a later
load that installs it, takes the file off the list.
- plugin.retry {file?} loads one of those files again, or all of them,
with the same checks as the load it failed in, and reports for each
whether this retry installed it. A folder file's row in the folder
report moves to loaded or keeps its new error. Under automation read
roots, a file outside them is not read again, its row stays listed,
and the reply names it and its folder by their names. Safe Mode
returns an error.
- plugin.setEnabled {file} also takes the name failed gives a file
outside the read roots.
- Object › Plug-ins › Plug-ins That Didn't Load… lists the files with
why; Retry All loads them again under the read roots the list opened
under, and the status bar says how many loaded. The item is disabled
while nothing failed.
- A command.batch that runs a filter and then retries a module with
its id turns Apply Last Filter off, as a reinstall does.
Docs: docs/plugins.md (Plug-ins that didn't load), docs/mcp.md.
- A panic while a held run's output is applied ends the run, so the
documents go back to their state before it, and ending a held run
drops the output handed in for it.
- The worker loads a plug-in with the limits the page sends with the
run, so its memory limit applies.
- A worker that is ready only after the run's deadline is not sent the
run, with or without a dialog open.
- A run that holds the documents and fails while a dialog is open ends
at once and frees them.
- A plug-in command's dialog that automation confirms runs the command
on the page and returns its result.
- A plug-in file opened or dropped on the web whose worker check fails
is reported in the Can't open dialog, not only in the status bar.
- The web README lists connect-src among the CSP directives the app
needs.
The plug-in loader, registry and dialog unit tests decided their results with
yield-count spins (up to 100,000,000 tries) and a 10 s recv_timeout. On a
loaded machine a spin could run out before a worker sent, and a test failed
without a fault.
- Loader tests block on the workers' outcome channel (Loads::record_next) and
on the jobs' start channel. The stuck-thread tests keep the outcome channel
of the dropped load and receive the stuck job's outcome, which its worker
sends after it stops counting the thread as stuck. The window test checks
that taking outcomes leaves the start limit where it was.
- The registry revision test holds the set and waits for a hook that install
runs right before it asks for the write lock. The folder-order test drives
the load on the test thread and receives the other two files' outcomes
while the first file waits.
- The dialog test counts the conditions Manifest::visible checks and fails
once it checks more than one per named parameter, so a check that does not
end fails the test.
Every assertion is kept.
The gate's test shard 4 builds vectorcraft-plugins without
vectorcraft-engine, which was the only crate that turned the
test-steady feature on, so `cargo xtask ci shard` stopped at its
feature check on every shard. vectorcraft-plugins now turns the
feature on in its own dev-dependencies, as vectorcraft-pdf and
vectorcraft-affinity do for their test features.
Three tests in crates/plugins/tests/abi.rs passed or failed on how long a
run took (under 5 s or 3 s), so a slow or loaded runner could fail them and
a fast one could hide a run stopped by the wrong limit.
- hostile_modules_fail_within_their_budget (was _fail_quickly) checks each
module's error. The endless ones must end with the instruction budget, so
a run stopped by the 60 s time budget fails the test.
- wall_clock_budget_stops_runaway_plugins gives an endless loop two slices
of instructions: with a time budget of 0 it ends with the time budget at
the end of the first slice, and with the default one it ends with the
instruction budget.
- cancelling_stops_a_run_between_two_slices_of_its_budget gives the loop
two slices: cancelled, it comes back Cancelled; not cancelled, the same
plug-in ends with the instruction budget.
Each test fails when its check in Plugin::call_with is removed.
wasmi 2.0.0 miscompiles a multi-value br_table whose targets take the
same values when another operand sits under those values: the targets
read their values from slots the branch never wrote
(https://github.com/wasmi-labs/wasmi/pull/2106, fixed in 2.0.2). A
plug-in that branched that way got wrong results. 2.0.1 to 2.0.3 also
fix other miscompilations, a use-after-free on resuming a call on
another store, and memory.grow past a declared maximum bypassing the
resource limiter
(https://github.com/wasmi-labs/wasmi/blob/main/CHANGELOG.md).
Only Cargo.lock changes: the workspace requirement "2.0.0" allows
2.0.3, and wasmi 2.0.3 still uses wasmparser 0.228.
The new abi test runs such a branch table for each of its targets; it
fails on 2.0.0 with the plug-in's unreachable trap.
The Preview Bounds memo checks the fonts, the hyphenation exceptions and
the plug-in revisions on every lookup. Other engine tests change the
hyphenation exceptions and install plug-ins on other threads, so a
change between two hovers refreshed one memo slot and
a_hover_checks_the_memo_as_often_however_many_objects_are_selected
counted 5 checks instead of 4.
- set_hyphenation_exceptions takes the font gate (test_fonts::font_change),
as composite font changes do, so steady_fonts holds it back too.
- vectorcraft_plugins::steady (feature test-steady) gates every revision
bump in the plug-in registry and the deferred stages the same way.
- Both counting tests in previewbounds.rs hold both guards, and the
hyphenation round-trip test holds steady_fonts through its sequence.
The example filter parsed its input with serde_json's default float
parser and handed every object back with its `path`. A coordinate could
come back changed in its last digit, which the host reads as a new path:
a live shape became a plain path after a color-only run, and a compound
path with a hidden, locked or guide member was refused.
The filter now leaves `path` out of each object it returns, so each
object keeps its geometry, as docs/plugins.md advises for a filter that
does not change it. The fixture desaturate.wasm is rebuilt from the
source with build.sh.
Docs: docs/plugins.md.
A paragraph style's hyphenation, justification, tab stops and list, and a
character style's stroke dash, now refuse a key they don't read, naming the
field, as the style's own keys already did. A misspelled nested key no longer
leaves that setting unchanged without an error.
Loading a JavaScript plug-in read its JSON into a map that sorts its keys and
wrote it out again before parsing the manifest, so `params` and each command's
`params` reached dialogs in alphabetical order. The manifest is now parsed from
the plug-in's own JSON (`Manifest::parse_text`), with its size still counted
without `script` and `source`, and a `.vcplugin` read from a folder has
`source` added to its own text instead of being written out again.
The Safe Mode choice after a stopped launch moves to main's dialog host and keeps listing every
plug-in that was loading: one name in the sentence, or the list with "Disable Listed Plug-ins and
Continue". Automation requests wait in the queue while plug-ins load, and one past its deadline is
answered as expired. File > Open and opening a file still wait for the plug-ins still loading.
- The grant test accepts only a missing grants file as an empty list; any other read error fails it.
- The same-stamp replacement test asserts that the callback rewrote the file before it checks that
nothing installed.
- The loader's ordering test binds the job senders after `loads`, so a failing assertion releases
the held jobs before `loads` waits on them under the manual clock.