two-stroke 5.0.2 → 5.0.3
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/package.json +11 -11
- package/src/index.ts +10 -2
package/package.json
CHANGED
|
@@ -8,24 +8,24 @@
|
|
|
8
8
|
"type-check": "./bin/type-check.mjs"
|
|
9
9
|
},
|
|
10
10
|
"dependencies": {
|
|
11
|
-
"@cloudflare/vitest-pool-workers": "^0.8.
|
|
12
|
-
"@cloudflare/workers-types": "^4.
|
|
13
|
-
"@sentry/cli": "^2.
|
|
14
|
-
"@types/node": "^22.15.
|
|
15
|
-
"@typescript-eslint/eslint-plugin": "^8.
|
|
16
|
-
"@typescript-eslint/parser": "^8.
|
|
11
|
+
"@cloudflare/vitest-pool-workers": "^0.8.34",
|
|
12
|
+
"@cloudflare/workers-types": "^4.20250601.0",
|
|
13
|
+
"@sentry/cli": "^2.46.0",
|
|
14
|
+
"@types/node": "^22.15.29",
|
|
15
|
+
"@typescript-eslint/eslint-plugin": "^8.33.0",
|
|
16
|
+
"@typescript-eslint/parser": "^8.33.0",
|
|
17
17
|
"@vitest/coverage-istanbul": "^3.1.4",
|
|
18
18
|
"eslint-config-prettier": "^10.1.5",
|
|
19
|
-
"eslint-config-two-stroke": "^1.1.
|
|
19
|
+
"eslint-config-two-stroke": "^1.1.20",
|
|
20
20
|
"eslint-config-typescript": "^3.0.0",
|
|
21
21
|
"jose": "^6.0.11",
|
|
22
22
|
"jwk-subtle": "^1.0.7",
|
|
23
|
-
"miniflare": "^4.
|
|
23
|
+
"miniflare": "^4.20250525.0",
|
|
24
24
|
"openapi-fetch": "^0.14.0",
|
|
25
25
|
"openapi-typescript": "^7.8.0",
|
|
26
26
|
"pbkdf-subtle": "^1.0.0",
|
|
27
27
|
"toucan-js": "^4.1.1",
|
|
28
|
-
"zod": "^3.25.
|
|
28
|
+
"zod": "^3.25.47"
|
|
29
29
|
},
|
|
30
30
|
"peerDependencies": {
|
|
31
31
|
"@sentry/cli": ">=2",
|
|
@@ -49,10 +49,10 @@
|
|
|
49
49
|
"name": "two-stroke",
|
|
50
50
|
"packageManager": "yarn@4.6.0",
|
|
51
51
|
"type": "module",
|
|
52
|
-
"version": "5.0.
|
|
52
|
+
"version": "5.0.3",
|
|
53
53
|
"devDependencies": {
|
|
54
54
|
"@types/eslint": "^9.6.1",
|
|
55
|
-
"eslint": "^9.
|
|
55
|
+
"eslint": "^9.28.0",
|
|
56
56
|
"prettier": "^3.5.3",
|
|
57
57
|
"typescript": "^5.8.3",
|
|
58
58
|
"vitest": "^3.1.4"
|
package/src/index.ts
CHANGED
|
@@ -121,7 +121,7 @@ export function twoStroke<T extends Env>(title: string, release: string) {
|
|
|
121
121
|
JSON.stringify({
|
|
122
122
|
error: "Request body schema invalid",
|
|
123
123
|
issues: JSON.parse(body.error?.message ?? "{}") as unknown,
|
|
124
|
-
name: body.error?.name
|
|
124
|
+
name: body.error?.name,
|
|
125
125
|
}),
|
|
126
126
|
{
|
|
127
127
|
status: 400,
|
|
@@ -319,7 +319,15 @@ export function twoStroke<T extends Env>(title: string, release: string) {
|
|
|
319
319
|
parsedBatch: ZodSafeParseResult<z.output<I>>[];
|
|
320
320
|
}) => Promise<void>,
|
|
321
321
|
) {
|
|
322
|
-
_queue = async ({
|
|
322
|
+
_queue = async ({
|
|
323
|
+
batch,
|
|
324
|
+
env,
|
|
325
|
+
sentry,
|
|
326
|
+
}: {
|
|
327
|
+
batch: MessageBatch<z.input<I>>;
|
|
328
|
+
env: T;
|
|
329
|
+
sentry: Toucan;
|
|
330
|
+
}) => {
|
|
323
331
|
const parsedBatch = batch.messages.map((message) => {
|
|
324
332
|
const passed = input.safeParse(message.body);
|
|
325
333
|
if (!passed.success) {
|