github solidjs/solid @solidjs/diagnostics@2.0.0-rc.9

Patch Changes

  • eaa7e33: The attribution engine's folds, queries and formatters are named exports of @solidjs/signals/attribution (and solid-js/attribution), not methods of attribution.

    • costs(), feedback(), why(target), subscriptions(target), formatRerun(event), formatOrigin(origin) — import them by name. attribution keeps enable, disable, subscribe, markFlight and the record ring buffers (history, holds, interactions, navigations, waterfalls). attribution.format is formatRerun.
    • Why: the fold tables (costs, feedback) are the dev/agent view of the records and the part of the engine that grows; a production adapter consumes records and never calls them. Each fold's module registers its accounting with the engine's fold seam when it is imported, so under the package's sideEffects: false a consumer that only subscribes to records ships neither the tables nor the work of filling them — importing costs or feedback is what turns them on. Measured: −1,150 B brotli for a records consumer (the size scenario's cap ratcheted to 27.25 KB); tree-shake tests pin it from source and from the built observe artifact.
    • New types AttributionCostTables; ScopeCost/WriteCost and the feedback types move with their modules and are still exported from the entry. The prod tier's inert twin exports the same named surface, typed against the real one.
    • @solidjs/diagnostics: AttributionCosts/AttributionFeedback are aliases of AttributionCostTables/AttributionFeedbackTables; the capture and the browser bridge import the folds by name. Artifact shape unchanged.
  • ebedb44: Attribution re-run records are serializable as emitted, and the observe tier's idle cost is a cap.

    • RerunEvent no longer carries the live node. It names its scope by nodeId — the engine's per-node id, stable across the scope's runs in the process and distinct between scopes (so runs of unnamed effects still fold to one scope after the record has left the process). In-process consumers that want the node ask OBSERVE.subjectOf(event), which now answers for re-run records as it did for diagnostic events, for as long as the caller holds the record object. attribution.why(target) and subscriptions(target) are unchanged.
    • @solidjs/diagnostics artifact format v7: re-runs are stored verbatim (RerunRecord is now an alias of RerunEvent), and the artifact gains timeOrigin — the capturing process's performance.timeOrigin — so every relative at in it (re-runs, holds, records, diagnostic data) is convertible to absolute time after the fact, and a server capture lines up with the browser session it served. The JSONL meta line carries it too; the browser bridge payload includes it.
    • New tripwire in the signals suite: the built observe artifact runs a graph-heavy workload within 1.25× of the built prod artifact with no hooks installed (measured 1.03–1.09). The idle wiring cost was informational before; it is capped now.
  • 3ae9e92: OBSERVE.records — one records channel on both platforms (observe/dev tiers); frame records from both ends; the client "call" record; observeServerFunctionCalls removed

    • @solidjs/signals: OBSERVE.recordssubscribe(type, listener), observed(type), emit(type, event, live) — the channel every runtime record rides, created once per process and registered on globalThis under Symbol.for("@solidjs/signals/observe/records") so a second copy of the core (a bundled server build instrumented through --import) and wire layers bundled without a framework import reach the same listener sets. Listeners are snapshotted per emit; a throwing listener is reported and the rest run. Types: Records, RecordTypes (extends HostRecordTypes; both declared empty, for the runtimes to augment — one augmenter per interface), RecordType, RecordEvent, RecordLive, RecordListener. Folds out of prod. New OBSERVE.attribution.currentOrigin() (and the currentOrigin hook on AttributionHooks): the provenance a root write performed now would be stamped with — the interaction whose handler is running, the navigation/effect/action frame open, or inside a recompute the origin of the change that caused it — as the engine's own ChangeOrigin object, undefined when external or with no engine; for a runtime stamping a record of its own. The installed hooks are also registered on globalThis under Symbol.for("@solidjs/signals/observe/attribution"), the same reach-without-an-import the channel has.
    • solid-js: the "boundary" record moves from OBSERVE.server.records to OBSERVE.records (augmenting the core's RecordTypes). OBSERVE.server keeps only the trace slot; ServerRecords is gone.
    • @solidjs/web: the "invocation" and "frame" records move to OBSERVE.records (augmenting HostRecordTypes through solid-js). New "call" record (CallEvent, CallLive, CallListener): one per server-function call made from the browser, at the caller's settle — { id, at, durationMs, method: "GET" | "POST", outcome, status?, origin?, deferred? } with { args, response?, result? | error? } beside it; joins the server's "invocation" by id, and — through origin, the engine's own interaction/navigation object read at dispatch via currentOrigin() — the attribution engine's InteractionEvent / NavigationEvent / HoldEvent by identity, so an observer files the call under the click that made it without a time join. The "frame" record now has a client half: FrameEvent is FrameProducedEvent | FrameAppliedEvent, discriminated by side, same census on both; the client half (applyFrameResponse, one per stream in a response) adds address (the as remap) and outcome: "truncated" for a body that ended before complete, with live.response. Server census fix: regions counts html chunks addressed to a child frame id (the former count read a chunk type that does not exist), and shellMs is set by the stream's own shell only. The emitters and their wrappers fold out of the prod client artifacts behind the observe literal (prod applyFrameResponse and the server-function dispatch are the pre-existing functions, no extra frame or promise hop). The server-functions and frames client entries gain observe and development builds and export conditions (server-functions/dist/client.{observe,dev}.js, frames/dist/client.observe.js); the server-functions client is now built with its flags replaced in every tier (before, _SOLID_DEV_ there was an unreplaced truthy string).
    • Removed: observeServerFunctionCalls and the ServerFunctionCall / ServerFunctionRequestCall / ServerFunctionResponseCall types, from both server-function entries. Subscribe to OBSERVE.records "call" (client) or "invocation" (server) instead.
    • @solidjs/diagnostics (format v6): artifact.server is replaced by artifact.records: { boundary, invocation, frame, call } — always present, captured on both platforms including the browser bridge; types BoundaryRecord, InvocationRecord, FrameRecord (FrameProducedRecord | FrameAppliedRecord), CallRecord (with origin?: ChangeOrigin), ArtifactRecords replace the Server*Record / ArtifactServer names. JSONL: one line per record with type naming its table; the meta line's boundaryCount/invocationCount/frameCount become recordCounts: { boundary, invocation, frame, call }.
  • 0d8347a: Server records reach the diagnostics artifact and the dev checks (server-dev-build-plan P4)

    • @solidjs/diagnostics artifact format v5: artifact.server: { boundaries, invocations } | null folds OBSERVE.server.records when the scenario runs under the server runtime — captureArtifact(() => renderToStream(…)) — one row per <Loading> boundary that waited and per server-function execution; null for client captures and the browser bridge. New exported types ArtifactServer, ServerBoundaryRecord, ServerInvocationRecord (mirrors of the runtime's BoundaryEvent/InvocationEvent; the package still depends on @solidjs/signals alone). JSONL egress adds boundary and invocation lines and the header counts.
    • InvocationEvent.boundary: a direct server-function call made during a <Loading> boundary's render pass carries that boundary's hydration id, the "boundary" record's id — the join between a boundary's wait and the calls under it.
    • Two dev checks derived from the boundary facts in ssrLoadingBoundary: ASYNC_WATERFALL with data.side: "server" (passes - 1 sequential flights; 2 → info, structured only; 3+ → console warn) and a new code SSR_CLIENT_CONTENT_MASKED (warn, ssr) for client-only content that surfaced only after a real server wait — the server's work discarded, the fallback shown for the wait. Dev tier only; the boundary clock now runs in dev without a listener.
    • solid-js's server emitFinding keeps info findings off the console (structured channel only), matching the core.
  • Updated dependencies [8ff4803]

  • Updated dependencies [e9c464b]

  • Updated dependencies [0da94f9]

  • Updated dependencies [8bf04ea]

  • Updated dependencies [eaa7e33]

  • Updated dependencies [ebedb44]

  • Updated dependencies [a8a8949]

  • Updated dependencies [d80cd1f]

  • Updated dependencies [d826cd3]

  • Updated dependencies [cc0396b]

  • Updated dependencies [d2a36f5]

  • Updated dependencies [50323b4]

  • Updated dependencies [53280e7]

  • Updated dependencies [d7cb456]

  • Updated dependencies [a0d6dd2]

  • Updated dependencies [c3ae310]

  • Updated dependencies [6095955]

  • Updated dependencies [e80f241]

  • Updated dependencies [84adf0b]

  • Updated dependencies [5c1f01f]

  • Updated dependencies [a5d8eae]

  • Updated dependencies [14ded24]

  • Updated dependencies [25c5064]

  • Updated dependencies [1ce0f85]

  • Updated dependencies [05c7e21]

  • Updated dependencies [9da7f0a]

  • Updated dependencies [62b0a22]

  • Updated dependencies [27b24aa]

  • Updated dependencies [549f482]

  • Updated dependencies [d80cd1f]

  • Updated dependencies [76230f9]

  • Updated dependencies [347a5ca]

  • Updated dependencies [a8a8949]

  • Updated dependencies [632e45c]

  • Updated dependencies [75c5113]

  • Updated dependencies [899c2c4]

  • Updated dependencies [ca05917]

  • Updated dependencies [3ae9e92]

  • Updated dependencies [328580f]

  • Updated dependencies [0bffee2]

  • Updated dependencies [f329a26]

  • Updated dependencies [c827758]

  • Updated dependencies [6e9243c]

  • Updated dependencies [7a09cd9]

  • Updated dependencies [61a114c]

  • Updated dependencies [0d8347a]

  • Updated dependencies [7623ce1]

  • Updated dependencies [af94f67]

  • Updated dependencies [e87d694]

  • Updated dependencies [dd19e9e]

  • Updated dependencies [c245532]

  • Updated dependencies [34287d8]

  • Updated dependencies [64f9266]

  • Updated dependencies [0148d58]

  • Updated dependencies [765a656]

  • Updated dependencies [9db33cf]

  • Updated dependencies [bfd6f6c]

  • Updated dependencies [2054045]

  • Updated dependencies [c410709]

  • Updated dependencies [f555ec2]

  • Updated dependencies [d8e35a3]

  • Updated dependencies [5f7da9d]

  • Updated dependencies [7f5f902]

  • Updated dependencies [31adfce]

    • @solidjs/signals@2.0.0-rc.9

Don't miss a new solid release

NewReleases is sending notifications on new releases.