STET

flux-pr-4680

Zod (TypeScript) · W2 · GPT-5.4

pass_with_warn

Tests passed. 3/3 commands passed. Strength: strong.

69.2% run pass rate
Tier 1
primary testspassednon equivalentdecision conflictfail
pnpm build
gold passagent pass
find . -name vitest.config.ts -exec sed -i 's/test: {/test: { testTimeout: 30000,/' {} +
gold passagent pass
pnpm test -- --maxWorkers 1 --maxConcurrency 1 --retry 2
gold passagent pass

Partial score: 3/3

Publishable: yesCache: miss

Trajectory

unknown · partial order only

Canonical trajectory missing; showing coarse derived order only.

patch written
Patch captured
#1

Stet captured agent.patch for this trial.

validation
Tests passed
#2
equivalence
Equivalence judgment
#3

non_equivalent

code review
Code review judgment
#4

fail

decision
Final decision
#5

pass_with_warn

Quality

equivalence
non_equivalent
87% confidence
code review
fail · 40/100
2 findings
footprint
medium (0.38)
behavioral
100.0%
cost
$0.69 · 983K

Equivalence Reasoning

behavioral

The patch implements optional seconds and named `TimePrecision` exports, but it keeps accepting basic timezone offsets (`+02`, `+0200`) for datetimes with `offset: true`. The intended change (as reflected by the target behavior/docs) is to allow only `Z` or normalized colon offsets (`±HH:MM`) and reject basic offset forms. This is a functional mismatch in ISO datetime validation behavior.

Code Review

correctness: 1/4introduced bug risk: 1/4edge case handling: 2/4maintainability idioms: 3/4

The patch partially implements the goal (optional seconds and named precision) but likely does not satisfy the intended offset behavior: it continues accepting and preserving non-canonical basic offsets instead of enforcing canonical offset formatting.

2 findings
Datetime offset regex still allows unsupported basic offset forms
major

With `offset: true`, the regex `([+-]\d{2}(?::?\d{2})?)` accepts `+02` and `+0200`. Intended behavior is to allow canonical offsets (`+HH:MM`) and reject basic forms.

packages/zod/src/v4/core/regexes.ts:112
Accepted non-canonical offsets are preserved in output
major

Normalization was removed and tests now assert preserving `+02`/`+0200`. Combined with permissive parsing, this can propagate multiple wire formats where a canonical one was expected.

packages/zod/src/v4/core/schemas.ts:604