Skip to content

refactor(result)!: remove resolve helper - #140

Merged
braden-w merged 3 commits into
mainfrom
codex/remove-resolve
Aug 20, 2026
Merged

braden-w merged 3 commits into
mainfrom
codex/remove-resolve

Conversation

@braden-w

Copy link
Copy Markdown
Collaborator

The Result query adapters already require Result-returning functions, so resolve added a second boundary name without a real caller. This makes unwrap the single operation for converting a known Result into a value-or-throwing contract.\n\nThe public resolve export and its mixed T | Result<T, E> behavior are removed. The query and mutation adapters now call unwrap, and the README and API documentation teach the single path.\n\n## Breaking\n\nresolve is no longer exported from wellcrafted/result.\n\nts\n// Before\nconst value = resolve(resultOrValue);\n\n// After\nconst value = unwrap(result);\n\n\nCallers that accept both plain values and Results should choose that union at their own boundary before calling unwrap.

braden-w added 2 commits July 17, 2026 11:34
Teach await-to-consume versus return-to-forward, preserve falsey errors, and separate failure mapping from transaction guarantees. Ground the distributable skill in shipped Wellcrafted source and tests.
The query adapters already require Result-returning functions, so resolve added a second boundary name without a real caller. Use unwrap for the single Result-to-throwing conversion.
@braden-w
braden-w marked this pull request as ready for review August 20, 2026 21:17
@braden-w
braden-w merged commit 68f781e into main Aug 20, 2026
2 checks passed
@braden-w
braden-w deleted the codex/remove-resolve branch August 20, 2026 21:19
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.

1 participant