ARKI_SCHEMA_E004

thrownThis error is thrown. It stops your code unless you catch it. Fix the cause below; catching it only hides the problem.

What happened

`assert` or `ensure` got a value the schema rejects. The value is a bug in the caller, so it throws instead of returning a failure.

Fix

Read `issues` on the error, then fix the code that produced the value. Use `parse` where bad data is expected.

Check the fix

bun run test -- src/assert.test.ts

Run it after the fix. It passes when the fix worked.

Where it comes from

Package
@arki/schema
Version
0.2.0 · next release candidate
Source
src/errors.ts:19