effect 4.0.0-beta.36 → 4.0.0-beta.37
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/Cause.d.ts +31 -0
- package/dist/Cause.d.ts.map +1 -1
- package/dist/Cause.js +19 -0
- package/dist/Cause.js.map +1 -1
- package/dist/Channel.d.ts +2 -2
- package/dist/Channel.d.ts.map +1 -1
- package/dist/Effect.d.ts +1 -16
- package/dist/Effect.d.ts.map +1 -1
- package/dist/Effect.js.map +1 -1
- package/dist/Schedule.d.ts.map +1 -1
- package/dist/Schedule.js +19 -1
- package/dist/Schedule.js.map +1 -1
- package/dist/Schema.d.ts +14 -42
- package/dist/Schema.d.ts.map +1 -1
- package/dist/Schema.js.map +1 -1
- package/dist/SchemaParser.d.ts +22 -66
- package/dist/SchemaParser.d.ts.map +1 -1
- package/dist/SchemaParser.js.map +1 -1
- package/dist/Sink.d.ts +5 -2
- package/dist/Sink.d.ts.map +1 -1
- package/dist/Sink.js.map +1 -1
- package/dist/Stream.d.ts +1 -1
- package/dist/Stream.d.ts.map +1 -1
- package/dist/internal/effect.js +15 -1
- package/dist/internal/effect.js.map +1 -1
- package/dist/unstable/cli/Prompt.js +16 -6
- package/dist/unstable/cli/Prompt.js.map +1 -1
- package/dist/unstable/devtools/DevToolsClient.d.ts.map +1 -1
- package/dist/unstable/devtools/DevToolsClient.js +4 -3
- package/dist/unstable/devtools/DevToolsClient.js.map +1 -1
- package/dist/unstable/devtools/DevToolsSchema.d.ts +2 -3
- package/dist/unstable/devtools/DevToolsSchema.d.ts.map +1 -1
- package/dist/unstable/devtools/DevToolsSchema.js +11 -1
- package/dist/unstable/devtools/DevToolsSchema.js.map +1 -1
- package/dist/unstable/http/HttpClientRequest.d.ts +24 -2
- package/dist/unstable/http/HttpClientRequest.d.ts.map +1 -1
- package/dist/unstable/http/HttpClientRequest.js +97 -0
- package/dist/unstable/http/HttpClientRequest.js.map +1 -1
- package/dist/unstable/http/HttpServerResponse.d.ts.map +1 -1
- package/dist/unstable/http/HttpServerResponse.js +2 -1
- package/dist/unstable/http/HttpServerResponse.js.map +1 -1
- package/dist/unstable/sql/Migrator.d.ts.map +1 -1
- package/dist/unstable/sql/Migrator.js +2 -2
- package/dist/unstable/sql/Migrator.js.map +1 -1
- package/dist/unstable/sql/SqlError.d.ts +229 -9
- package/dist/unstable/sql/SqlError.d.ts.map +1 -1
- package/dist/unstable/sql/SqlError.js +256 -6
- package/dist/unstable/sql/SqlError.js.map +1 -1
- package/package.json +1 -1
- package/src/Cause.ts +35 -0
- package/src/Channel.ts +2 -2
- package/src/Effect.ts +1 -16
- package/src/Schedule.ts +20 -8
- package/src/Schema.ts +6 -10
- package/src/SchemaParser.ts +25 -29
- package/src/Sink.ts +5 -2
- package/src/Stream.ts +1 -1
- package/src/internal/effect.ts +27 -2
- package/src/unstable/cli/Prompt.ts +15 -6
- package/src/unstable/devtools/DevToolsClient.ts +23 -18
- package/src/unstable/devtools/DevToolsSchema.ts +13 -1
- package/src/unstable/http/HttpClientRequest.ts +104 -2
- package/src/unstable/http/HttpServerResponse.ts +8 -4
- package/src/unstable/sql/Migrator.ts +7 -5
- package/src/unstable/sql/SqlError.ts +360 -8
package/dist/internal/effect.js
CHANGED
|
@@ -2117,7 +2117,7 @@ export const runSyncExitWith = services => {
|
|
|
2117
2117
|
scheduler
|
|
2118
2118
|
});
|
|
2119
2119
|
fiber.currentDispatcher?.flush();
|
|
2120
|
-
return fiber._exit ?? exitDie(fiber);
|
|
2120
|
+
return fiber._exit ?? exitDie(new AsyncFiberError(fiber));
|
|
2121
2121
|
};
|
|
2122
2122
|
};
|
|
2123
2123
|
/** @internal */
|
|
@@ -2489,6 +2489,20 @@ export class ExceededCapacityError extends /*#__PURE__*/TaggedError("ExceededCap
|
|
|
2489
2489
|
}
|
|
2490
2490
|
}
|
|
2491
2491
|
/** @internal */
|
|
2492
|
+
export const AsyncFiberErrorTypeId = "~effect/Cause/AsyncFiberError";
|
|
2493
|
+
/** @internal */
|
|
2494
|
+
export const isAsyncFiberError = u => hasProperty(u, AsyncFiberErrorTypeId);
|
|
2495
|
+
/** @internal */
|
|
2496
|
+
export class AsyncFiberError extends /*#__PURE__*/TaggedError("AsyncFiberError") {
|
|
2497
|
+
[AsyncFiberErrorTypeId] = AsyncFiberErrorTypeId;
|
|
2498
|
+
constructor(fiber) {
|
|
2499
|
+
super({
|
|
2500
|
+
message: "An asynchronous Effect was executed with Effect.runSync",
|
|
2501
|
+
fiber
|
|
2502
|
+
});
|
|
2503
|
+
}
|
|
2504
|
+
}
|
|
2505
|
+
/** @internal */
|
|
2492
2506
|
export const UnknownErrorTypeId = "~effect/Cause/UnknownError";
|
|
2493
2507
|
/** @internal */
|
|
2494
2508
|
export const isUnknownError = u => hasProperty(u, UnknownErrorTypeId);
|