@effect/sql-d1 4.0.0-rc.116 → 4.0.0-rc.118
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/AGENTS.md +4 -4
- package/CLAUDE.md +4 -4
- package/ai-docs/package.json +3 -3
- package/ai-docs/src/01_effect/03_services/20_layer-composition.ts +1 -1
- package/ai-docs/src/01_effect/06_running/20_layer-launch.ts +1 -1
- package/ai-docs/src/03_stream/30_encoding.ts +1 -1
- package/ai-docs/src/08_observability/20_otlp-tracing.ts +2 -2
- package/ai-docs/src/08_observability/index.md +1 -1
- package/ai-docs/src/40_sql/10_basics.ts +2 -2
- package/ai-docs/src/40_sql/index.md +1 -1
- package/ai-docs/src/50_http-client/10_basics.ts +1 -1
- package/ai-docs/src/51_http-server/10_basics.ts +2 -2
- package/ai-docs/src/51_http-server/20_testing.ts +2 -2
- package/ai-docs/src/51_http-server/fixtures/api/Api.ts +1 -1
- package/ai-docs/src/51_http-server/fixtures/api/Authorization.ts +1 -1
- package/ai-docs/src/51_http-server/fixtures/api/System.ts +1 -1
- package/ai-docs/src/51_http-server/fixtures/api/Users.ts +1 -1
- package/ai-docs/src/51_http-server/fixtures/domain/User.ts +1 -1
- package/ai-docs/src/51_http-server/fixtures/server/Users/http.ts +1 -1
- package/ai-docs/src/51_http-server/fixtures/server/Users.ts +1 -1
- package/ai-docs/src/60_child-process/10_working-with-child-processes.ts +1 -1
- package/ai-docs/src/60_child-process/index.md +1 -1
- package/ai-docs/src/70_cli/10_basics.ts +1 -1
- package/ai-docs/src/70_cli/index.md +1 -1
- package/ai-docs/src/71_ai/10_language-model.ts +2 -2
- package/ai-docs/src/71_ai/20_tools.ts +2 -2
- package/ai-docs/src/71_ai/30_chat.ts +2 -2
- package/ai-docs/src/80_cluster/10_entities.ts +3 -3
- package/dist/D1Client.d.ts +4 -4
- package/dist/D1Client.d.ts.map +1 -1
- package/dist/D1Client.js +4 -4
- package/dist/D1Client.js.map +1 -1
- package/package.json +5 -5
- package/src/D1Client.ts +5 -5
package/AGENTS.md
CHANGED
|
@@ -302,7 +302,7 @@ Use it when your Effect programs need testable current time, safe parsing, stabl
|
|
|
302
302
|
|
|
303
303
|
Effect has built-in support for structured logging, distributed tracing, and
|
|
304
304
|
metrics. For exporting telemetry, use the lightweight Otlp modules from
|
|
305
|
-
`effect/
|
|
305
|
+
`effect/observability` in new projects, or use
|
|
306
306
|
`@effect/opentelemetry` NodeSdk when integrating with an existing OpenTelemetry
|
|
307
307
|
setup.
|
|
308
308
|
|
|
@@ -344,7 +344,7 @@ if (Predicate.isObject(thing)) {
|
|
|
344
344
|
|
|
345
345
|
## Working with SQL databases
|
|
346
346
|
|
|
347
|
-
Use the `effect/
|
|
347
|
+
Use the `effect/sql` modules together with a driver package such as
|
|
348
348
|
`@effect/sql-sqlite-node` to access SQL databases. Define domain models with
|
|
349
349
|
`Model.Class` to derive schemas for the database and JSON boundaries, run
|
|
350
350
|
migrations, and write type-safe queries.
|
|
@@ -372,13 +372,13 @@ Build http clients with the `HttpClient` module.
|
|
|
372
372
|
|
|
373
373
|
## Working with child processes
|
|
374
374
|
|
|
375
|
-
Use the `effect/
|
|
375
|
+
Use the `effect/process` modules to define child processes and run them with `ChildProcessSpawner`.
|
|
376
376
|
|
|
377
377
|
- **[Working with child processes](./ai-docs/src/60_child-process/10_working-with-child-processes.ts)**: This example shows how to collect process output, compose pipelines, and stream long-running command output.
|
|
378
378
|
|
|
379
379
|
## Building CLI applications
|
|
380
380
|
|
|
381
|
-
Use the "effect/
|
|
381
|
+
Use the "effect/cli" modules to build CLI applications. These modules
|
|
382
382
|
provide utilities for parsing command-line arguments, handling user input, and
|
|
383
383
|
managing the flow of a CLI application.
|
|
384
384
|
|
package/CLAUDE.md
CHANGED
|
@@ -302,7 +302,7 @@ Use it when your Effect programs need testable current time, safe parsing, stabl
|
|
|
302
302
|
|
|
303
303
|
Effect has built-in support for structured logging, distributed tracing, and
|
|
304
304
|
metrics. For exporting telemetry, use the lightweight Otlp modules from
|
|
305
|
-
`effect/
|
|
305
|
+
`effect/observability` in new projects, or use
|
|
306
306
|
`@effect/opentelemetry` NodeSdk when integrating with an existing OpenTelemetry
|
|
307
307
|
setup.
|
|
308
308
|
|
|
@@ -344,7 +344,7 @@ if (Predicate.isObject(thing)) {
|
|
|
344
344
|
|
|
345
345
|
## Working with SQL databases
|
|
346
346
|
|
|
347
|
-
Use the `effect/
|
|
347
|
+
Use the `effect/sql` modules together with a driver package such as
|
|
348
348
|
`@effect/sql-sqlite-node` to access SQL databases. Define domain models with
|
|
349
349
|
`Model.Class` to derive schemas for the database and JSON boundaries, run
|
|
350
350
|
migrations, and write type-safe queries.
|
|
@@ -372,13 +372,13 @@ Build http clients with the `HttpClient` module.
|
|
|
372
372
|
|
|
373
373
|
## Working with child processes
|
|
374
374
|
|
|
375
|
-
Use the `effect/
|
|
375
|
+
Use the `effect/process` modules to define child processes and run them with `ChildProcessSpawner`.
|
|
376
376
|
|
|
377
377
|
- **[Working with child processes](./ai-docs/src/60_child-process/10_working-with-child-processes.ts)**: This example shows how to collect process output, compose pipelines, and stream long-running command output.
|
|
378
378
|
|
|
379
379
|
## Building CLI applications
|
|
380
380
|
|
|
381
|
-
Use the "effect/
|
|
381
|
+
Use the "effect/cli" modules to build CLI applications. These modules
|
|
382
382
|
provide utilities for parsing command-line arguments, handling user input, and
|
|
383
383
|
managing the flow of a CLI application.
|
|
384
384
|
|
package/ai-docs/package.json
CHANGED
|
@@ -27,10 +27,10 @@
|
|
|
27
27
|
"@effect/sql-sqlite-wasm": "workspace:*",
|
|
28
28
|
"@effect/vitest": "workspace:*",
|
|
29
29
|
"effect": "workspace:*",
|
|
30
|
-
"hono": "^4.13.
|
|
31
|
-
"nodemailer": "^10.0.
|
|
30
|
+
"hono": "^4.13.9",
|
|
31
|
+
"nodemailer": "^10.0.10"
|
|
32
32
|
},
|
|
33
33
|
"devDependencies": {
|
|
34
|
-
"@types/nodemailer": "^8.0.
|
|
34
|
+
"@types/nodemailer": "^8.0.2"
|
|
35
35
|
}
|
|
36
36
|
}
|
|
@@ -7,7 +7,7 @@
|
|
|
7
7
|
|
|
8
8
|
import { PgClient } from "@effect/sql-pg"
|
|
9
9
|
import { Array, Config, Context, Effect, Layer, type Option, Schema } from "effect"
|
|
10
|
-
import { SqlClient, SqlError } from "effect/
|
|
10
|
+
import { SqlClient, SqlError } from "effect/sql"
|
|
11
11
|
|
|
12
12
|
// Define a layer for the SqlClient service
|
|
13
13
|
export const SqlClientLayer: Layer.Layer<
|
|
@@ -5,7 +5,7 @@
|
|
|
5
5
|
*/
|
|
6
6
|
import { NodeHttpServer, NodeRuntime } from "@effect/platform-node"
|
|
7
7
|
import { Effect, Layer } from "effect"
|
|
8
|
-
import { HttpRouter, HttpServerResponse } from "effect/
|
|
8
|
+
import { HttpRouter, HttpServerResponse } from "effect/http"
|
|
9
9
|
import { createServer } from "node:http"
|
|
10
10
|
|
|
11
11
|
// Build a tiny HTTP app with a health-check endpoint.
|
|
@@ -5,7 +5,7 @@
|
|
|
5
5
|
* decode and encode streams of structured data.
|
|
6
6
|
*/
|
|
7
7
|
import { DateTime, Schema, Stream } from "effect"
|
|
8
|
-
import { Ndjson, SchemaBinary } from "effect/
|
|
8
|
+
import { Ndjson, SchemaBinary } from "effect/encoding"
|
|
9
9
|
|
|
10
10
|
// SchemaBinary derives a framed binary decoder directly from a schema.
|
|
11
11
|
export const schemaBinaryDecoder = SchemaBinary.decode(Schema.Struct({
|
|
@@ -5,8 +5,8 @@
|
|
|
5
5
|
*/
|
|
6
6
|
import { NodeRuntime } from "@effect/platform-node"
|
|
7
7
|
import { Context, Effect, Layer } from "effect"
|
|
8
|
-
import { FetchHttpClient } from "effect/
|
|
9
|
-
import { OtlpLogger, OtlpSerialization, OtlpTracer } from "effect/
|
|
8
|
+
import { FetchHttpClient } from "effect/http"
|
|
9
|
+
import { OtlpLogger, OtlpSerialization, OtlpTracer } from "effect/observability"
|
|
10
10
|
|
|
11
11
|
// Configure OTLP span export.
|
|
12
12
|
export const OtlpTracingLayer = OtlpTracer.layer({
|
|
@@ -2,6 +2,6 @@
|
|
|
2
2
|
|
|
3
3
|
Effect has built-in support for structured logging, distributed tracing, and
|
|
4
4
|
metrics. For exporting telemetry, use the lightweight Otlp modules from
|
|
5
|
-
`effect/
|
|
5
|
+
`effect/observability` in new projects, or use
|
|
6
6
|
`@effect/opentelemetry` NodeSdk when integrating with an existing OpenTelemetry
|
|
7
7
|
setup.
|
|
@@ -7,8 +7,8 @@
|
|
|
7
7
|
import { NodeRuntime } from "@effect/platform-node"
|
|
8
8
|
import { SqliteClient, SqliteMigrator } from "@effect/sql-sqlite-node"
|
|
9
9
|
import { Context, Effect, Layer, Schema } from "effect"
|
|
10
|
-
import { Model } from "effect/
|
|
11
|
-
import { SqlClient, SqlModel, SqlSchema } from "effect/
|
|
10
|
+
import { Model } from "effect/schema"
|
|
11
|
+
import { SqlClient, SqlModel, SqlSchema } from "effect/sql"
|
|
12
12
|
|
|
13
13
|
// Use a branded string for the group id, so it cannot be mixed up with other
|
|
14
14
|
// string ids in the application.
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
## Working with SQL databases
|
|
2
2
|
|
|
3
|
-
Use the `effect/
|
|
3
|
+
Use the `effect/sql` modules together with a driver package such as
|
|
4
4
|
`@effect/sql-sqlite-node` to access SQL databases. Define domain models with
|
|
5
5
|
`Model.Class` to derive schemas for the database and JSON boundaries, run
|
|
6
6
|
migrations, and write type-safe queries.
|
|
@@ -4,7 +4,7 @@
|
|
|
4
4
|
* Define a service that uses the HttpClient module to fetch data from an external API
|
|
5
5
|
*/
|
|
6
6
|
import { Context, Effect, flow, Layer, Schedule, Schema } from "effect"
|
|
7
|
-
import { FetchHttpClient, HttpClient, HttpClientRequest, HttpClientResponse } from "effect/
|
|
7
|
+
import { FetchHttpClient, HttpClient, HttpClientRequest, HttpClientResponse } from "effect/http"
|
|
8
8
|
|
|
9
9
|
class Todo extends Schema.Class<Todo>("Todo")({
|
|
10
10
|
userId: Schema.Int,
|
|
@@ -6,8 +6,8 @@
|
|
|
6
6
|
*/
|
|
7
7
|
import { NodeHttpServer, NodeRuntime } from "@effect/platform-node"
|
|
8
8
|
import { Context, Effect, flow, Layer, Schedule } from "effect"
|
|
9
|
-
import { FetchHttpClient, HttpClient, HttpClientRequest, HttpRouter, HttpServer } from "effect/
|
|
10
|
-
import { HttpApiBuilder, HttpApiClient, HttpApiMiddleware, HttpApiScalar } from "effect/
|
|
9
|
+
import { FetchHttpClient, HttpClient, HttpClientRequest, HttpRouter, HttpServer } from "effect/http"
|
|
10
|
+
import { HttpApiBuilder, HttpApiClient, HttpApiMiddleware, HttpApiScalar } from "effect/http-api"
|
|
11
11
|
import { createServer } from "node:http"
|
|
12
12
|
// Api definitions should **always** be seperate from the server implementation,
|
|
13
13
|
// so that they can be shared between the server and client without leaking
|
|
@@ -6,8 +6,8 @@
|
|
|
6
6
|
*/
|
|
7
7
|
import { assert, layer } from "@effect/vitest"
|
|
8
8
|
import { Effect, Layer } from "effect"
|
|
9
|
-
import { HttpClientRequest, HttpServer } from "effect/
|
|
10
|
-
import { HttpApiMiddleware, HttpApiTest } from "effect/
|
|
9
|
+
import { HttpClientRequest, HttpServer } from "effect/http"
|
|
10
|
+
import { HttpApiMiddleware, HttpApiTest } from "effect/http-api"
|
|
11
11
|
import { Api } from "./fixtures/api/Api.ts"
|
|
12
12
|
import { Authorization } from "./fixtures/api/Authorization.ts"
|
|
13
13
|
import { UserId } from "./fixtures/domain/User.ts"
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { Context, Schema } from "effect"
|
|
2
|
-
import { HttpApiMiddleware, HttpApiSecurity } from "effect/
|
|
2
|
+
import { HttpApiMiddleware, HttpApiSecurity } from "effect/http-api"
|
|
3
3
|
import type { User } from "../domain/User.ts"
|
|
4
4
|
|
|
5
5
|
export class CurrentUser extends Context.Service<CurrentUser, User>()("acme/HttpApi/Authorization/CurrentUser") {}
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { Schema } from "effect"
|
|
2
|
-
import { HttpApiEndpoint, HttpApiError, HttpApiGroup, HttpApiSchema, OpenApi } from "effect/
|
|
2
|
+
import { HttpApiEndpoint, HttpApiError, HttpApiGroup, HttpApiSchema, OpenApi } from "effect/http-api"
|
|
3
3
|
import { User, UserId } from "../domain/User.ts"
|
|
4
4
|
import { SearchQueryTooShort, UserNotFound } from "../domain/UserErrors.ts"
|
|
5
5
|
import { Authorization } from "./Authorization.ts"
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { Effect, Layer } from "effect"
|
|
2
|
-
import { HttpApiBuilder, HttpApiError } from "effect/
|
|
2
|
+
import { HttpApiBuilder, HttpApiError } from "effect/http-api"
|
|
3
3
|
import { Api } from "../../api/Api.ts"
|
|
4
4
|
import { CurrentUser } from "../../api/Authorization.ts"
|
|
5
5
|
import { AuthorizationLayer } from "../Authorization.ts"
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { SqliteClient, SqliteMigrator } from "@effect/sql-sqlite-node"
|
|
2
2
|
import { Context, Effect, Layer, Schema } from "effect"
|
|
3
|
-
import { SqlClient, SqlModel, SqlSchema } from "effect/
|
|
3
|
+
import { SqlClient, SqlModel, SqlSchema } from "effect/sql"
|
|
4
4
|
import { User } from "../domain/User.ts"
|
|
5
5
|
import type { UserId } from "../domain/User.ts"
|
|
6
6
|
import { SearchQueryTooShort, UserNotFound, UsersError } from "../domain/UserErrors.ts"
|
|
@@ -5,7 +5,7 @@
|
|
|
5
5
|
*/
|
|
6
6
|
import { NodeServices } from "@effect/platform-node"
|
|
7
7
|
import { Console, Context, Effect, Layer, Schema, Stream, String } from "effect"
|
|
8
|
-
import { ChildProcess, ChildProcessSpawner } from "effect/
|
|
8
|
+
import { ChildProcess, ChildProcessSpawner } from "effect/process"
|
|
9
9
|
|
|
10
10
|
export class DevToolsError extends Schema.TaggedError<DevToolsError>()("DevToolsError", {
|
|
11
11
|
cause: Schema.Defect()
|
|
@@ -6,7 +6,7 @@
|
|
|
6
6
|
*/
|
|
7
7
|
import { NodeRuntime, NodeServices } from "@effect/platform-node"
|
|
8
8
|
import { Console, Effect, Option, Schema } from "effect"
|
|
9
|
-
import { Argument, Command, Flag } from "effect/
|
|
9
|
+
import { Argument, Command, Flag } from "effect/cli"
|
|
10
10
|
|
|
11
11
|
// You can define flags outside of commands and reuse them across multiple
|
|
12
12
|
// commands.
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
## Building CLI applications
|
|
2
2
|
|
|
3
|
-
Use the "effect/
|
|
3
|
+
Use the "effect/cli" modules to build CLI applications. These modules
|
|
4
4
|
provide utilities for parsing command-line arguments, handling user input, and
|
|
5
5
|
managing the flow of a CLI application.
|
|
@@ -7,8 +7,8 @@
|
|
|
7
7
|
import { AnthropicClient, AnthropicLanguageModel } from "@effect/ai-anthropic"
|
|
8
8
|
import { OpenAiClient, OpenAiLanguageModel } from "@effect/ai-openai"
|
|
9
9
|
import { Config, Context, Effect, ExecutionPlan, Layer, Schema, Stream } from "effect"
|
|
10
|
-
import { AiError, LanguageModel, Model, type Response } from "effect/
|
|
11
|
-
import { FetchHttpClient } from "effect/
|
|
10
|
+
import { AiError, LanguageModel, Model, type Response } from "effect/ai"
|
|
11
|
+
import { FetchHttpClient } from "effect/http"
|
|
12
12
|
import { LaunchPlan } from "./fixtures/domain/LaunchPlan.ts"
|
|
13
13
|
|
|
14
14
|
// You can use Config to create ai clients
|
|
@@ -6,8 +6,8 @@
|
|
|
6
6
|
*/
|
|
7
7
|
import { OpenAiClient, OpenAiLanguageModel, OpenAiTool } from "@effect/ai-openai"
|
|
8
8
|
import { Config, Context, Effect, Layer, Schema } from "effect"
|
|
9
|
-
import { AiError, LanguageModel, Tool, Toolkit } from "effect/
|
|
10
|
-
import { FetchHttpClient } from "effect/
|
|
9
|
+
import { AiError, LanguageModel, Tool, Toolkit } from "effect/ai"
|
|
10
|
+
import { FetchHttpClient } from "effect/http"
|
|
11
11
|
|
|
12
12
|
// ---------------------------------------------------------------------------
|
|
13
13
|
// 1. Defining tools
|
|
@@ -6,8 +6,8 @@
|
|
|
6
6
|
*/
|
|
7
7
|
import { OpenAiClient, OpenAiLanguageModel } from "@effect/ai-openai"
|
|
8
8
|
import { Config, Context, DateTime, Effect, Layer, Ref, Schema } from "effect"
|
|
9
|
-
import { AiError, Chat, Prompt, Tool, Toolkit } from "effect/
|
|
10
|
-
import { FetchHttpClient } from "effect/
|
|
9
|
+
import { AiError, Chat, Prompt, Tool, Toolkit } from "effect/ai"
|
|
10
|
+
import { FetchHttpClient } from "effect/http"
|
|
11
11
|
|
|
12
12
|
// ---------------------------------------------------------------------------
|
|
13
13
|
// Provider setup
|
|
@@ -5,9 +5,9 @@
|
|
|
5
5
|
*/
|
|
6
6
|
import { NodeClusterSocket, NodeRuntime } from "@effect/platform-node"
|
|
7
7
|
import { Effect, Layer, Ref, Schema } from "effect"
|
|
8
|
-
import { ClusterSchema, Entity, TestRunner } from "effect/
|
|
9
|
-
import { Rpc } from "effect/
|
|
10
|
-
import type { SqlClient } from "effect/
|
|
8
|
+
import { ClusterSchema, Entity, TestRunner } from "effect/cluster"
|
|
9
|
+
import { Rpc } from "effect/rpc"
|
|
10
|
+
import type { SqlClient } from "effect/sql"
|
|
11
11
|
|
|
12
12
|
export const Increment = Rpc.make("Increment", {
|
|
13
13
|
payload: { amount: Schema.Int },
|
package/dist/D1Client.d.ts
CHANGED
|
@@ -16,11 +16,11 @@ import * as Context from "effect/Context";
|
|
|
16
16
|
import * as Duration from "effect/Duration";
|
|
17
17
|
import * as Effect from "effect/Effect";
|
|
18
18
|
import * as Layer from "effect/Layer";
|
|
19
|
+
import * as Reactivity from "effect/reactivity/Reactivity";
|
|
19
20
|
import type * as Scope from "effect/Scope";
|
|
20
|
-
import * as
|
|
21
|
-
import
|
|
22
|
-
import
|
|
23
|
-
import * as Statement from "effect/unstable/sql/Statement";
|
|
21
|
+
import * as Client from "effect/sql/SqlClient";
|
|
22
|
+
import { SqlError } from "effect/sql/SqlError";
|
|
23
|
+
import * as Statement from "effect/sql/Statement";
|
|
24
24
|
/**
|
|
25
25
|
* Unique runtime identifier used to tag `D1Client` values.
|
|
26
26
|
*
|
package/dist/D1Client.d.ts.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"D1Client.d.ts","sourceRoot":"","sources":["../src/D1Client.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;GAWG;AACH,OAAO,KAAK,EAAE,UAAU,EAAiC,MAAM,2BAA2B,CAAA;AAE1F,OAAO,KAAK,MAAM,MAAM,eAAe,CAAA;AACvC,OAAO,KAAK,OAAO,MAAM,gBAAgB,CAAA;AACzC,OAAO,KAAK,QAAQ,MAAM,iBAAiB,CAAA;AAC3C,OAAO,KAAK,MAAM,MAAM,eAAe,CAAA;AAEvC,OAAO,KAAK,KAAK,MAAM,cAAc,CAAA;AACrC,OAAO,KAAK,
|
|
1
|
+
{"version":3,"file":"D1Client.d.ts","sourceRoot":"","sources":["../src/D1Client.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;GAWG;AACH,OAAO,KAAK,EAAE,UAAU,EAAiC,MAAM,2BAA2B,CAAA;AAE1F,OAAO,KAAK,MAAM,MAAM,eAAe,CAAA;AACvC,OAAO,KAAK,OAAO,MAAM,gBAAgB,CAAA;AACzC,OAAO,KAAK,QAAQ,MAAM,iBAAiB,CAAA;AAC3C,OAAO,KAAK,MAAM,MAAM,eAAe,CAAA;AAEvC,OAAO,KAAK,KAAK,MAAM,cAAc,CAAA;AACrC,OAAO,KAAK,UAAU,MAAM,8BAA8B,CAAA;AAC1D,OAAO,KAAK,KAAK,KAAK,MAAM,cAAc,CAAA;AAC1C,OAAO,KAAK,MAAM,MAAM,sBAAsB,CAAA;AAE9C,OAAO,EAAE,QAAQ,EAAgB,MAAM,qBAAqB,CAAA;AAC5D,OAAO,KAAK,SAAS,MAAM,sBAAsB,CAAA;AAUjD;;;;;GAKG;AACH,eAAO,MAAM,MA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;CACrE;AA0ED;;;;;GAKG;AACH,eAAO,MAAM,IAAI,YACN,cAAc,KACtB,MAAM,CAAC,MAAM,CAAC,QAAQ,EAAE,KAAK,EAAE,KAAK,CAAC,KAAK,GAAG,UAAU,CAAC,UAAU,CA4KjE,CAAA;AAEJ;;;;;GAKG;AACH,eAAO,MAAM,WAAW,WACd,MAAM,CAAC,IAAI,CAAC,cAAc,CAAC,KAClC,KAAK,CAAC,KAAK,CAAC,QAAQ,GAAG,MAAM,CAAC,SAAS,EAAE,MAAM,CAAC,WAAW,CAUrB,CAAA;AAEzC;;;;;GAKG;AACH,eAAO,MAAM,KAAK,WACR,cAAc,KACrB,KAAK,CAAC,KAAK,CAAC,QAAQ,GAAG,MAAM,CAAC,SAAS,EAAE,MAAM,CAAC,WAAW,CAMrB,CAAA"}
|
package/dist/D1Client.js
CHANGED
|
@@ -5,11 +5,11 @@ import * as Duration from "effect/Duration";
|
|
|
5
5
|
import * as Effect from "effect/Effect";
|
|
6
6
|
import { identity } from "effect/Function";
|
|
7
7
|
import * as Layer from "effect/Layer";
|
|
8
|
+
import * as Reactivity from "effect/reactivity/Reactivity";
|
|
9
|
+
import * as Client from "effect/sql/SqlClient";
|
|
10
|
+
import { SqlError, UnknownError } from "effect/sql/SqlError";
|
|
11
|
+
import * as Statement from "effect/sql/Statement";
|
|
8
12
|
import * as Stream from "effect/Stream";
|
|
9
|
-
import * as Reactivity from "effect/unstable/reactivity/Reactivity";
|
|
10
|
-
import * as Client from "effect/unstable/sql/SqlClient";
|
|
11
|
-
import { SqlError, UnknownError } from "effect/unstable/sql/SqlError";
|
|
12
|
-
import * as Statement from "effect/unstable/sql/Statement";
|
|
13
13
|
const ATTR_DB_SYSTEM_NAME = "db.system.name";
|
|
14
14
|
const ATTR_DB_OPERATION_NAME = "db.operation.name";
|
|
15
15
|
const ATTR_DB_QUERY_TEXT = "db.query.text";
|
package/dist/D1Client.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"D1Client.js","names":[],"sources":["../src/D1Client.ts"],"sourcesContent":[null],"mappings":"AAaA,OAAO,KAAK,KAAK,MAAM,cAAc;AACrC,OAAO,KAAK,MAAM,MAAM,eAAe;AACvC,OAAO,KAAK,OAAO,MAAM,gBAAgB;AACzC,OAAO,KAAK,QAAQ,MAAM,iBAAiB;AAC3C,OAAO,KAAK,MAAM,MAAM,eAAe;AACvC,SAAS,QAAQ,QAAQ,iBAAiB;AAC1C,OAAO,KAAK,KAAK,MAAM,cAAc;
|
|
1
|
+
{"version":3,"file":"D1Client.js","names":[],"sources":["../src/D1Client.ts"],"sourcesContent":[null],"mappings":"AAaA,OAAO,KAAK,KAAK,MAAM,cAAc;AACrC,OAAO,KAAK,MAAM,MAAM,eAAe;AACvC,OAAO,KAAK,OAAO,MAAM,gBAAgB;AACzC,OAAO,KAAK,QAAQ,MAAM,iBAAiB;AAC3C,OAAO,KAAK,MAAM,MAAM,eAAe;AACvC,SAAS,QAAQ,QAAQ,iBAAiB;AAC1C,OAAO,KAAK,KAAK,MAAM,cAAc;AACrC,OAAO,KAAK,UAAU,MAAM,8BAA8B;AAE1D,OAAO,KAAK,MAAM,MAAM,sBAAsB;AAE9C,SAAS,QAAQ,EAAE,YAAY,QAAQ,qBAAqB;AAC5D,OAAO,KAAK,SAAS,MAAM,sBAAsB;AACjD,OAAO,KAAK,MAAM,MAAM,eAAe;AAEvC,MAAM,mBAAmB,GAAG,gBAAgB;AAC5C,MAAM,sBAAsB,GAAG,mBAAmB;AAClD,MAAM,kBAAkB,GAAG,eAAe;AAE1C,MAAM,aAAa,GAAG,CAAC,KAAc,EAAE,OAAe,EAAE,SAAiB,KACvE,IAAI,YAAY,CAAC;EAAE,KAAK;EAAE,OAAO;EAAE;AAAS,CAAE,CAAC;AAEjD;;;;;;AAMA,OAAO,MAAM,MAAM,GAAW,0BAA0B;AAiDxD;;;;;;;;;;;AAWA,OAAO,MAAM,QAAQ,gBAAG,OAAO,CAAC,OAAO,CAAW,yBAAy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AM,CAAC,SAAS,EAAE,MAAM,CAAC,CACtC,CACF,CACF,CACF,CAAC,IAAI,CAAC,KAAK,CAAC,OAAO,CAAC,UAAU,CAAC,KAAK,CAAC,CAAC;AAEzC;;;;;;AAMA,OAAO,MAAM,KAAK,GAChB,MAAsB,IAEtB,KAAK,CAAC,aAAa,CACjB,MAAM,CAAC,GAAG,CAAC,IAAI,CAAC,MAAM,CAAC,EAAG,MAAM,IAC9B,OAAO,CAAC,IAAI,CAAC,QAAQ,EAAE,MAAM,CAAC,CAAC,IAAI,CACjC,OAAO,CAAC,GAAG,CAAC,MAAM,CAAC,SAAS,EAAE,MAAM,CAAC,CACtC,CAAC,CACL,CAAC,IAAI,CAAC,KAAK,CAAC,OAAO,CAAC,UAAU,CAAC,KAAK,CAAC,CAAC","ignoreList":[]}
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@effect/sql-d1",
|
|
3
|
-
"version": "4.0.0-rc.
|
|
3
|
+
"version": "4.0.0-rc.118",
|
|
4
4
|
"type": "module",
|
|
5
5
|
"license": "MIT",
|
|
6
6
|
"description": "A Cloudflare D1 integration for Effect",
|
|
@@ -51,14 +51,14 @@
|
|
|
51
51
|
"provenance": true
|
|
52
52
|
},
|
|
53
53
|
"devDependencies": {
|
|
54
|
-
"miniflare": "5.
|
|
55
|
-
"effect": "^4.0.0-rc.
|
|
54
|
+
"miniflare": "5.20260925.0-alpha",
|
|
55
|
+
"effect": "^4.0.0-rc.118"
|
|
56
56
|
},
|
|
57
57
|
"peerDependencies": {
|
|
58
|
-
"effect": "^4.0.0-rc.
|
|
58
|
+
"effect": "^4.0.0-rc.118"
|
|
59
59
|
},
|
|
60
60
|
"dependencies": {
|
|
61
|
-
"@cloudflare/workers-types": "^5.
|
|
61
|
+
"@cloudflare/workers-types": "^5.20260926.1"
|
|
62
62
|
},
|
|
63
63
|
"scripts": {
|
|
64
64
|
"codegen": "effect-utils codegen",
|
package/src/D1Client.ts
CHANGED
|
@@ -18,13 +18,13 @@ import * as Duration from "effect/Duration"
|
|
|
18
18
|
import * as Effect from "effect/Effect"
|
|
19
19
|
import { identity } from "effect/Function"
|
|
20
20
|
import * as Layer from "effect/Layer"
|
|
21
|
+
import * as Reactivity from "effect/reactivity/Reactivity"
|
|
21
22
|
import type * as Scope from "effect/Scope"
|
|
23
|
+
import * as Client from "effect/sql/SqlClient"
|
|
24
|
+
import type { Connection } from "effect/sql/SqlConnection"
|
|
25
|
+
import { SqlError, UnknownError } from "effect/sql/SqlError"
|
|
26
|
+
import * as Statement from "effect/sql/Statement"
|
|
22
27
|
import * as Stream from "effect/Stream"
|
|
23
|
-
import * as Reactivity from "effect/unstable/reactivity/Reactivity"
|
|
24
|
-
import * as Client from "effect/unstable/sql/SqlClient"
|
|
25
|
-
import type { Connection } from "effect/unstable/sql/SqlConnection"
|
|
26
|
-
import { SqlError, UnknownError } from "effect/unstable/sql/SqlError"
|
|
27
|
-
import * as Statement from "effect/unstable/sql/Statement"
|
|
28
28
|
|
|
29
29
|
const ATTR_DB_SYSTEM_NAME = "db.system.name"
|
|
30
30
|
const ATTR_DB_OPERATION_NAME = "db.operation.name"
|