You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
attest: replace references to Node's builtin assertions #1287
attest currently relies on Node's builtin deepStrictEqual for its default .equals comparison, but this feels like a big problem:
import{type}from"arktype";importassertfrom"node:assert/strict";// Currently crashes with OOM exceptionassert.deepStrictEqual(type.string,type.boolean);
I'd like to find either a simple string diffing implementation we could use internally based on generate .snap contents or some targeted external solution for this without these issues (and potentially also clearer diffs).
In the meantime I will try to avoid this specific case happening by ensuring we only compare functions based on reference equality or similar.
Activity
PointSingularity commentedon Feb 1, 2025
Here are some potential options:
fix(attest): fail fast when .equals or .is compares a Type (#1287)
ssalbdivad commentedon Nov 18, 2026
Fixed in 3.0.0-beta.0 (#1728). Try it with
npm i arktype@next.