Effect
4.0.0-beta.37
Patch Changes
-
#1812
f7a0b71Thanks @tim-smart! - Consolidate the SqlError changes to the new reason-based shape across effect and the SQL drivers, classifying native failures into structured reasons with Unknown fallback where native codes are unavailable. -
#1816
1e223c3Thanks @tim-smart! - unstable/http HttpClientRequest: add toWeb and fromWeb conversions for web Request objects -
#1829
53740f4Thanks @tim-smart! - Fix sql migrator lock handling to only treat duplicate migration-row inserts as a concurrent migration lock. -
#1831
8c7cf89Thanks @tim-smart! - FixSchedule.fixedto run the next iteration immediately when the previous action takes longer than the configured interval. -
#1833
b6b81a9Thanks @tim-smart! - FixUnify.unifyso unions ofEffectvalues collapse to a single unifiedEffecttype again. -
#1825
8f4c1f9Thanks @skoshx! - Fix DevToolsClient not flushing final span events on teardown.The stream consumer was
forkScoped, causing it to be interrupted before it could drain remaining queue items. Replaced withforkChildandFiber.awaitin the finalizer so the stream drains naturally after the queue is failed. -
#1824
f2479f9Thanks @tim-smart! - Ignore unsupported Ctrl key combinations in interactive CLI prompts to avoid rendering control characters such as Ctrl+L form feed into prompt input. -
#1819
c919921Thanks @j! - HttpServerResponse: fixfromWebto preserve Content-Type header when response has a bodyPreviously, when converting a web
Responseto anHttpServerResponseviafromWeb, theContent-Typeheader was not passed toBody.stream(), causing it to default toapplication/octet-stream. This affected any code usingHttpApp.fromWebHandlerto wrap web handlers, as JSON responses would incorrectly have their Content-Type set toapplication/octet-streaminstead ofapplication/json. -
#1821
7af90c2Thanks @gcanti! - Schema: relaxassertsandisconstraints. -
#1822
f3be185Thanks @tim-smart! - improve runSync error when executing async effects
4.0.0-beta.36
Patch Changes
-
#1793
60fcbccThanks @tim-smart! - Ensure streamed tool results are emitted before the finish part so chat history includes tool outputs before stream termination. -
#1762
0a60837Thanks @kitlangton! - Allow unstable HttpApi middleware to declare multiple error schemas with arrays.Middleware errors now follow endpoint error behavior for response status resolution, client decoding, and generated API schemas.
-
#1805
49164d2Thanks @tim-smart! - FixEffect.cachedWithTTLandEffect.cachedInvalidateWithTTLto start TTL expiration when the cached value is produced instead of when computation starts. -
#1808
334b6e4Thanks @tim-smart! - BackportCron.prevwith reverse lookup tables and cron stepping logic, including DST-aware reverse traversal. -
#1789
5700695Thanks @mikearnaldi! - FixStream.scanEffecthanging and repeatedly emitting the initial state. -
#1810
f8f4456Thanks @tim-smart! - Support key-derivedidleTimeToLiveinLayerMapoptions (make,fromRecord, andLayerMap.Service) and addLayerMaptests for dynamic TTL behavior. -
#1802
969d24fThanks @kitlangton! - PubSub.publish and PubSub.publishAll now return false on shutdown instead of interrupting, matching Queue.offer semantics. -
#1796
851eda0Thanks @tim-smart! - ImprovePrompt.fileto support incremental filtering while typing, including backspace and ctrl-u handling. -
#1806
8059c1cThanks @tim-smart! - Fix a regression inPubSub.shutdownso shutting down a pubsub interrupts suspended subscribers (includingtakeAll) by ensuring subscriptions are scoped under the pubsub shutdown scope. -
#1797
6f83295Thanks @tim-smart! - Add `Ctrl-A` and `Ctrl-E` key handling for editable CLI text prompts to move the cursor to the beginning or end of the current input line. -
#1633
65f7f57Thanks @kitlangton! - Schema: adddecodeUnknownResult/decodeResultandencodeUnknownResult/encodeResulthelpers for synchronousResult-based parsing. -
#1798
e7fabd2Thanks @gcanti! - Schema: allow usingStructtype helpers directly, e.g.Schema.Struct.Type<F>instead ofSchema.Schema.Type<Schema.Struct<F>>. -
#1794
89c3e98Thanks @tim-smart! - Fix ai LanguageModel streaming finish parts so finish events are always emitted when a toolkit is provided. -
#1785
53794abThanks @KhraksMamtsov! - add missing Equivalence.Date
4.0.0-beta.35
Patch Changes
-
#1784
7daf387Thanks @gcanti! - AddConfig.Successtype utility, closes #1783. -
#1778
e1664a3Thanks @tim-smart! - AllowEffect.acquireReleaserelease finalizers to depend on the surrounding environment. -
#1777
fdaa6e0Thanks @tim-smart! - Remove an unreachable array branch indecodeJsonRpcRawto simplify JSON-RPC decode logic without changing behavior. -
#1774
19aa47eThanks @tim-smart! - Align CLI help flag and global flag descriptions to a single column even when some flag names are very long. -
#1780
c667dadThanks @tim-smart! - FixLanguageModelincremental prompt fallback to reliably retry with the full prompt when an incremental request fails withInvalidRequestError. -
#1781
764d150Thanks @gcanti! - FixDateTime.makeUnsafeincorrectly appending “Z” to date strings containing “GMT” -
#1772
3c27098Thanks @tim-smart! - make Layer.mock work with Stream and Channel
4.0.0-beta.34
Patch Changes
-
#1758
f2f75eeThanks @tim-smart! - Use a normal Map in ResponseIdTracker and clear it on divergence / reset instead of reallocating a WeakMap. -
#1764
342fc4bThanks @tim-smart! - Add unstable EmbeddingModel support across core and OpenAI providers.- Add the unstable EmbeddingModel module API surface in
effect, including service, request, response, and provider types. - Implement the unstable EmbeddingModel runtime constructor in
effect, withRequestResolverbatching,embed/embedManyspans, provider error propagation, deterministic ordering, and empty-inputembedManyfast-path behavior. - Add and align EmbeddingModel behavior tests in
effectfor embedding usage, batching, ordering, and error handling. - Add
OpenAiEmbeddingModelin@effect/ai-openai, including model / make / layer constructors, config overrides, and provider output index validation with deterministic reordering. - Add OpenAI-compatible EmbeddingModel provider support in
@effect/ai-openai-compat, including config overrides, layer constructors, and output index validation.
- Add the unstable EmbeddingModel module API surface in
-
#1766
5d704eeThanks @tim-smart! - Fix JSDoc wording forEffect.catchto consistently reference the current API name. -
#1771
00add69Thanks @tim-smart! - AddEmbeddingModel.ModelDimensionsand require dimensions in embedding providermodelconstructors. -
#1767
58217d3Thanks @gcanti! - AddisMutableHashMapandisMutableHashSet, and align nominal guard implementations and tests across collections and transactional data types. -
#1765
f4e2abaThanks @tim-smart! - retry incremental prompt on invalid request -
#1756
e3b44b6Thanks @tim-smart! - add HttpApiMiddleware.layerSchemaErrorTransform -
#1732
e1472b7Thanks @KhraksMamtsov! - port Url module from v3 -
#1761
7686320Thanks @gcanti! - FixTool.maketype and runtime behavior whenparametersis not provided.
4.0.0-beta.33
Patch Changes
4.0.0-beta.32
Patch Changes
-
#1717
bf8fff8Thanks @gcanti! - Schema: addOptionFromOptionalNullOrschema, closes #1707. -
#1722
1af3ef3Thanks @tim-smart! - FixRpcSerialization.jsondecode so JSON array payloads are not wrapped in an extra outer array. -
#1725
27fea0fThanks @tim-smart! - Improve unstable HttpApi runtime failures for missing server middleware and missing group implementations.- HttpApiBuilder.applyMiddleware now resolves middleware services via Context.getUnsafe, so missing middleware fails with a clear “Service not found:
” error instead of an opaque is not a function TypeError. - HttpApiBuilder.layer now reports missing groups with actionable context (group identifier, service key, suggested HttpApiBuilder.group(…) call, and available group keys).
- Added regression tests in packages/platform-node/test/HttpApi.test.ts covering:
- addHttpApi + API-level middleware applied across merged groups
- missing middleware service diagnostics
- missing addHttpApi group layer diagnostics
- HttpApiBuilder.applyMiddleware now resolves middleware services via Context.getUnsafe, so missing middleware fails with a clear “Service not found:
-
#1727
2ad6c1bThanks @tim-smart! - Make all built-inHttpApiErrorclasses implementHttpServerRespondable, so they can be returned directly from plain HTTP server handlers outside ofHttpApi. -
#1739
398ac3eThanks @tim-smart! - Use predicate-baseddualdispatch forStream.mergeso data-last calls with optionaloptionsare handled correctly. -
#1741
51fe22fThanks @tim-smart! - AddLayer.tap,Layer.tapError, andLayer.tapCauseAPIs for effectful observation of layer success and failure without changing layer outputs. -
#1740
4605db6Thanks @tim-smart! - Refactor call sites with multipleContextmutations to useContext.mutatefor batched updates. -
#1750
f4de1b0Thanks @gcanti! - Improve unstable AI structured output handling for empty tool params and addTool.EmptyParams, closes #1749. -
#1525
60214f2Thanks @tim-smart! - use Option instead of undefined | A -
#1747
c4b8b0fThanks @tim-smart! - seperate scheduler dispatch from yield decisions -
#1753
6de4efeThanks @tim-smart! - Add dtslint coverage forStream.catchIfto lock in predicate and refinement inference behavior in both data-first and data-last forms. -
#1716
4f969d1Thanks @gcanti! - Remove unusedeffect/NullOrmodule. -
#1721
6cc67c8Thanks @IMax153! - Correct the type of the schema parameter accepted by thefileSchemamethods in the CLI to beSchema.Decoder<A> -
#1709
8531a22Thanks @mikearnaldi! - Add module-level helpers forSemaphore,Latch, and extractedPartitionedSemaphoreoperations. -
#1743
47a51abThanks @tim-smart! - default ws close codes to 1001 in case they are undefined -
#1728
1521d02Thanks @tim-smart! - add graceful shutdown to http servers
4.0.0-beta.31
Patch Changes
-
#1696
5a84853Thanks @krzkaczor! - AddDurationObjecttoDuration.Inputto support Temporal-style object input.Durations can now be created from objects with named unit properties like
{ hours: 1, minutes: 30 }, similar toTemporal.Duration.from(). Supported fields:weeks,days,hours,minutes,seconds,millis,micros,nanos. -
#1705
6f23f0eThanks @tim-smart! - Preserve message item ordering in the default logger when logging aCausewith message values. -
#1711
654aaecThanks @tim-smart! - FixRpcGroup.toLayerandRpcGroup.toLayerHandlerservice requirement inference so handler dependencies are preserved for non-stream RPC handlers. -
#1712
2958a42Thanks @tim-smart! - Expose CLI completions as a public unstable module ateffect/unstable/cli/Completions. -
#1713
95d27a2Thanks @tim-smart! - MakeLayer.mocka dual API so it supports bothLayer.mock(Service)(impl)andLayer.mock(Service, impl). -
#1704
0fbaea8Thanks @tim-smart! - Support toolkit unions inLanguageModeloptions. -
#1701
21d5d5eThanks @tim-smart! - wrap httpapi request context with HttpRouter.Request -
#1696
5a84853Thanks @krzkaczor! - allow assigning Temporal types to DateTime & Duration input -
#1698
6e49959Thanks @tim-smart! - Include toolkit tool handler requirements in AI generation API environment inference. -
#1703
8f5805dThanks @tim-smart! - RelaxNdjsonbyte-stream channel signatures to accept plainUint8Array. -
#1710
990df2cThanks @gcanti! - Schema:toCodecJsonnow returnsCodec<T, Json, RD, RE>instead ofCodec<T, unknown, RD, RE>.Http: the
jsonproperty onHttpIncomingMessage,HttpClientResponse,HttpServerRequest, andHttpServerResponsenow returnsEffect<Schema.Json, E>instead ofEffect<unknown, E>.
4.0.0-beta.30
Patch Changes
-
#1675
c88e5b7Thanks @gijsbartman! - Fix consolePretty ignoring explicit colors option in non-TTY environments.When colors is explicitly set to true, prettyLoggerTty was still gating it with processStdoutIsTTY check, making it impossible to enable colors in non-TTY environments like Vite dev server.
-
#1690
947d0e4Thanks @gcanti! - FixCause.hasInterruptsOnlyto returnfalsefor empty causes. -
#1620
7517908Thanks @kitlangton! - FixTaggedUnion.matchto useUnifyfor return types, allowing branches to return distinct Effect types that are properly merged. -
#1680
a49ecd5Thanks @KhraksMamtsov! - make HttpClientResponse pipeable -
#1681
6993e33Thanks @mikearnaldi! - Add an optionalmessagefield toEffect.ignoreandEffect.ignoreCausefor custom log output. -
#1695
514f2a2Thanks @gcanti! - Remove unused APIs from theUtilsmodule. -
#1644
3214b47Thanks @patroza! - fix: update Service interface to use ‘this: void’ in ‘of’ method signatures -
#1693
95ec5edThanks @tim-smart! - fix cli subcommand context
4.0.0-beta.29
Patch Changes
-
#1677
b52721cThanks @gcanti! - FixSchema.isUUIDso theversionparameter is optional in its public signature. -
#1667
a891c7bThanks @tim-smart! - PreserveAtom.withReactivity(...)refresh behavior when registry initial values seed the wrapped atom. -
#1678
ef26cdfThanks @tim-smart! - Abort HTTP client requests when response streams are consumed only partially. -
#1665
82fd3edThanks @tim-smart! - Remove placeholder fallback behavior from CLI prompt inputs now that default values are prefilled.
4.0.0-beta.28
Minor Changes
- #1637
42bc7ceThanks @tim-smart! - Add a neweffect/unstable/http/HttpStaticServermodule for static file serving with MIME resolution, directory index fallback, SPA fallback, and safe path resolution.
Patch Changes
-
#1659
ff533f2Thanks @tim-smart! - Persist MCP HTTP session and protocol headers after initialize so follow-up JSON-RPC requests includeMCP-Protocol-Version. -
#1663
dc803eeThanks @tim-smart! - AddHttpServerResponse.fromClientResponsefor directly converting client responses into server responses. -
#1657
d660b1cThanks @tim-smart! - AddCtrl-Uline clearing support to editable CLI prompts. -
#1645
93a05e3Thanks @gijsbartman! - ensure transformed Atom’s don’t extend idle ttl -
#1655
2a65cf6Thanks @tim-smart! - MakeAtomRpc.queryandAtomHttpApi.queryreturn serializable atoms by default when query results are schema-backed.The atom serialization key now uses each API’s built-in request schemas so dehydrated state can be keyed consistently across server and client.
-
#1662
a561a40Thanks @tim-smart! - AddHttpServerRequest.toClientRequestfor direct server-to-client request conversion. -
#1648
29cd24dThanks @gcanti! - FixTypes.VoidIfEmptyto correctly detect empty object types. Remove deprecatedTypes.MatchRecordin favor of the simplified implementation, closes #1647. -
#1664
662a8e6Thanks @tim-smart! - AddHttpServerRequest.fromClientRequestfor direct client-request-backed server request conversion. -
#1656
d2b52baThanks @tim-smart! - Persist MCP client capability context across HTTP requests by resolving initialized payloads through the standardMcp-Session-IdHTTP header inMcpServer.Adds a regression test that initializes an MCP HTTP client, verifies the MCP server echoes
Mcp-Session-Id, and then checks a later tool call can still readMcpServer.clientCapabilities. -
#1639
407c3b4Thanks @tim-smart! - AddScheduler.PreventSchedulerYieldand expose it viaReferencesso fibers can skip schedulershouldYieldchecks when needed. -
#1649
e741322Thanks @tim-smart! - SetSchema.TaggedErrorClassinstancenameto the tag value, matchingData.TaggedErrorbehavior. -
#1646
5c75fa8Thanks @tim-smart! - Simplify internal and documented request usage by passing request resolvers directly toEffect.requestinstead of wrapping them withEffect.succeed. -
#1641
747177bThanks @tim-smart! - Don’t transform Tool result schemas, as they aren’t sent to the providers as json schemas -
#1636
326cd48Thanks @tim-smart! - AddCookies.expireCookie/expireCookieUnsafeandHttpServerResponse.expireCookie/expireCookieUnsafefor emitting expired cookies. -
#1653
627e922Thanks @tim-smart! - expose mcp client capabilities -
#1660
662287eThanks @tim-smart! - AddHttpServerResponse.toClientResponsefor converting server responses intoHttpClientResponsevalues.