Effect
Version 4.0.0-beta.84
Patch Changes
-
#2420
87f52baThanks @tim-smart! - AddEffect.transposeOptionfor converting anOption<Effect<A, E, R>>into anEffect<Option<A>, E, R>. -
#2374
b8ee07fThanks @gcanti! - Import unconstrained JSON Schema nodes asSchema.Jsoninstead ofSchema.Unknown. -
#2407
867c0d7Thanks @gcanti! - Normalize error behavior for Schema and SchemaParser boundary APIs.SchemaErrornow extendsData.TaggedError, so it is also a nativeError. SchemaParser Promise APIs now reject anErrorwhose cause is theSchemaIssue.Issuefor schema failures.Schema and SchemaParser
EffectandExitadapters now preserve full causes while mapping schema issue failures to their public error type. Theis,asserts,Promise,Sync,Result,Option,make, andmakeOptionadapters now distinguish schema issues from non-schema causes. Schema-only failures are converted to the adapter’s normal representation (false, rejected or thrown schema error,Result.fail, orNone), while non-schema causes throw or reject with anErrorwhose cause is the underlyingCause. -
#2409
b93bc6cThanks @tim-smart! - Fix Stream.runForEachWhile so it continues across chunk boundaries while the predicate returns true and stops when the predicate returns false. -
#2424
57d387fThanks @tim-smart! - Fix cluster workflow activity defect hydration -
#2403
bacca41Thanks @lloydrichards! - align ProcessInput.Input runtime field name with type definition on Prompt.custom -
#2423
0f8ac79Thanks @tim-smart! - RpcGroup.toHandlers is definition first -
#2383
25b4482Thanks @gcanti! - Fix config path composition and directory-backed lookup behavior.ConfigProvider.orElsenow keeps each side’s ownnestedandmapInputbehavior. ApplyingnestedormapInputto a combined provider now applies the same transformation to both sides.ConfigProviderpath transformations now compose as a single path function. This makesnestedandmapInputbehave consistently with normal function composition.Config.nestednow tracks the logical config path inConfigitself instead of wrapping the provider. This keeps lookup paths and schema error paths aligned. The low-levelConfig.makeconstructor is no longer exported; use config constructors and combinators, or implement custom lookup behavior withConfigProvider.make.ConfigProvider.fromDirnow returnsundefinedwhen neither a file nor a directory exists at the requested path, soorElsecan fall back instead of failing withSourceError. -
#2415
9cf3a25Thanks @gcanti! - FixEffect.trythunk usage andEffect.tryPromisemapper and signal handling defects.Effect.trynow supports passing a thunk directly, matchingEffect.tryPromise. Thrown values from direct-thunk usage are mapped toCause.UnknownError.When a promise handled by
Effect.tryPromiserejected and the customcatchmapper threw while mapping that rejection, the effect could remain pending and produce an unhandled rejection. The mapper is now guarded consistently with the synchronous throw path, so a thrown mapper error becomes an Effect defect. The JSDoc forEffect.tryandEffect.tryPromisewas also corrected.Effect.tryPromisenow also only creates anAbortControllerwhen the wrapped thunk declares anAbortSignalparameter. -
#2417
8def767Thanks @tim-smart! - deduplicate SqlResolver.findById requests