Skip to content

feat!: migrate to unthrown 3.0.0#276

Merged
btravers merged 1 commit into
mainfrom
feat/unthrown-v3
Jun 30, 2026
Merged

feat!: migrate to unthrown 3.0.0#276
btravers merged 1 commit into
mainfrom
feat/unthrown-v3

Conversation

@btravers

Copy link
Copy Markdown
Collaborator

Summary

Upgrades to unthrown 3.0.0, following the 1.0/2.0 migrations (all merged).

3.0.0's breaking change removes the standalone Defect constructor — defects are now produced via a defect argument passed into fromPromise / fromThrowable's qualify callback. temporal-contract never constructs defects (every boundary maps rejections to a modeled error: ApplicationFailure, RuntimeClientError, classifyHandleError, …), so this change doesn't touch us. No source changes — just a version bump.

What changed

  • unthrown + @unthrown/vitest catalog entries → 3.0.0.
  • Published packages' unthrown peer range → ^3.
  • Migration-guide install snippet → ^3.
  • major changeset (requiring unthrown ^3 is breaking for consumers on 2.x).

Unchanged (verified against the new .d.ts)

Ok / Err constructors, TaggedError, matchTags, fromPromise / fromSafePromise, result.match({ ok, err, defect }), .toAsync(), and result.isOk() / isErr() / isDefect() narrowing — all identical. @unthrown/vitest matchers unchanged.

Verification

typecheck · oxlint · oxfmt · knip · 271 unit tests · integration tests (8/8) · docs build — all green, no code changes required.

🤖 Generated with Claude Code

unthrown 3.0.0 removes the standalone `Defect` constructor in favour of a
`defect` argument passed into `fromPromise` / `fromThrowable`'s `qualify`
callback. temporal-contract never constructs defects (every boundary maps
rejections to a modeled error), so no source changes are needed — the `Ok` /
`Err` constructors, `TaggedError`, `matchTags`, `fromPromise` /
`fromSafePromise`, `result.match({ ok, err, defect })`, `.toAsync()`, and
`result.isOk()` / `isErr()` / `isDefect()` narrowing are all unchanged.

Bumps the `unthrown` / `@unthrown/vitest` catalog entries to 3.0.0 and the
published packages' `unthrown` peer range to `^3`.

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
Copilot AI review requested due to automatic review settings June 30, 2026 17:17

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

This PR upgrades the repo to unthrown 3.0.0 (and @unthrown/vitest 3.0.0), updating the workspace catalog, lockfile, and published package peer dependency ranges to ^3, plus updating migration docs and adding a changeset for the breaking peer-range bump.

Changes:

  • Bump catalog versions for unthrown and @unthrown/vitest to 3.0.0 and regenerate pnpm-lock.yaml.
  • Update published packages’ unthrown peer dependency ranges to ^3 (contract, client, worker).
  • Update migration documentation install snippet and add a breaking (major) changeset.

Reviewed changes

Copilot reviewed 6 out of 7 changed files in this pull request and generated 1 comment.

Show a summary per file
File Description
pnpm-workspace.yaml Catalog bump to unthrown/@unthrown/vitest 3.0.0.
pnpm-lock.yaml Lockfile updates reflecting unthrown/@unthrown/vitest 3.0.0.
packages/worker/package.json Peer dependency range moved to unthrown: ^3.
packages/contract/package.json Peer dependency range moved to unthrown: ^3.
packages/client/package.json Peer dependency range moved to unthrown: ^3.
docs/guide/migrating-to-unthrown.md Install snippet updated to unthrown: ^3.
.changeset/unthrown-v3.md Adds changeset describing the breaking peer-range bump (needs a correction per review).
Files not reviewed (1)
  • pnpm-lock.yaml: Generated file

Comment thread .changeset/unthrown-v3.md
@btravers btravers merged commit 6c79004 into main Jun 30, 2026
10 checks passed
@btravers btravers deleted the feat/unthrown-v3 branch June 30, 2026 17:21
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants