Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fix: fix peerDependencies flag #2956

Open
wants to merge 1 commit into
base: production
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 2 additions & 4 deletions lerna.json
Original file line number Diff line number Diff line change
Expand Up @@ -14,9 +14,7 @@
"version": "8.4.0",
"command": {
"bootstrap": {
"npmClientArgs": [
"--no-package-lock"
]
"npmClientArgs": ["--no-package-lock"]
}
}
}
}
2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
Expand Up @@ -113,7 +113,7 @@
"@swc-node/register": "1.10.9",
"@swc/core": "1.7.28",
"@swc/helpers": "0.5.13",
"@tsed/monorepo-utils": "2.3.9",
"@tsed/monorepo-utils": "2.3.11",
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

💡 Codebase verification

Version inconsistency detected in monorepo-utils dependency

The update to version 2.3.11 in root package.json creates inconsistency with other packages still using 2.3.9:

  • packages/core/package.json: version 2.3.9
  • packages/hooks/package.json: version 2.3.9

Consider synchronizing the version across all package.json files to avoid potential build issues.

🔗 Analysis chain

Verify the monorepo-utils version update.

The update from 2.3.9 to 2.3.11 seems minor, but let's verify the changes.

🏁 Scripts executed

The following scripts were executed for the analysis:

Script:

#!/bin/bash
# Check for the changelog or release notes
if [ -d "tools/monorepo-utils" ]; then
  echo "Checking local monorepo-utils changelog..."
  rg -A 5 "## \[2.3.(10|11)\]" "tools/monorepo-utils/CHANGELOG.md"
else
  echo "Checking GitHub releases..."
  gh api repos/tsedio/tsed/releases | jq -r '.[] | select(.tag_name | contains("monorepo-utils@2.3.1")) | .body'
fi

Length of output: 211


Script:

#!/bin/bash
# Check correct repository and usage patterns
echo "Checking correct repository..."
gh api repos/tsed/monorepo-utils/releases | jq -r '.[] | select(.tag_name | contains("2.3.1")) | .body'

echo -e "\nChecking usage patterns..."
rg -l "@tsed/monorepo-utils" --type js --type ts --type json

Length of output: 549


Script:

#!/bin/bash
echo "Checking usage in build tools..."
cat tools/vitest/index.js tools/typescript/index.js

echo -e "\nChecking package versions in other package.json files..."
for f in packages/*/package.json; do
  echo "=== $f ==="
  grep "@tsed/monorepo-utils" "$f" || true
done

Length of output: 8993

"@tsed/ts-doc": "5.0.0",
"@types/axios": "0.14.0",
"@types/globby": "9.1.0",
Expand Down
2 changes: 1 addition & 1 deletion packages/core/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@
"browser": "./lib/browser/core.umd.min.js",
"exports": {
".": {
"@tsed/source": "./src/index.ts",
"tsed-source": "./src/index.ts",
"types": "./lib/types/index.d.ts",
"browser": "./lib/browser/core.umd.min.js",
"import": "./lib/esm/index.js",
Expand Down
8 changes: 4 additions & 4 deletions packages/di/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@
"browser": "./lib/browser/di.umd.min.js",
"exports": {
".": {
"@tsed/source": "./src/index.ts",
"tsed-source": "./src/index.ts",
"types": "./lib/types/index.d.ts",
"browser": "./lib/browser/di.umd.min.js",
"import": "./lib/esm/index.js",
Expand Down Expand Up @@ -43,10 +43,10 @@
"webpack": "^5.75.0"
},
"peerDependencies": {
"@tsed/core": "8.4.0",
"@tsed/hooks": "8.4.0",
"@tsed/core": ">=8.0.0",
"@tsed/hooks": ">=8.0.0",
"@tsed/logger": ">=7.0.1",
"@tsed/schema": "8.4.0"
"@tsed/schema": ">=8.0.0"
},
"peerDependenciesMeta": {
"@tsed/core": {
Expand Down
2 changes: 1 addition & 1 deletion packages/engines/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@
"typings": "./lib/types/index.d.ts",
"exports": {
".": {
"@tsed/source": "./src/index.ts",
"tsed-source": "./src/index.ts",
"types": "./lib/types/index.d.ts",
"import": "./lib/esm/index.js",
"default": "./lib/esm/index.js"
Expand Down
8 changes: 4 additions & 4 deletions packages/graphql/apollo/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@
"typings": "./lib/types/index.d.ts",
"exports": {
".": {
"@tsed/source": "./src/index.ts",
"tsed-source": "./src/index.ts",
"types": "./lib/types/index.d.ts",
"import": "./lib/esm/index.js",
"default": "./lib/esm/index.js"
Expand Down Expand Up @@ -44,10 +44,10 @@
},
"peerDependencies": {
"@apollo/server": ">=4.10.4",
"@tsed/core": "8.4.0",
"@tsed/di": "8.4.0",
"@tsed/core": ">=8.0.0",
"@tsed/di": ">=8.0.0",
"@tsed/logger": ">=7.0.1",
"@tsed/platform-http": "8.4.0",
"@tsed/platform-http": ">=8.0.0",
"graphql": ">16.0.0"
}
}
8 changes: 4 additions & 4 deletions packages/graphql/graphql-ws/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@
"typings": "./lib/types/index.d.ts",
"exports": {
".": {
"@tsed/source": "./src/index.ts",
"tsed-source": "./src/index.ts",
"types": "./lib/types/index.d.ts",
"import": "./lib/esm/index.js",
"default": "./lib/esm/index.js"
Expand All @@ -35,10 +35,10 @@
"typescript": "5.4.5"
},
"peerDependencies": {
"@tsed/core": "8.4.0",
"@tsed/di": "8.4.0",
"@tsed/core": ">=8.0.0",
"@tsed/di": ">=8.0.0",
"@tsed/logger": ">=7.0.1",
"@tsed/platform-http": "8.4.0",
"@tsed/platform-http": ">=8.0.0",
"graphql-ws": ">=5.14.2"
}
}
2 changes: 1 addition & 1 deletion packages/graphql/typegraphql/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@
"typings": "./lib/types/index.d.ts",
"exports": {
".": {
"@tsed/source": "./src/index.ts",
"tsed-source": "./src/index.ts",
"types": "./lib/types/index.d.ts",
"import": "./lib/esm/index.js",
"default": "./lib/esm/index.js"
Expand Down
2 changes: 1 addition & 1 deletion packages/hooks/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@
"browser": "./lib/browser/core.umd.min.js",
"exports": {
".": {
"@tsed/source": "./src/index.ts",
"tsed-source": "./src/index.ts",
"types": "./lib/types/index.d.ts",
"browser": "./lib/browser/hooks.umd.min.js",
"import": "./lib/esm/index.js",
Expand Down
12 changes: 6 additions & 6 deletions packages/orm/adapters-redis/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@
"typings": "./lib/types/index.d.ts",
"exports": {
".": {
"@tsed/source": "./src/index.ts",
"tsed-source": "./src/index.ts",
"types": "./lib/types/index.d.ts",
"import": "./lib/esm/index.js",
"default": "./lib/esm/index.js"
Expand Down Expand Up @@ -37,11 +37,11 @@
"vitest": "2.1.2"
},
"peerDependencies": {
"@tsed/adapters": "8.4.0",
"@tsed/core": "8.4.0",
"@tsed/di": "8.4.0",
"@tsed/hooks": "8.4.0",
"@tsed/platform-http": "8.4.0",
"@tsed/adapters": ">=8.0.0",
"@tsed/core": ">=8.0.0",
"@tsed/di": ">=8.0.0",
"@tsed/hooks": ">=8.0.0",
"@tsed/platform-http": ">=8.0.0",
Comment on lines +40 to +44
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

🧹 Nitpick (assertive)

Consider using a more specific version range

While changing from fixed versions to ranges improves flexibility, using >=8.0.0 might be too permissive. Consider using a more specific range like ^8.0.0 to prevent potential compatibility issues with future major versions.

-    "@tsed/adapters": ">=8.0.0",
-    "@tsed/core": ">=8.0.0",
-    "@tsed/di": ">=8.0.0",
-    "@tsed/hooks": ">=8.0.0",
-    "@tsed/platform-http": ">=8.0.0",
+    "@tsed/adapters": "^8.0.0",
+    "@tsed/core": "^8.0.0",
+    "@tsed/di": "^8.0.0",
+    "@tsed/hooks": "^8.0.0",
+    "@tsed/platform-http": "^8.0.0",
📝 Committable suggestion

‼️ IMPORTANT
Carefully review the code before committing. Ensure that it accurately replaces the highlighted code, contains no missing lines, and has no issues with indentation. Thoroughly test & benchmark the code to ensure it meets the requirements.

Suggested change
"@tsed/adapters": ">=8.0.0",
"@tsed/core": ">=8.0.0",
"@tsed/di": ">=8.0.0",
"@tsed/hooks": ">=8.0.0",
"@tsed/platform-http": ">=8.0.0",
"@tsed/adapters": "^8.0.0",
"@tsed/core": "^8.0.0",
"@tsed/di": "^8.0.0",
"@tsed/hooks": "^8.0.0",
"@tsed/platform-http": "^8.0.0",

"ioredis": ">=5.2.3",
"ioredis-mock": ">=8.2.2",
"uuid": "^10.0.0"
Expand Down
14 changes: 7 additions & 7 deletions packages/orm/adapters/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@
"typings": "./lib/types/index.d.ts",
"exports": {
".": {
"@tsed/source": "./src/index.ts",
"tsed-source": "./src/index.ts",
"types": "./lib/types/index.d.ts",
"import": "./lib/esm/index.js",
"default": "./lib/esm/index.js"
Expand Down Expand Up @@ -47,12 +47,12 @@
"vitest": "2.1.2"
},
"peerDependencies": {
"@tsed/ajv": "8.4.0",
"@tsed/core": "8.4.0",
"@tsed/di": "8.4.0",
"@tsed/json-mapper": "8.4.0",
"@tsed/platform-http": "8.4.0",
"@tsed/schema": "8.4.0"
"@tsed/ajv": ">=8.0.0",
"@tsed/core": ">=8.0.0",
"@tsed/di": ">=8.0.0",
"@tsed/json-mapper": ">=8.0.0",
"@tsed/platform-http": ">=8.0.0",
"@tsed/schema": ">=8.0.0"
},
"peerDependenciesMeta": {
"@tsed/ajv": {
Expand Down
6 changes: 3 additions & 3 deletions packages/orm/ioredis/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@
"typings": "./lib/types/index.d.ts",
"exports": {
".": {
"@tsed/source": "./src/index.ts",
"tsed-source": "./src/index.ts",
"types": "./lib/types/index.d.ts",
"import": "./lib/esm/index.js",
"default": "./lib/esm/index.js"
Expand Down Expand Up @@ -38,8 +38,8 @@
"vitest": "2.1.2"
},
"peerDependencies": {
"@tsed/core": "8.4.0",
"@tsed/di": "8.4.0",
"@tsed/core": ">=8.0.0",
"@tsed/di": ">=8.0.0",
"ioredis": ">=5.2.3",
"ioredis-mock": ">=8.2.2"
}
Expand Down
8 changes: 4 additions & 4 deletions packages/orm/mikro-orm/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@
"typings": "./lib/types/index.d.ts",
"exports": {
".": {
"@tsed/source": "./src/index.ts",
"tsed-source": "./src/index.ts",
"types": "./lib/types/index.d.ts",
"import": "./lib/esm/index.js",
"default": "./lib/esm/index.js"
Expand Down Expand Up @@ -45,9 +45,9 @@
},
"peerDependencies": {
"@mikro-orm/core": ">=4.5.9",
"@tsed/core": "8.4.0",
"@tsed/di": "8.4.0",
"@tsed/core": ">=8.0.0",
"@tsed/di": ">=8.0.0",
"@tsed/logger": ">=7.0.1",
"@tsed/platform-http": "8.4.0"
"@tsed/platform-http": ">=8.0.0"
}
}
12 changes: 6 additions & 6 deletions packages/orm/mongoose/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@
"typings": "./lib/types/index.d.ts",
"exports": {
".": {
"@tsed/source": "./src/index.ts",
"tsed-source": "./src/index.ts",
"types": "./lib/types/index.d.ts",
"import": "./lib/esm/index.js",
"default": "./lib/esm/index.js"
Expand Down Expand Up @@ -49,12 +49,12 @@
"vitest": "2.1.2"
},
"peerDependencies": {
"@tsed/ajv": "8.4.0",
"@tsed/core": "8.4.0",
"@tsed/di": "8.4.0",
"@tsed/json-mapper": "8.4.0",
"@tsed/ajv": ">=8.0.0",
"@tsed/core": ">=8.0.0",
"@tsed/di": ">=8.0.0",
"@tsed/json-mapper": ">=8.0.0",
"@tsed/logger": ">=7.0.1",
"@tsed/schema": "8.4.0",
"@tsed/schema": ">=8.0.0",
"mongoose": ">=6.0.0"
}
}
12 changes: 6 additions & 6 deletions packages/orm/objection/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@
"typings": "./lib/types/index.d.ts",
"exports": {
".": {
"@tsed/source": "./src/index.ts",
"tsed-source": "./src/index.ts",
"types": "./lib/types/index.d.ts",
"import": "./lib/esm/index.js",
"default": "./lib/esm/index.js"
Expand Down Expand Up @@ -41,11 +41,11 @@
"vitest": "2.1.2"
},
"peerDependencies": {
"@tsed/ajv": "8.4.0",
"@tsed/core": "8.4.0",
"@tsed/di": "8.4.0",
"@tsed/json-mapper": "8.4.0",
"@tsed/schema": "8.4.0",
"@tsed/ajv": ">=8.0.0",
"@tsed/core": ">=8.0.0",
"@tsed/di": ">=8.0.0",
"@tsed/json-mapper": ">=8.0.0",
"@tsed/schema": ">=8.0.0",
"knex": ">=0.94.0",
"objection": ">=2.0.0"
},
Expand Down
10 changes: 5 additions & 5 deletions packages/orm/prisma/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@
"typings": "./lib/types/index.d.ts",
"exports": {
".": {
"@tsed/source": "./src/index.ts",
"tsed-source": "./src/index.ts",
"types": "./lib/types/index.d.ts",
"import": "./lib/esm/index.js",
"default": "./lib/esm/index.js"
Expand Down Expand Up @@ -57,10 +57,10 @@
},
"peerDependencies": {
"@prisma/client": ">=6.0.0",
"@tsed/core": "8.4.0",
"@tsed/di": "8.4.0",
"@tsed/json-mapper": "8.4.0",
"@tsed/schema": "8.4.0"
"@tsed/core": ">=8.0.0",
"@tsed/di": ">=8.0.0",
"@tsed/json-mapper": ">=8.0.0",
"@tsed/schema": ">=8.0.0"
},
"keywords": [
"TypeScript",
Expand Down
8 changes: 4 additions & 4 deletions packages/orm/testcontainers-mongo/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@
"typings": "./lib/types/index.d.ts",
"exports": {
".": {
"@tsed/source": "./src/index.ts",
"tsed-source": "./src/index.ts",
"types": "./lib/types/index.d.ts",
"import": "./lib/esm/index.js",
"default": "./lib/esm/index.js"
Expand Down Expand Up @@ -42,9 +42,9 @@
},
"peerDependencies": {
"@testcontainers/mongodb": ">=10.11.0",
"@tsed/core": "8.4.0",
"@tsed/di": "8.4.0",
"@tsed/platform-http": "8.4.0",
"@tsed/core": ">=8.0.0",
"@tsed/di": ">=8.0.0",
"@tsed/platform-http": ">=8.0.0",
"mongodb": ">=6",
"testcontainers": ">=10.11.0"
}
Expand Down
2 changes: 1 addition & 1 deletion packages/perf/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@
"typings": "./lib/types/index.d.ts",
"exports": {
".": {
"@tsed/source": "./src/index.ts",
"tsed-source": "./src/index.ts",
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

💡 Codebase verification

Update build script to use new export key

The change from "@tsed/source" to "tsed-source" is safe, but the build script at tools/typescript/index.js needs to be updated to use the new export key for consistency.

  • tools/typescript/index.js: Update line containing "@tsed/source" to use "tsed-source" instead
🔗 Analysis chain

Verify the impact of exports field change.

The change from "@tsed/source" to "tsed-source" is part of a systematic update across all packages. While the change appears intentional, we should verify there are no existing tools or workflows depending on the old export key.

Run this script to check for any existing usage of the old export key:

🏁 Scripts executed

The following scripts were executed for the analysis:

Script:

#!/bin/bash
# Search for any references to the old export key in the codebase
rg -l "@tsed/source" --type ts --type js

Length of output: 66


Script:

#!/bin/bash
# Check the content and context of the reference
cat tools/typescript/index.js

Length of output: 6551

"types": "./lib/types/index.d.ts",
"import": "./lib/esm/index.js",
"default": "./lib/esm/index.js"
Expand Down
2 changes: 1 addition & 1 deletion packages/platform/common/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@
"typings": "./lib/types/index.d.ts",
"exports": {
".": {
"@tsed/source": "./src/index.ts",
"tsed-source": "./src/index.ts",
"types": "./lib/types/index.d.ts",
"import": "./lib/esm/index.js",
"default": "./lib/esm/index.js"
Expand Down
10 changes: 5 additions & 5 deletions packages/platform/platform-cache/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@
"typings": "./lib/types/index.d.ts",
"exports": {
".": {
"@tsed/source": "./src/index.ts",
"tsed-source": "./src/index.ts",
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

🧹 Nitpick (assertive)

Changes maintain monorepo consistency

The modifications align with the standardization effort across the monorepo.

Consider documenting these widespread changes in the migration guide, specifically:

  1. The export key change from "@tsed/source" to "tsed-source"
  2. The relaxed peer dependencies version requirements

Also applies to: 43-46

"types": "./lib/types/index.d.ts",
"import": "./lib/esm/index.js",
"default": "./lib/esm/index.js"
Expand Down Expand Up @@ -40,10 +40,10 @@
"vitest": "2.1.2"
},
"peerDependencies": {
"@tsed/core": "8.4.0",
"@tsed/di": "8.4.0",
"@tsed/json-mapper": "8.4.0",
"@tsed/schema": "8.4.0"
"@tsed/core": ">=8.0.0",
"@tsed/di": ">=8.0.0",
"@tsed/json-mapper": ">=8.0.0",
"@tsed/schema": ">=8.0.0"
},
"peerDependenciesMeta": {
"@tsed/core": {
Expand Down
10 changes: 5 additions & 5 deletions packages/platform/platform-exceptions/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@
"typings": "./lib/types/index.d.ts",
"exports": {
".": {
"@tsed/source": "./src/index.ts",
"tsed-source": "./src/index.ts",
"types": "./lib/types/index.d.ts",
"import": "./lib/esm/index.js",
"default": "./lib/esm/index.js"
Expand Down Expand Up @@ -37,10 +37,10 @@
"vitest": "2.1.2"
},
"peerDependencies": {
"@tsed/core": "8.4.0",
"@tsed/di": "8.4.0",
"@tsed/exceptions": "8.4.0",
"@tsed/schema": "8.4.0"
"@tsed/core": ">=8.0.0",
"@tsed/di": ">=8.0.0",
"@tsed/exceptions": ">=8.0.0",
"@tsed/schema": ">=8.0.0"
},
"peerDependenciesMeta": {
"@tsed/core": {
Expand Down
Loading
Loading