From 04db2a6255dad5d3e2d92da4607eb2324f473288 Mon Sep 17 00:00:00 2001 From: Jake Bailey <5341706+jakebailey@users.noreply.github.com> Date: Wed, 6 Mar 2024 19:14:52 -0800 Subject: [PATCH 1/4] Update for TS 5.4 --- package.json | 2 +- packages/definitions-parser/package.json | 2 +- packages/dts-critic/package.json | 2 +- packages/dts-gen/package.json | 2 +- packages/dtslint/package.json | 2 +- packages/eslint-plugin/package.json | 2 +- packages/publisher/package.json | 2 +- .../publisher/test/generate-packages.test.ts | 2 +- packages/typescript-packages/package.json | 4 +- packages/typescript-versions/src/index.ts | 14 +- .../typescript-versions/test/index.test.ts | 28 +-- pnpm-lock.yaml | 170 +++++++++--------- 12 files changed, 123 insertions(+), 109 deletions(-) diff --git a/package.json b/package.json index c4dece08b4..50b734bf25 100644 --- a/package.json +++ b/package.json @@ -27,7 +27,7 @@ "knip": "^4.0.2", "prettier": "^3.2.2", "ts-jest": "^29.1.1", - "typescript": "^5.3.3" + "typescript": "^5.4.2" }, "pnpm": { "overrides": { diff --git a/packages/definitions-parser/package.json b/packages/definitions-parser/package.json index 44bc65dc4e..02dbc62da3 100644 --- a/packages/definitions-parser/package.json +++ b/packages/definitions-parser/package.json @@ -29,7 +29,7 @@ }, "devDependencies": { "@types/pacote": "^11.1.8", - "typescript": "^5.3.3" + "typescript": "^5.4.2" }, "peerDependencies": { "typescript": "*" diff --git a/packages/dts-critic/package.json b/packages/dts-critic/package.json index 32431bfa51..d1ac616a48 100644 --- a/packages/dts-critic/package.json +++ b/packages/dts-critic/package.json @@ -8,7 +8,7 @@ }, "dependencies": { "@definitelytyped/header-parser": "workspace:*", - "typescript": "^5.3.3", + "typescript": "^5.4.2", "yargs": "^17.7.2" }, "peerDependencies": { diff --git a/packages/dts-gen/package.json b/packages/dts-gen/package.json index 34fa3bb231..c4cd2399d9 100644 --- a/packages/dts-gen/package.json +++ b/packages/dts-gen/package.json @@ -26,7 +26,7 @@ "dependencies": { "dts-dom": "^3.7.0", "parse-git-config": "^3.0.0", - "typescript": "^5.3.3", + "typescript": "^5.4.2", "yargs": "^17.7.2" }, "devDependencies": { diff --git a/packages/dtslint/package.json b/packages/dtslint/package.json index 2bc3417687..dc60d2f3a3 100644 --- a/packages/dtslint/package.json +++ b/packages/dtslint/package.json @@ -45,7 +45,7 @@ "@types/eslint": "^8.56.2", "@types/semver": "^7.5.5", "@types/strip-json-comments": "^3.0.0", - "typescript": "^5.3.3" + "typescript": "^5.4.2" }, "engines": { "node": ">=18.18.0" diff --git a/packages/eslint-plugin/package.json b/packages/eslint-plugin/package.json index 5e6167e9ee..17683085e3 100644 --- a/packages/eslint-plugin/package.json +++ b/packages/eslint-plugin/package.json @@ -39,7 +39,7 @@ "glob": "^10.3.10", "jest-file-snapshot": "^0.5.0", "strip-ansi": "^6.0.1", - "typescript": "^5.3.3" + "typescript": "^5.4.2" }, "engines": { "node": ">=18.18.0" diff --git a/packages/publisher/package.json b/packages/publisher/package.json index 635344e27c..ad257f3036 100644 --- a/packages/publisher/package.json +++ b/packages/publisher/package.json @@ -13,7 +13,7 @@ "longjohn": "^0.2.12", "pacote": "^17.0.5", "semver": "^7.5.4", - "typescript": "^5.3.3", + "typescript": "^5.4.2", "yargs": "^17.7.2" }, "devDependencies": { diff --git a/packages/publisher/test/generate-packages.test.ts b/packages/publisher/test/generate-packages.test.ts index e0d7d7efd1..7e37336342 100644 --- a/packages/publisher/test/generate-packages.test.ts +++ b/packages/publisher/test/generate-packages.test.ts @@ -156,7 +156,7 @@ testo({ "@types/madeira": "^1" }, "typesPublisherContentHash": "05febc04df55db2687c2ac05a291177c2f4fd90f76d679faaf1b01896fe5600c", - "typeScriptVersion": "4.6" + "typeScriptVersion": "4.7" }`); }, basicNotNeededPackageJson() { diff --git a/packages/typescript-packages/package.json b/packages/typescript-packages/package.json index 66cf4adfc5..3f0dccec34 100644 --- a/packages/typescript-packages/package.json +++ b/packages/typescript-packages/package.json @@ -22,7 +22,6 @@ }, "dependencies": { "@definitelytyped/typescript-versions": "workspace:*", - "typescript-4.6": "npm:typescript@~4.6.0-0", "typescript-4.7": "npm:typescript@~4.7.0-0", "typescript-4.8": "npm:typescript@~4.8.0-0", "typescript-4.9": "npm:typescript@~4.9.0-0", @@ -30,6 +29,7 @@ "typescript-5.1": "npm:typescript@~5.1.0-0", "typescript-5.2": "npm:typescript@~5.2.0-0", "typescript-5.3": "npm:typescript@~5.3.0-0", - "typescript-5.4": "npm:typescript@~5.4.0-0" + "typescript-5.4": "npm:typescript@~5.4.0-0", + "typescript-5.5": "npm:typescript@~5.5.0-0" } } diff --git a/packages/typescript-versions/src/index.ts b/packages/typescript-versions/src/index.ts index e9b48430e3..8e127e16f0 100644 --- a/packages/typescript-versions/src/index.ts +++ b/packages/typescript-versions/src/index.ts @@ -6,7 +6,7 @@ import assert from "assert"; For the RC: - 1. Add a new version to the end of `TypeScriptVersion` and `supported`. + 1. Add a new version to the end of `supported`. `supported` now contains the shipped versions, the RC, and the nightly. 2. Add the new version to `packages/typescript-packages/package.json`. 3. Update failing tests. @@ -20,10 +20,9 @@ import assert from "assert"; # How to deprecate an old version on Definitely Typed # - 1. Move the old version from `TypeScriptVersion` to `UnsupportedTypeScriptVersion`. - 2. Move the old version from `shipped` to `unsupported`. - 3. Remove the old version from `packages/typescript-packages/package.json`. - 4. Update failing tests. + 1. Move the old version from `shipped` to `unsupported`. + 2. Remove the old version from `packages/typescript-packages/package.json`. + 3. Update failing tests. Currently, it's possible to release a new version and deprecate an old version at the same time because of the way release schedule overlaps. @@ -42,9 +41,9 @@ export type AllTypeScriptVersion = UnsupportedTypeScriptVersion | TypeScriptVers export namespace TypeScriptVersion { /** Add to this list when a version actually ships. */ - export const shipped = ["4.6", "4.7", "4.8", "4.9", "5.0", "5.1", "5.2", "5.3"] as const; + export const shipped = ["4.7", "4.8", "4.9", "5.0", "5.1", "5.2", "5.3", "5.4"] as const; /** Add to this list when a version is available as typescript@next */ - export const supported = [...shipped, "5.4"] as const; + export const supported = [...shipped, "5.5"] as const; /** Add to this list when it will no longer be supported on Definitely Typed */ export const unsupported = [ "2.0", @@ -73,6 +72,7 @@ export namespace TypeScriptVersion { "4.3", "4.4", "4.5", + "4.6", ] as const; export const all: readonly AllTypeScriptVersion[] = [...unsupported, ...supported]; export const lowest = supported[0]; diff --git a/packages/typescript-versions/test/index.test.ts b/packages/typescript-versions/test/index.test.ts index 86c8571899..d873c4ffae 100644 --- a/packages/typescript-versions/test/index.test.ts +++ b/packages/typescript-versions/test/index.test.ts @@ -20,11 +20,11 @@ describe("isSupported", () => { it("works", () => { expect(TypeScriptVersion.isSupported("5.1")).toBeTruthy(); }); - it("supports 4.6", () => { - expect(TypeScriptVersion.isSupported("4.6")).toBeTruthy(); + it("supports 4.7", () => { + expect(TypeScriptVersion.isSupported("4.7")).toBeTruthy(); }); - it("does not support 4.5", () => { - expect(!TypeScriptVersion.isSupported("4.5")).toBeTruthy(); + it("does not support 4.6", () => { + expect(!TypeScriptVersion.isSupported("4.6")).toBeTruthy(); }); }); @@ -42,19 +42,27 @@ describe("isTypeScriptVersion", () => { describe("range", () => { it("works", () => { - expect(TypeScriptVersion.range("4.9")).toEqual(["4.9", "5.0", "5.1", "5.2", "5.3", "5.4"]); + expect(TypeScriptVersion.range("4.9")).toEqual(["4.9", "5.0", "5.1", "5.2", "5.3", "5.4", "5.5"]); }); - it("includes 4.6 onwards", () => { - expect(TypeScriptVersion.range("4.6")).toEqual(TypeScriptVersion.supported); + it("includes 4.7 onwards", () => { + expect(TypeScriptVersion.range("4.7")).toEqual(TypeScriptVersion.supported); }); }); describe("tagsToUpdate", () => { it("works", () => { - expect(TypeScriptVersion.tagsToUpdate("5.0")).toEqual(["ts5.0", "ts5.1", "ts5.2", "ts5.3", "ts5.4", "latest"]); + expect(TypeScriptVersion.tagsToUpdate("5.0")).toEqual([ + "ts5.0", + "ts5.1", + "ts5.2", + "ts5.3", + "ts5.4", + "ts5.5", + "latest", + ]); }); - it("allows 4.6 onwards", () => { - expect(TypeScriptVersion.tagsToUpdate("4.6")).toEqual( + it("allows 4.7 onwards", () => { + expect(TypeScriptVersion.tagsToUpdate("4.7")).toEqual( TypeScriptVersion.supported.map((s) => "ts" + s).concat("latest"), ); }); diff --git a/pnpm-lock.yaml b/pnpm-lock.yaml index 611f9cb6f1..982d541d50 100644 --- a/pnpm-lock.yaml +++ b/pnpm-lock.yaml @@ -32,10 +32,10 @@ importers: version: 17.0.32 '@typescript-eslint/eslint-plugin': specifier: ^6.19.0 - version: 6.19.0(@typescript-eslint/parser@6.19.0)(eslint@8.56.0)(typescript@5.3.3) + version: 6.19.0(@typescript-eslint/parser@6.19.0)(eslint@8.56.0)(typescript@5.4.2) '@typescript-eslint/parser': specifier: ^6.19.0 - version: 6.19.0(eslint@8.56.0)(typescript@5.3.3) + version: 6.19.0(eslint@8.56.0)(typescript@5.4.2) eslint: specifier: ^8.56.0 version: 8.56.0 @@ -50,16 +50,16 @@ importers: version: 29.7.0(@types/node@18.19.8) knip: specifier: ^4.0.2 - version: 4.0.4(@types/node@18.19.8)(typescript@5.3.3) + version: 4.0.4(@types/node@18.19.8)(typescript@5.4.2) prettier: specifier: ^3.2.2 version: 3.2.4 ts-jest: specifier: ^29.1.1 - version: 29.1.1(@babel/core@7.23.3)(jest@29.7.0)(typescript@5.3.3) + version: 29.1.1(@babel/core@7.23.3)(jest@29.7.0)(typescript@5.4.2) typescript: - specifier: ^5.3.3 - version: 5.3.3 + specifier: ^5.4.2 + version: 5.4.2 packages/definitions-parser: dependencies: @@ -89,8 +89,8 @@ importers: specifier: ^11.1.8 version: 11.1.8 typescript: - specifier: ^5.3.3 - version: 5.3.3 + specifier: ^5.4.2 + version: 5.4.2 packages/dts-critic: dependencies: @@ -98,8 +98,8 @@ importers: specifier: workspace:* version: link:../header-parser typescript: - specifier: ^5.3.3 - version: 5.3.3 + specifier: ^5.4.2 + version: 5.4.2 yargs: specifier: ^17.7.2 version: 17.7.2 @@ -113,8 +113,8 @@ importers: specifier: ^3.0.0 version: 3.0.0 typescript: - specifier: ^5.3.3 - version: 5.3.3 + specifier: ^5.4.2 + version: 5.4.2 yargs: specifier: ^17.7.2 version: 17.7.2 @@ -160,19 +160,19 @@ importers: version: link:../utils '@typescript-eslint/eslint-plugin': specifier: ^6.19.0 - version: 6.19.0(@typescript-eslint/parser@6.19.0)(eslint@8.56.0)(typescript@5.3.3) + version: 6.19.0(@typescript-eslint/parser@6.19.0)(eslint@8.56.0)(typescript@5.4.2) '@typescript-eslint/parser': specifier: ^6.19.0 - version: 6.19.0(eslint@8.56.0)(typescript@5.3.3) + version: 6.19.0(eslint@8.56.0)(typescript@5.4.2) '@typescript-eslint/types': specifier: ^6.19.0 version: 6.19.0 '@typescript-eslint/typescript-estree': specifier: ^6.19.0 - version: 6.19.0(typescript@5.3.3) + version: 6.19.0(typescript@5.4.2) '@typescript-eslint/utils': specifier: ^6.19.0 - version: 6.19.0(eslint@8.56.0)(typescript@5.3.3) + version: 6.19.0(eslint@8.56.0)(typescript@5.4.2) eslint: specifier: ^8.56.0 version: 8.56.0 @@ -196,8 +196,8 @@ importers: specifier: ^3.0.0 version: 3.0.0 typescript: - specifier: ^5.3.3 - version: 5.3.3 + specifier: ^5.4.2 + version: 5.4.2 packages/dtslint-runner: dependencies: @@ -228,16 +228,16 @@ importers: version: link:../utils '@typescript-eslint/eslint-plugin': specifier: ^6.11.0 - version: 6.11.0(@typescript-eslint/parser@6.11.0)(eslint@8.53.0)(typescript@5.3.3) + version: 6.11.0(@typescript-eslint/parser@6.11.0)(eslint@8.53.0)(typescript@5.4.2) '@typescript-eslint/parser': specifier: ^6.11.0 - version: 6.11.0(eslint@8.53.0)(typescript@5.3.3) + version: 6.11.0(eslint@8.53.0)(typescript@5.4.2) '@typescript-eslint/types': specifier: ^6.19.0 version: 6.19.0 '@typescript-eslint/utils': specifier: ^6.19.0 - version: 6.19.0(eslint@8.53.0)(typescript@5.3.3) + version: 6.19.0(eslint@8.53.0)(typescript@5.4.2) eslint: specifier: ^8.40.0 version: 8.53.0 @@ -261,8 +261,8 @@ importers: specifier: ^6.0.1 version: 6.0.1 typescript: - specifier: ^5.3.3 - version: 5.3.3 + specifier: ^5.4.2 + version: 5.4.2 packages/header-parser: dependencies: @@ -304,8 +304,8 @@ importers: specifier: ^7.5.4 version: 7.5.4 typescript: - specifier: ^5.3.3 - version: 5.3.3 + specifier: ^5.4.2 + version: 5.4.2 yargs: specifier: ^17.7.2 version: 17.7.2 @@ -359,9 +359,6 @@ importers: '@definitelytyped/typescript-versions': specifier: workspace:* version: link:../typescript-versions - typescript-4.6: - specifier: npm:typescript@~4.6.0-0 - version: /typescript@4.6.4 typescript-4.7: specifier: npm:typescript@~4.7.0-0 version: /typescript@4.7.4 @@ -386,6 +383,9 @@ importers: typescript-5.4: specifier: npm:typescript@~5.4.0-0 version: /typescript@5.4.0-dev.20231212 + typescript-5.5: + specifier: npm:typescript@~5.5.0-0 + version: /typescript@5.5.0-dev.20240306 packages/typescript-versions: {} @@ -2110,7 +2110,7 @@ packages: '@types/yargs-parser': 21.0.3 dev: true - /@typescript-eslint/eslint-plugin@6.11.0(@typescript-eslint/parser@6.11.0)(eslint@8.53.0)(typescript@5.3.3): + /@typescript-eslint/eslint-plugin@6.11.0(@typescript-eslint/parser@6.11.0)(eslint@8.53.0)(typescript@5.4.2): resolution: {integrity: sha512-uXnpZDc4VRjY4iuypDBKzW1rz9T5YBBK0snMn8MaTSNd2kMlj50LnLBABELjJiOL5YHk7ZD8hbSpI9ubzqYI0w==} engines: {node: ^16.0.0 || >=18.0.0} peerDependencies: @@ -2122,10 +2122,10 @@ packages: optional: true dependencies: '@eslint-community/regexpp': 4.10.0 - '@typescript-eslint/parser': 6.11.0(eslint@8.53.0)(typescript@5.3.3) + '@typescript-eslint/parser': 6.11.0(eslint@8.53.0)(typescript@5.4.2) '@typescript-eslint/scope-manager': 6.11.0 - '@typescript-eslint/type-utils': 6.11.0(eslint@8.53.0)(typescript@5.3.3) - '@typescript-eslint/utils': 6.11.0(eslint@8.53.0)(typescript@5.3.3) + '@typescript-eslint/type-utils': 6.11.0(eslint@8.53.0)(typescript@5.4.2) + '@typescript-eslint/utils': 6.11.0(eslint@8.53.0)(typescript@5.4.2) '@typescript-eslint/visitor-keys': 6.11.0 debug: 4.3.4 eslint: 8.53.0 @@ -2133,13 +2133,13 @@ packages: ignore: 5.2.4 natural-compare: 1.4.0 semver: 7.5.4 - ts-api-utils: 1.0.3(typescript@5.3.3) - typescript: 5.3.3 + ts-api-utils: 1.0.3(typescript@5.4.2) + typescript: 5.4.2 transitivePeerDependencies: - supports-color dev: false - /@typescript-eslint/eslint-plugin@6.19.0(@typescript-eslint/parser@6.19.0)(eslint@8.56.0)(typescript@5.3.3): + /@typescript-eslint/eslint-plugin@6.19.0(@typescript-eslint/parser@6.19.0)(eslint@8.56.0)(typescript@5.4.2): resolution: {integrity: sha512-DUCUkQNklCQYnrBSSikjVChdc84/vMPDQSgJTHBZ64G9bA9w0Crc0rd2diujKbTdp6w2J47qkeHQLoi0rpLCdg==} engines: {node: ^16.0.0 || >=18.0.0} peerDependencies: @@ -2151,10 +2151,10 @@ packages: optional: true dependencies: '@eslint-community/regexpp': 4.10.0 - '@typescript-eslint/parser': 6.19.0(eslint@8.56.0)(typescript@5.3.3) + '@typescript-eslint/parser': 6.19.0(eslint@8.56.0)(typescript@5.4.2) '@typescript-eslint/scope-manager': 6.19.0 - '@typescript-eslint/type-utils': 6.19.0(eslint@8.56.0)(typescript@5.3.3) - '@typescript-eslint/utils': 6.19.0(eslint@8.56.0)(typescript@5.3.3) + '@typescript-eslint/type-utils': 6.19.0(eslint@8.56.0)(typescript@5.4.2) + '@typescript-eslint/utils': 6.19.0(eslint@8.56.0)(typescript@5.4.2) '@typescript-eslint/visitor-keys': 6.19.0 debug: 4.3.4 eslint: 8.56.0 @@ -2162,12 +2162,12 @@ packages: ignore: 5.2.4 natural-compare: 1.4.0 semver: 7.5.4 - ts-api-utils: 1.0.3(typescript@5.3.3) - typescript: 5.3.3 + ts-api-utils: 1.0.3(typescript@5.4.2) + typescript: 5.4.2 transitivePeerDependencies: - supports-color - /@typescript-eslint/parser@6.11.0(eslint@8.53.0)(typescript@5.3.3): + /@typescript-eslint/parser@6.11.0(eslint@8.53.0)(typescript@5.4.2): resolution: {integrity: sha512-+whEdjk+d5do5nxfxx73oanLL9ghKO3EwM9kBCkUtWMRwWuPaFv9ScuqlYfQ6pAD6ZiJhky7TZ2ZYhrMsfMxVQ==} engines: {node: ^16.0.0 || >=18.0.0} peerDependencies: @@ -2179,16 +2179,16 @@ packages: dependencies: '@typescript-eslint/scope-manager': 6.11.0 '@typescript-eslint/types': 6.11.0 - '@typescript-eslint/typescript-estree': 6.11.0(typescript@5.3.3) + '@typescript-eslint/typescript-estree': 6.11.0(typescript@5.4.2) '@typescript-eslint/visitor-keys': 6.11.0 debug: 4.3.4 eslint: 8.53.0 - typescript: 5.3.3 + typescript: 5.4.2 transitivePeerDependencies: - supports-color dev: false - /@typescript-eslint/parser@6.19.0(eslint@8.56.0)(typescript@5.3.3): + /@typescript-eslint/parser@6.19.0(eslint@8.56.0)(typescript@5.4.2): resolution: {integrity: sha512-1DyBLG5SH7PYCd00QlroiW60YJ4rWMuUGa/JBV0iZuqi4l4IK3twKPq5ZkEebmGqRjXWVgsUzfd3+nZveewgow==} engines: {node: ^16.0.0 || >=18.0.0} peerDependencies: @@ -2200,11 +2200,11 @@ packages: dependencies: '@typescript-eslint/scope-manager': 6.19.0 '@typescript-eslint/types': 6.19.0 - '@typescript-eslint/typescript-estree': 6.19.0(typescript@5.3.3) + '@typescript-eslint/typescript-estree': 6.19.0(typescript@5.4.2) '@typescript-eslint/visitor-keys': 6.19.0 debug: 4.3.4 eslint: 8.56.0 - typescript: 5.3.3 + typescript: 5.4.2 transitivePeerDependencies: - supports-color @@ -2223,7 +2223,7 @@ packages: '@typescript-eslint/types': 6.19.0 '@typescript-eslint/visitor-keys': 6.19.0 - /@typescript-eslint/type-utils@6.11.0(eslint@8.53.0)(typescript@5.3.3): + /@typescript-eslint/type-utils@6.11.0(eslint@8.53.0)(typescript@5.4.2): resolution: {integrity: sha512-nA4IOXwZtqBjIoYrJcYxLRO+F9ri+leVGoJcMW1uqr4r1Hq7vW5cyWrA43lFbpRvQ9XgNrnfLpIkO3i1emDBIA==} engines: {node: ^16.0.0 || >=18.0.0} peerDependencies: @@ -2233,17 +2233,17 @@ packages: typescript: optional: true dependencies: - '@typescript-eslint/typescript-estree': 6.11.0(typescript@5.3.3) - '@typescript-eslint/utils': 6.11.0(eslint@8.53.0)(typescript@5.3.3) + '@typescript-eslint/typescript-estree': 6.11.0(typescript@5.4.2) + '@typescript-eslint/utils': 6.11.0(eslint@8.53.0)(typescript@5.4.2) debug: 4.3.4 eslint: 8.53.0 - ts-api-utils: 1.0.3(typescript@5.3.3) - typescript: 5.3.3 + ts-api-utils: 1.0.3(typescript@5.4.2) + typescript: 5.4.2 transitivePeerDependencies: - supports-color dev: false - /@typescript-eslint/type-utils@6.19.0(eslint@8.56.0)(typescript@5.3.3): + /@typescript-eslint/type-utils@6.19.0(eslint@8.56.0)(typescript@5.4.2): resolution: {integrity: sha512-mcvS6WSWbjiSxKCwBcXtOM5pRkPQ6kcDds/juxcy/727IQr3xMEcwr/YLHW2A2+Fp5ql6khjbKBzOyjuPqGi/w==} engines: {node: ^16.0.0 || >=18.0.0} peerDependencies: @@ -2253,12 +2253,12 @@ packages: typescript: optional: true dependencies: - '@typescript-eslint/typescript-estree': 6.19.0(typescript@5.3.3) - '@typescript-eslint/utils': 6.19.0(eslint@8.56.0)(typescript@5.3.3) + '@typescript-eslint/typescript-estree': 6.19.0(typescript@5.4.2) + '@typescript-eslint/utils': 6.19.0(eslint@8.56.0)(typescript@5.4.2) debug: 4.3.4 eslint: 8.56.0 - ts-api-utils: 1.0.3(typescript@5.3.3) - typescript: 5.3.3 + ts-api-utils: 1.0.3(typescript@5.4.2) + typescript: 5.4.2 transitivePeerDependencies: - supports-color @@ -2271,7 +2271,7 @@ packages: resolution: {integrity: sha512-lFviGV/vYhOy3m8BJ/nAKoAyNhInTdXpftonhWle66XHAtT1ouBlkjL496b5H5hb8dWXHwtypTqgtb/DEa+j5A==} engines: {node: ^16.0.0 || >=18.0.0} - /@typescript-eslint/typescript-estree@6.11.0(typescript@5.3.3): + /@typescript-eslint/typescript-estree@6.11.0(typescript@5.4.2): resolution: {integrity: sha512-Aezzv1o2tWJwvZhedzvD5Yv7+Lpu1by/U1LZ5gLc4tCx8jUmuSCMioPFRjliN/6SJIvY6HpTtJIWubKuYYYesQ==} engines: {node: ^16.0.0 || >=18.0.0} peerDependencies: @@ -2286,13 +2286,13 @@ packages: globby: 11.1.0 is-glob: 4.0.3 semver: 7.5.4 - ts-api-utils: 1.0.3(typescript@5.3.3) - typescript: 5.3.3 + ts-api-utils: 1.0.3(typescript@5.4.2) + typescript: 5.4.2 transitivePeerDependencies: - supports-color dev: false - /@typescript-eslint/typescript-estree@6.19.0(typescript@5.3.3): + /@typescript-eslint/typescript-estree@6.19.0(typescript@5.4.2): resolution: {integrity: sha512-o/zefXIbbLBZ8YJ51NlkSAt2BamrK6XOmuxSR3hynMIzzyMY33KuJ9vuMdFSXW+H0tVvdF9qBPTHA91HDb4BIQ==} engines: {node: ^16.0.0 || >=18.0.0} peerDependencies: @@ -2308,12 +2308,12 @@ packages: is-glob: 4.0.3 minimatch: 9.0.3 semver: 7.5.4 - ts-api-utils: 1.0.3(typescript@5.3.3) - typescript: 5.3.3 + ts-api-utils: 1.0.3(typescript@5.4.2) + typescript: 5.4.2 transitivePeerDependencies: - supports-color - /@typescript-eslint/utils@6.11.0(eslint@8.53.0)(typescript@5.3.3): + /@typescript-eslint/utils@6.11.0(eslint@8.53.0)(typescript@5.4.2): resolution: {integrity: sha512-p23ibf68fxoZy605dc0dQAEoUsoiNoP3MD9WQGiHLDuTSOuqoTsa4oAy+h3KDkTcxbbfOtUjb9h3Ta0gT4ug2g==} engines: {node: ^16.0.0 || >=18.0.0} peerDependencies: @@ -2324,7 +2324,7 @@ packages: '@types/semver': 7.5.6 '@typescript-eslint/scope-manager': 6.11.0 '@typescript-eslint/types': 6.11.0 - '@typescript-eslint/typescript-estree': 6.11.0(typescript@5.3.3) + '@typescript-eslint/typescript-estree': 6.11.0(typescript@5.4.2) eslint: 8.53.0 semver: 7.5.4 transitivePeerDependencies: @@ -2332,7 +2332,7 @@ packages: - typescript dev: false - /@typescript-eslint/utils@6.19.0(eslint@8.53.0)(typescript@5.3.3): + /@typescript-eslint/utils@6.19.0(eslint@8.53.0)(typescript@5.4.2): resolution: {integrity: sha512-QR41YXySiuN++/dC9UArYOg4X86OAYP83OWTewpVx5ct1IZhjjgTLocj7QNxGhWoTqknsgpl7L+hGygCO+sdYw==} engines: {node: ^16.0.0 || >=18.0.0} peerDependencies: @@ -2343,7 +2343,7 @@ packages: '@types/semver': 7.5.6 '@typescript-eslint/scope-manager': 6.19.0 '@typescript-eslint/types': 6.19.0 - '@typescript-eslint/typescript-estree': 6.19.0(typescript@5.3.3) + '@typescript-eslint/typescript-estree': 6.19.0(typescript@5.4.2) eslint: 8.53.0 semver: 7.5.4 transitivePeerDependencies: @@ -2351,7 +2351,7 @@ packages: - typescript dev: false - /@typescript-eslint/utils@6.19.0(eslint@8.56.0)(typescript@5.3.3): + /@typescript-eslint/utils@6.19.0(eslint@8.56.0)(typescript@5.4.2): resolution: {integrity: sha512-QR41YXySiuN++/dC9UArYOg4X86OAYP83OWTewpVx5ct1IZhjjgTLocj7QNxGhWoTqknsgpl7L+hGygCO+sdYw==} engines: {node: ^16.0.0 || >=18.0.0} peerDependencies: @@ -2362,7 +2362,7 @@ packages: '@types/semver': 7.5.6 '@typescript-eslint/scope-manager': 6.19.0 '@typescript-eslint/types': 6.19.0 - '@typescript-eslint/typescript-estree': 6.19.0(typescript@5.3.3) + '@typescript-eslint/typescript-estree': 6.19.0(typescript@5.4.2) eslint: 8.56.0 semver: 7.5.4 transitivePeerDependencies: @@ -3469,7 +3469,7 @@ packages: eslint-import-resolver-webpack: optional: true dependencies: - '@typescript-eslint/parser': 6.19.0(eslint@8.56.0)(typescript@5.3.3) + '@typescript-eslint/parser': 6.19.0(eslint@8.56.0)(typescript@5.4.2) debug: 3.2.7 eslint: 8.56.0 eslint-import-resolver-node: 0.3.9 @@ -3486,7 +3486,7 @@ packages: '@typescript-eslint/parser': optional: true dependencies: - '@typescript-eslint/parser': 6.19.0(eslint@8.56.0)(typescript@5.3.3) + '@typescript-eslint/parser': 6.19.0(eslint@8.56.0)(typescript@5.4.2) array-includes: 3.1.7 array.prototype.findlastindex: 1.2.3 array.prototype.flat: 1.3.2 @@ -5131,7 +5131,7 @@ packages: engines: {node: '>=6'} dev: true - /knip@4.0.4(@types/node@18.19.8)(typescript@5.3.3): + /knip@4.0.4(@types/node@18.19.8)(typescript@5.4.2): resolution: {integrity: sha512-b9TaKnktkIbeoYgEPocxjHS93GadCyMoYE+6SKrvO8cyGd4Btoey/x0BB8OtMQov8HjSNBgOHS6soJOdcxvHDQ==} engines: {node: '>=18.6.0'} hasBin: true @@ -5160,7 +5160,7 @@ packages: pretty-ms: 8.0.0 strip-json-comments: 5.0.1 summary: 2.1.0 - typescript: 5.3.3 + typescript: 5.4.2 zod: 3.22.4 zod-validation-error: 3.0.0(zod@3.22.4) transitivePeerDependencies: @@ -6896,19 +6896,19 @@ packages: escape-string-regexp: 1.0.5 dev: true - /ts-api-utils@1.0.3(typescript@5.3.3): + /ts-api-utils@1.0.3(typescript@5.4.2): resolution: {integrity: sha512-wNMeqtMz5NtwpT/UZGY5alT+VoKdSsOOP/kqHFcUW1P/VRhH2wJ48+DN2WwUliNbQ976ETwDL0Ifd2VVvgonvg==} engines: {node: '>=16.13.0'} peerDependencies: typescript: '>=4.2.0' dependencies: - typescript: 5.3.3 + typescript: 5.4.2 /ts-expose-internals-conditionally@1.0.0-empty.0: resolution: {integrity: sha512-F8m9NOF6ZhdOClDVdlM8gj3fDCav4ZIFSs/EI3ksQbAAXVSCN/Jh5OCJDDZWBuBy9psFc6jULGDlPwjMYMhJDw==} dev: false - /ts-jest@29.1.1(@babel/core@7.23.3)(jest@29.7.0)(typescript@5.3.3): + /ts-jest@29.1.1(@babel/core@7.23.3)(jest@29.7.0)(typescript@5.4.2): resolution: {integrity: sha512-D6xjnnbP17cC85nliwGiL+tpoKN0StpgE0TeOjXQTU6MVCfsB4v7aW05CgQ/1OywGb0x/oy9hHFnN+sczTiRaA==} engines: {node: ^14.15.0 || ^16.10.0 || >=18.0.0} hasBin: true @@ -6938,7 +6938,7 @@ packages: lodash.memoize: 4.1.2 make-error: 1.3.6 semver: 7.5.4 - typescript: 5.3.3 + typescript: 5.4.2 yargs-parser: 21.1.1 dev: true @@ -7063,12 +7063,6 @@ packages: resolution: {integrity: sha512-/aCDEGatGvZ2BIk+HmLf4ifCJFwvKFNb9/JeZPMulfgFracn9QFcAf5GO8B/mweUjSoblS5In0cWhqpfs/5PQA==} dev: false - /typescript@4.6.4: - resolution: {integrity: sha512-9ia/jWHIEbo49HfjrLGfKbZSuWo9iTMwXO+Ca3pRsSpbsMbc7/IU8NKdCZVRRBafVPGnoJeFL76ZOAA84I9fEg==} - engines: {node: '>=4.2.0'} - hasBin: true - dev: false - /typescript@4.7.4: resolution: {integrity: sha512-C0WQT0gezHuw6AdY1M2jxUO83Rjf0HP7Sk1DtXj6j1EwkQNZrHAg2XPWlq62oqEhYvONq5pkC2Y9oPljWToLmQ==} engines: {node: '>=4.2.0'} @@ -7109,6 +7103,7 @@ packages: resolution: {integrity: sha512-pXWcraxM0uxAS+tN0AG/BF2TyqmHO014Z070UsJ+pFvYuRSq8KH8DmWpnbXe0pEPDHXZV3FcAbJkijJ5oNEnWw==} engines: {node: '>=14.17'} hasBin: true + dev: false /typescript@5.4.0-dev.20231212: resolution: {integrity: sha512-h3fO+IfEsmtTuje/ZBrinHekd9rob7fO0QJFxedSXrd8vy/aJeyqjv4PNZpW2peM/jxNaexpp1wC6eTjfrtEwg==} @@ -7116,6 +7111,17 @@ packages: hasBin: true dev: false + /typescript@5.4.2: + resolution: {integrity: sha512-+2/g0Fds1ERlP6JsakQQDXjZdZMM+rqpamFZJEKh4kwTIn3iDkgKtby0CeNd5ATNZ4Ry1ax15TMx0W2V+miizQ==} + engines: {node: '>=14.17'} + hasBin: true + + /typescript@5.5.0-dev.20240306: + resolution: {integrity: sha512-8fi3+9qaHf/GQh7oo4X0HDxiWBwzRdGfgyXQlA/qUQ5NBBSbt3LCJFs2nlRBEd9pFBN5RD9Gfzyr0c3b+Ev9+A==} + engines: {node: '>=14.17'} + hasBin: true + dev: false + /unbox-primitive@1.0.2: resolution: {integrity: sha512-61pPlCD9h51VoreyJ0BReideM3MDKMKnh6+V9L08331ipq6Q8OFXZYiqP6n/tbHx4s5I9uRhcye6BrbkizkBDw==} dependencies: From 6126fbc07677a3332f5d7001fe001132ae21319a Mon Sep 17 00:00:00 2001 From: Jake Bailey <5341706+jakebailey@users.noreply.github.com> Date: Wed, 6 Mar 2024 19:15:19 -0800 Subject: [PATCH 2/4] changeset --- .changeset/neat-dogs-speak.md | 12 ++++++++++++ 1 file changed, 12 insertions(+) create mode 100644 .changeset/neat-dogs-speak.md diff --git a/.changeset/neat-dogs-speak.md b/.changeset/neat-dogs-speak.md new file mode 100644 index 0000000000..0d32c3ecb7 --- /dev/null +++ b/.changeset/neat-dogs-speak.md @@ -0,0 +1,12 @@ +--- +"@definitelytyped/typescript-packages": patch +"@definitelytyped/typescript-versions": patch +"@definitelytyped/definitions-parser": patch +"@definitelytyped/eslint-plugin": patch +"@definitelytyped/dts-critic": patch +"@definitelytyped/publisher": patch +"dts-gen": patch +"@definitelytyped/dtslint": patch +--- + +Update for TS 5.4 From 9ec0fea483deca2d37eb597b72e2767ecf68d334 Mon Sep 17 00:00:00 2001 From: Jake Bailey <5341706+jakebailey@users.noreply.github.com> Date: Wed, 6 Mar 2024 21:21:50 -0800 Subject: [PATCH 3/4] Fix lock --- packages/eslint-plugin/src/rules/expect.ts | 1 + pnpm-lock.yaml | 8 +------- 2 files changed, 2 insertions(+), 7 deletions(-) diff --git a/packages/eslint-plugin/src/rules/expect.ts b/packages/eslint-plugin/src/rules/expect.ts index 2964b4debc..dc3c15923d 100644 --- a/packages/eslint-plugin/src/rules/expect.ts +++ b/packages/eslint-plugin/src/rules/expect.ts @@ -102,6 +102,7 @@ Then re-run.`, for (const version of versionsToTest) { const ts = require(version.path) as TSModule; const program = getProgram(tsconfigPath, ts, version.versionName, parserServices.program); + console.log(version); walk( getLocFromIndex, reporter, diff --git a/pnpm-lock.yaml b/pnpm-lock.yaml index 982d541d50..8f2a6e60f1 100644 --- a/pnpm-lock.yaml +++ b/pnpm-lock.yaml @@ -382,7 +382,7 @@ importers: version: /typescript@5.3.3 typescript-5.4: specifier: npm:typescript@~5.4.0-0 - version: /typescript@5.4.0-dev.20231212 + version: /typescript@5.4.2 typescript-5.5: specifier: npm:typescript@~5.5.0-0 version: /typescript@5.5.0-dev.20240306 @@ -7105,12 +7105,6 @@ packages: hasBin: true dev: false - /typescript@5.4.0-dev.20231212: - resolution: {integrity: sha512-h3fO+IfEsmtTuje/ZBrinHekd9rob7fO0QJFxedSXrd8vy/aJeyqjv4PNZpW2peM/jxNaexpp1wC6eTjfrtEwg==} - engines: {node: '>=14.17'} - hasBin: true - dev: false - /typescript@5.4.2: resolution: {integrity: sha512-+2/g0Fds1ERlP6JsakQQDXjZdZMM+rqpamFZJEKh4kwTIn3iDkgKtby0CeNd5ATNZ4Ry1ax15TMx0W2V+miizQ==} engines: {node: '>=14.17'} From de5e84d112fa55b8c365006b5b2dafb7a8afa631 Mon Sep 17 00:00:00 2001 From: Jake Bailey <5341706+jakebailey@users.noreply.github.com> Date: Wed, 6 Mar 2024 21:22:10 -0800 Subject: [PATCH 4/4] Revert log --- packages/eslint-plugin/src/rules/expect.ts | 1 - 1 file changed, 1 deletion(-) diff --git a/packages/eslint-plugin/src/rules/expect.ts b/packages/eslint-plugin/src/rules/expect.ts index dc3c15923d..2964b4debc 100644 --- a/packages/eslint-plugin/src/rules/expect.ts +++ b/packages/eslint-plugin/src/rules/expect.ts @@ -102,7 +102,6 @@ Then re-run.`, for (const version of versionsToTest) { const ts = require(version.path) as TSModule; const program = getProgram(tsconfigPath, ts, version.versionName, parserServices.program); - console.log(version); walk( getLocFromIndex, reporter,