Skip to content

Commit 6faf52b

Browse files
authored
fix(typescript-sdk): random build failures (#78)
* fix(typescript-sdk): random build failures Due to the way pnpm runs scripts in parallel, some packages were not ready when others tried to access them, leading to random build failures. Fixes applied to eliminate race conditions: - Disable clean in tsup config files - Use the same clean method across all packages Also: - Add clean script to the root package.json for consistency - Disable minify when watch is enabled for performance Fixes #59 * chore(typescript-sdk): clean root level Clean the typescript SDK root level, which was previously missing, requiring manual clean up on some changes.
1 parent f56f59c commit 6faf52b

File tree

17 files changed

+27
-26
lines changed

17 files changed

+27
-26
lines changed

typescript-sdk/integrations/agno/package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -17,7 +17,7 @@
1717
"scripts": {
1818
"build": "tsup",
1919
"dev": "tsup --watch",
20-
"clean": "rm -rf dist",
20+
"clean": "rm -rf dist .turbo node_modules",
2121
"typecheck": "tsc --noEmit",
2222
"test": "jest",
2323
"link:global": "pnpm link --global",

typescript-sdk/integrations/langgraph/package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -16,7 +16,7 @@
1616
"scripts": {
1717
"build": "tsup",
1818
"dev": "tsup --watch",
19-
"clean": "rm -rf dist",
19+
"clean": "rm -rf dist .turbo node_modules",
2020
"typecheck": "tsc --noEmit",
2121
"test": "jest",
2222
"link:global": "pnpm link --global",

typescript-sdk/integrations/mastra/package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -17,7 +17,7 @@
1717
"scripts": {
1818
"build": "tsup",
1919
"dev": "tsup --watch",
20-
"clean": "rm -rf dist",
20+
"clean": "rm -rf dist .turbo node_modules",
2121
"typecheck": "tsc --noEmit",
2222
"test": "jest",
2323
"link:global": "pnpm link --global",

typescript-sdk/integrations/middleware-starter/package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -12,7 +12,7 @@
1212
"scripts": {
1313
"build": "tsup",
1414
"dev": "tsup --watch",
15-
"clean": "rm -rf dist",
15+
"clean": "rm -rf dist .turbo node_modules",
1616
"typecheck": "tsc --noEmit",
1717
"test": "jest",
1818
"link:global": "pnpm link --global",

typescript-sdk/integrations/server-starter-all-features/package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -12,7 +12,7 @@
1212
"scripts": {
1313
"build": "tsup",
1414
"dev": "tsup --watch",
15-
"clean": "rm -rf dist",
15+
"clean": "rm -rf dist .turbo node_modules",
1616
"typecheck": "tsc --noEmit",
1717
"test": "jest",
1818
"link:global": "pnpm link --global",

typescript-sdk/integrations/server-starter/package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -12,7 +12,7 @@
1212
"scripts": {
1313
"build": "tsup",
1414
"dev": "tsup --watch",
15-
"clean": "rm -rf dist",
15+
"clean": "rm -rf dist .turbo node_modules",
1616
"typecheck": "tsc --noEmit",
1717
"test": "jest",
1818
"link:global": "pnpm link --global",

typescript-sdk/integrations/vercel-ai-sdk/package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -12,7 +12,7 @@
1212
"scripts": {
1313
"build": "tsup",
1414
"dev": "tsup --watch",
15-
"clean": "rm -rf dist",
15+
"clean": "rm -rf dist .turbo node_modules",
1616
"typecheck": "tsc --noEmit",
1717
"test": "jest",
1818
"link:global": "pnpm link --global",

typescript-sdk/package.json

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,8 @@
44
"private": true,
55
"scripts": {
66
"build": "turbo run build",
7-
"build:clean": "pnpm -r clean && pnpm install && turbo run build",
7+
"clean": "rm -rf dist .turbo node_modules && pnpm -r clean",
8+
"build:clean": "rm -rf dist .turbo node_modules && pnpm -r clean && pnpm install && turbo run build",
89
"dev": "turbo run dev",
910
"lint": "turbo run lint",
1011
"format": "prettier --write \"**/*.{ts,tsx,md,mdx}\"",

typescript-sdk/packages/cli/package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -18,7 +18,7 @@
1818
"scripts": {
1919
"build": "tsup",
2020
"dev": "tsup --watch",
21-
"clean": "rm -rf dist",
21+
"clean": "rm -rf dist .turbo node_modules",
2222
"typecheck": "tsc --noEmit",
2323
"test": "jest",
2424
"link:global": "pnpm link --global",

typescript-sdk/packages/client/package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -17,7 +17,7 @@
1717
"scripts": {
1818
"build": "tsup",
1919
"dev": "tsup --watch",
20-
"clean": "rm -rf dist",
20+
"clean": "rm -rf dist .turbo node_modules",
2121
"typecheck": "tsc --noEmit",
2222
"test": "jest",
2323
"link:global": "pnpm link --global",

0 commit comments

Comments
 (0)