From 88b768967b8908607f5cd7dfcd3be4e2759dfe9b Mon Sep 17 00:00:00 2001 From: "renovate[bot]" <29139614+renovate[bot]@users.noreply.github.com> Date: Fri, 3 Jan 2025 17:14:52 +0000 Subject: [PATCH 1/3] chore(deps): update dependency @typescript-eslint/eslint-plugin to v8 --- package-lock.json | 437 +++++++++++++++++++++++++++++++++++++++------- package.json | 2 +- 2 files changed, 378 insertions(+), 61 deletions(-) diff --git a/package-lock.json b/package-lock.json index e3f41e2c1a..8dbf6f7b5e 100644 --- a/package-lock.json +++ b/package-lock.json @@ -14,7 +14,7 @@ "devDependencies": { "@commitlint/cli": "^17.1.2", "@commitlint/config-conventional": "^17.1.0", - "@typescript-eslint/eslint-plugin": "^5.39.0", + "@typescript-eslint/eslint-plugin": "^8.0.0", "ci-info": "^4.0.0", "eslint": "^8.24.0", "eslint-config-prettier": "^9.0.0", @@ -8936,105 +8936,339 @@ "license": "MIT" }, "node_modules/@typescript-eslint/eslint-plugin": { - "version": "5.62.0", + "version": "8.19.0", + "resolved": "https://registry.npmjs.org/@typescript-eslint/eslint-plugin/-/eslint-plugin-8.19.0.tgz", + "integrity": "sha512-NggSaEZCdSrFddbctrVjkVZvFC6KGfKfNK0CU7mNK/iKHGKbzT4Wmgm08dKpcZECBu9f5FypndoMyRHkdqfT1Q==", "dev": true, "license": "MIT", "dependencies": { - "@eslint-community/regexpp": "^4.4.0", - "@typescript-eslint/scope-manager": "5.62.0", - "@typescript-eslint/type-utils": "5.62.0", - "@typescript-eslint/utils": "5.62.0", - "debug": "^4.3.4", + "@eslint-community/regexpp": "^4.10.0", + "@typescript-eslint/scope-manager": "8.19.0", + "@typescript-eslint/type-utils": "8.19.0", + "@typescript-eslint/utils": "8.19.0", + "@typescript-eslint/visitor-keys": "8.19.0", "graphemer": "^1.4.0", - "ignore": "^5.2.0", - "natural-compare-lite": "^1.4.0", - "semver": "^7.3.7", - "tsutils": "^3.21.0" + "ignore": "^5.3.1", + "natural-compare": "^1.4.0", + "ts-api-utils": "^1.3.0" }, "engines": { - "node": "^12.22.0 || ^14.17.0 || >=16.0.0" + "node": "^18.18.0 || ^20.9.0 || >=21.1.0" }, "funding": { "type": "opencollective", "url": "https://opencollective.com/typescript-eslint" }, "peerDependencies": { - "@typescript-eslint/parser": "^5.0.0", - "eslint": "^6.0.0 || ^7.0.0 || ^8.0.0" + "@typescript-eslint/parser": "^8.0.0 || ^8.0.0-alpha.0", + "eslint": "^8.57.0 || ^9.0.0", + "typescript": ">=4.8.4 <5.8.0" + } + }, + "node_modules/@typescript-eslint/eslint-plugin/node_modules/@typescript-eslint/types": { + "version": "8.19.0", + "resolved": "https://registry.npmjs.org/@typescript-eslint/types/-/types-8.19.0.tgz", + "integrity": "sha512-8XQ4Ss7G9WX8oaYvD4OOLCjIQYgRQxO+qCiR2V2s2GxI9AUpo7riNwo6jDhKtTcaJjT8PY54j2Yb33kWtSJsmA==", + "dev": true, + "license": "MIT", + "engines": { + "node": "^18.18.0 || ^20.9.0 || >=21.1.0" }, - "peerDependenciesMeta": { - "typescript": { - "optional": true - } + "funding": { + "type": "opencollective", + "url": "https://opencollective.com/typescript-eslint" + } + }, + "node_modules/@typescript-eslint/eslint-plugin/node_modules/@typescript-eslint/visitor-keys": { + "version": "8.19.0", + "resolved": "https://registry.npmjs.org/@typescript-eslint/visitor-keys/-/visitor-keys-8.19.0.tgz", + "integrity": "sha512-mCFtBbFBJDCNCWUl5y6sZSCHXw1DEFEk3c/M3nRK2a4XUB8StGFtmcEMizdjKuBzB6e/smJAAWYug3VrdLMr1w==", + "dev": true, + "license": "MIT", + "dependencies": { + "@typescript-eslint/types": "8.19.0", + "eslint-visitor-keys": "^4.2.0" + }, + "engines": { + "node": "^18.18.0 || ^20.9.0 || >=21.1.0" + }, + "funding": { + "type": "opencollective", + "url": "https://opencollective.com/typescript-eslint" + } + }, + "node_modules/@typescript-eslint/eslint-plugin/node_modules/eslint-visitor-keys": { + "version": "4.2.0", + "resolved": "https://registry.npmjs.org/eslint-visitor-keys/-/eslint-visitor-keys-4.2.0.tgz", + "integrity": "sha512-UyLnSehNt62FFhSwjZlHmeokpRK59rcz29j+F1/aDgbkbRTk7wIc9XzdoasMUbRNKDM0qQt/+BJ4BrpFeABemw==", + "dev": true, + "license": "Apache-2.0", + "engines": { + "node": "^18.18.0 || ^20.9.0 || >=21.1.0" + }, + "funding": { + "url": "https://opencollective.com/eslint" } }, "node_modules/@typescript-eslint/parser": { - "version": "5.62.0", + "version": "8.19.0", + "resolved": "https://registry.npmjs.org/@typescript-eslint/parser/-/parser-8.19.0.tgz", + "integrity": "sha512-6M8taKyOETY1TKHp0x8ndycipTVgmp4xtg5QpEZzXxDhNvvHOJi5rLRkLr8SK3jTgD5l4fTlvBiRdfsuWydxBw==", "dev": true, - "license": "BSD-2-Clause", + "license": "MIT", "peer": true, "dependencies": { - "@typescript-eslint/scope-manager": "5.62.0", - "@typescript-eslint/types": "5.62.0", - "@typescript-eslint/typescript-estree": "5.62.0", + "@typescript-eslint/scope-manager": "8.19.0", + "@typescript-eslint/types": "8.19.0", + "@typescript-eslint/typescript-estree": "8.19.0", + "@typescript-eslint/visitor-keys": "8.19.0", "debug": "^4.3.4" }, "engines": { - "node": "^12.22.0 || ^14.17.0 || >=16.0.0" + "node": "^18.18.0 || ^20.9.0 || >=21.1.0" }, "funding": { "type": "opencollective", "url": "https://opencollective.com/typescript-eslint" }, "peerDependencies": { - "eslint": "^6.0.0 || ^7.0.0 || ^8.0.0" + "eslint": "^8.57.0 || ^9.0.0", + "typescript": ">=4.8.4 <5.8.0" + } + }, + "node_modules/@typescript-eslint/parser/node_modules/@typescript-eslint/types": { + "version": "8.19.0", + "resolved": "https://registry.npmjs.org/@typescript-eslint/types/-/types-8.19.0.tgz", + "integrity": "sha512-8XQ4Ss7G9WX8oaYvD4OOLCjIQYgRQxO+qCiR2V2s2GxI9AUpo7riNwo6jDhKtTcaJjT8PY54j2Yb33kWtSJsmA==", + "dev": true, + "license": "MIT", + "peer": true, + "engines": { + "node": "^18.18.0 || ^20.9.0 || >=21.1.0" }, - "peerDependenciesMeta": { - "typescript": { - "optional": true - } + "funding": { + "type": "opencollective", + "url": "https://opencollective.com/typescript-eslint" + } + }, + "node_modules/@typescript-eslint/parser/node_modules/@typescript-eslint/typescript-estree": { + "version": "8.19.0", + "resolved": "https://registry.npmjs.org/@typescript-eslint/typescript-estree/-/typescript-estree-8.19.0.tgz", + "integrity": "sha512-WW9PpDaLIFW9LCbucMSdYUuGeFUz1OkWYS/5fwZwTA+l2RwlWFdJvReQqMUMBw4yJWJOfqd7An9uwut2Oj8sLw==", + "dev": true, + "license": "MIT", + "peer": true, + "dependencies": { + "@typescript-eslint/types": "8.19.0", + "@typescript-eslint/visitor-keys": "8.19.0", + "debug": "^4.3.4", + "fast-glob": "^3.3.2", + "is-glob": "^4.0.3", + "minimatch": "^9.0.4", + "semver": "^7.6.0", + "ts-api-utils": "^1.3.0" + }, + "engines": { + "node": "^18.18.0 || ^20.9.0 || >=21.1.0" + }, + "funding": { + "type": "opencollective", + "url": "https://opencollective.com/typescript-eslint" + }, + "peerDependencies": { + "typescript": ">=4.8.4 <5.8.0" + } + }, + "node_modules/@typescript-eslint/parser/node_modules/@typescript-eslint/visitor-keys": { + "version": "8.19.0", + "resolved": "https://registry.npmjs.org/@typescript-eslint/visitor-keys/-/visitor-keys-8.19.0.tgz", + "integrity": "sha512-mCFtBbFBJDCNCWUl5y6sZSCHXw1DEFEk3c/M3nRK2a4XUB8StGFtmcEMizdjKuBzB6e/smJAAWYug3VrdLMr1w==", + "dev": true, + "license": "MIT", + "peer": true, + "dependencies": { + "@typescript-eslint/types": "8.19.0", + "eslint-visitor-keys": "^4.2.0" + }, + "engines": { + "node": "^18.18.0 || ^20.9.0 || >=21.1.0" + }, + "funding": { + "type": "opencollective", + "url": "https://opencollective.com/typescript-eslint" + } + }, + "node_modules/@typescript-eslint/parser/node_modules/eslint-visitor-keys": { + "version": "4.2.0", + "resolved": "https://registry.npmjs.org/eslint-visitor-keys/-/eslint-visitor-keys-4.2.0.tgz", + "integrity": "sha512-UyLnSehNt62FFhSwjZlHmeokpRK59rcz29j+F1/aDgbkbRTk7wIc9XzdoasMUbRNKDM0qQt/+BJ4BrpFeABemw==", + "dev": true, + "license": "Apache-2.0", + "peer": true, + "engines": { + "node": "^18.18.0 || ^20.9.0 || >=21.1.0" + }, + "funding": { + "url": "https://opencollective.com/eslint" } }, "node_modules/@typescript-eslint/scope-manager": { - "version": "5.62.0", + "version": "8.19.0", + "resolved": "https://registry.npmjs.org/@typescript-eslint/scope-manager/-/scope-manager-8.19.0.tgz", + "integrity": "sha512-hkoJiKQS3GQ13TSMEiuNmSCvhz7ujyqD1x3ShbaETATHrck+9RaDdUbt+osXaUuns9OFwrDTTrjtwsU8gJyyRA==", "dev": true, "license": "MIT", "dependencies": { - "@typescript-eslint/types": "5.62.0", - "@typescript-eslint/visitor-keys": "5.62.0" + "@typescript-eslint/types": "8.19.0", + "@typescript-eslint/visitor-keys": "8.19.0" }, "engines": { - "node": "^12.22.0 || ^14.17.0 || >=16.0.0" + "node": "^18.18.0 || ^20.9.0 || >=21.1.0" + }, + "funding": { + "type": "opencollective", + "url": "https://opencollective.com/typescript-eslint" + } + }, + "node_modules/@typescript-eslint/scope-manager/node_modules/@typescript-eslint/types": { + "version": "8.19.0", + "resolved": "https://registry.npmjs.org/@typescript-eslint/types/-/types-8.19.0.tgz", + "integrity": "sha512-8XQ4Ss7G9WX8oaYvD4OOLCjIQYgRQxO+qCiR2V2s2GxI9AUpo7riNwo6jDhKtTcaJjT8PY54j2Yb33kWtSJsmA==", + "dev": true, + "license": "MIT", + "engines": { + "node": "^18.18.0 || ^20.9.0 || >=21.1.0" }, "funding": { "type": "opencollective", "url": "https://opencollective.com/typescript-eslint" } }, + "node_modules/@typescript-eslint/scope-manager/node_modules/@typescript-eslint/visitor-keys": { + "version": "8.19.0", + "resolved": "https://registry.npmjs.org/@typescript-eslint/visitor-keys/-/visitor-keys-8.19.0.tgz", + "integrity": "sha512-mCFtBbFBJDCNCWUl5y6sZSCHXw1DEFEk3c/M3nRK2a4XUB8StGFtmcEMizdjKuBzB6e/smJAAWYug3VrdLMr1w==", + "dev": true, + "license": "MIT", + "dependencies": { + "@typescript-eslint/types": "8.19.0", + "eslint-visitor-keys": "^4.2.0" + }, + "engines": { + "node": "^18.18.0 || ^20.9.0 || >=21.1.0" + }, + "funding": { + "type": "opencollective", + "url": "https://opencollective.com/typescript-eslint" + } + }, + "node_modules/@typescript-eslint/scope-manager/node_modules/eslint-visitor-keys": { + "version": "4.2.0", + "resolved": "https://registry.npmjs.org/eslint-visitor-keys/-/eslint-visitor-keys-4.2.0.tgz", + "integrity": "sha512-UyLnSehNt62FFhSwjZlHmeokpRK59rcz29j+F1/aDgbkbRTk7wIc9XzdoasMUbRNKDM0qQt/+BJ4BrpFeABemw==", + "dev": true, + "license": "Apache-2.0", + "engines": { + "node": "^18.18.0 || ^20.9.0 || >=21.1.0" + }, + "funding": { + "url": "https://opencollective.com/eslint" + } + }, "node_modules/@typescript-eslint/type-utils": { - "version": "5.62.0", + "version": "8.19.0", + "resolved": "https://registry.npmjs.org/@typescript-eslint/type-utils/-/type-utils-8.19.0.tgz", + "integrity": "sha512-TZs0I0OSbd5Aza4qAMpp1cdCYVnER94IziudE3JU328YUHgWu9gwiwhag+fuLeJ2LkWLXI+F/182TbG+JaBdTg==", "dev": true, "license": "MIT", "dependencies": { - "@typescript-eslint/typescript-estree": "5.62.0", - "@typescript-eslint/utils": "5.62.0", + "@typescript-eslint/typescript-estree": "8.19.0", + "@typescript-eslint/utils": "8.19.0", "debug": "^4.3.4", - "tsutils": "^3.21.0" + "ts-api-utils": "^1.3.0" }, "engines": { - "node": "^12.22.0 || ^14.17.0 || >=16.0.0" + "node": "^18.18.0 || ^20.9.0 || >=21.1.0" }, "funding": { "type": "opencollective", "url": "https://opencollective.com/typescript-eslint" }, "peerDependencies": { - "eslint": "*" + "eslint": "^8.57.0 || ^9.0.0", + "typescript": ">=4.8.4 <5.8.0" + } + }, + "node_modules/@typescript-eslint/type-utils/node_modules/@typescript-eslint/types": { + "version": "8.19.0", + "resolved": "https://registry.npmjs.org/@typescript-eslint/types/-/types-8.19.0.tgz", + "integrity": "sha512-8XQ4Ss7G9WX8oaYvD4OOLCjIQYgRQxO+qCiR2V2s2GxI9AUpo7riNwo6jDhKtTcaJjT8PY54j2Yb33kWtSJsmA==", + "dev": true, + "license": "MIT", + "engines": { + "node": "^18.18.0 || ^20.9.0 || >=21.1.0" }, - "peerDependenciesMeta": { - "typescript": { - "optional": true - } + "funding": { + "type": "opencollective", + "url": "https://opencollective.com/typescript-eslint" + } + }, + "node_modules/@typescript-eslint/type-utils/node_modules/@typescript-eslint/typescript-estree": { + "version": "8.19.0", + "resolved": "https://registry.npmjs.org/@typescript-eslint/typescript-estree/-/typescript-estree-8.19.0.tgz", + "integrity": "sha512-WW9PpDaLIFW9LCbucMSdYUuGeFUz1OkWYS/5fwZwTA+l2RwlWFdJvReQqMUMBw4yJWJOfqd7An9uwut2Oj8sLw==", + "dev": true, + "license": "MIT", + "dependencies": { + "@typescript-eslint/types": "8.19.0", + "@typescript-eslint/visitor-keys": "8.19.0", + "debug": "^4.3.4", + "fast-glob": "^3.3.2", + "is-glob": "^4.0.3", + "minimatch": "^9.0.4", + "semver": "^7.6.0", + "ts-api-utils": "^1.3.0" + }, + "engines": { + "node": "^18.18.0 || ^20.9.0 || >=21.1.0" + }, + "funding": { + "type": "opencollective", + "url": "https://opencollective.com/typescript-eslint" + }, + "peerDependencies": { + "typescript": ">=4.8.4 <5.8.0" + } + }, + "node_modules/@typescript-eslint/type-utils/node_modules/@typescript-eslint/visitor-keys": { + "version": "8.19.0", + "resolved": "https://registry.npmjs.org/@typescript-eslint/visitor-keys/-/visitor-keys-8.19.0.tgz", + "integrity": "sha512-mCFtBbFBJDCNCWUl5y6sZSCHXw1DEFEk3c/M3nRK2a4XUB8StGFtmcEMizdjKuBzB6e/smJAAWYug3VrdLMr1w==", + "dev": true, + "license": "MIT", + "dependencies": { + "@typescript-eslint/types": "8.19.0", + "eslint-visitor-keys": "^4.2.0" + }, + "engines": { + "node": "^18.18.0 || ^20.9.0 || >=21.1.0" + }, + "funding": { + "type": "opencollective", + "url": "https://opencollective.com/typescript-eslint" + } + }, + "node_modules/@typescript-eslint/type-utils/node_modules/eslint-visitor-keys": { + "version": "4.2.0", + "resolved": "https://registry.npmjs.org/eslint-visitor-keys/-/eslint-visitor-keys-4.2.0.tgz", + "integrity": "sha512-UyLnSehNt62FFhSwjZlHmeokpRK59rcz29j+F1/aDgbkbRTk7wIc9XzdoasMUbRNKDM0qQt/+BJ4BrpFeABemw==", + "dev": true, + "license": "Apache-2.0", + "engines": { + "node": "^18.18.0 || ^20.9.0 || >=21.1.0" + }, + "funding": { + "url": "https://opencollective.com/eslint" } }, "node_modules/@typescript-eslint/types": { @@ -9092,28 +9326,99 @@ } }, "node_modules/@typescript-eslint/utils": { - "version": "5.62.0", + "version": "8.19.0", + "resolved": "https://registry.npmjs.org/@typescript-eslint/utils/-/utils-8.19.0.tgz", + "integrity": "sha512-PTBG+0oEMPH9jCZlfg07LCB2nYI0I317yyvXGfxnvGvw4SHIOuRnQ3kadyyXY6tGdChusIHIbM5zfIbp4M6tCg==", "dev": true, "license": "MIT", "dependencies": { - "@eslint-community/eslint-utils": "^4.2.0", - "@types/json-schema": "^7.0.9", - "@types/semver": "^7.3.12", - "@typescript-eslint/scope-manager": "5.62.0", - "@typescript-eslint/types": "5.62.0", - "@typescript-eslint/typescript-estree": "5.62.0", - "eslint-scope": "^5.1.1", - "semver": "^7.3.7" + "@eslint-community/eslint-utils": "^4.4.0", + "@typescript-eslint/scope-manager": "8.19.0", + "@typescript-eslint/types": "8.19.0", + "@typescript-eslint/typescript-estree": "8.19.0" }, "engines": { - "node": "^12.22.0 || ^14.17.0 || >=16.0.0" + "node": "^18.18.0 || ^20.9.0 || >=21.1.0" + }, + "funding": { + "type": "opencollective", + "url": "https://opencollective.com/typescript-eslint" + }, + "peerDependencies": { + "eslint": "^8.57.0 || ^9.0.0", + "typescript": ">=4.8.4 <5.8.0" + } + }, + "node_modules/@typescript-eslint/utils/node_modules/@typescript-eslint/types": { + "version": "8.19.0", + "resolved": "https://registry.npmjs.org/@typescript-eslint/types/-/types-8.19.0.tgz", + "integrity": "sha512-8XQ4Ss7G9WX8oaYvD4OOLCjIQYgRQxO+qCiR2V2s2GxI9AUpo7riNwo6jDhKtTcaJjT8PY54j2Yb33kWtSJsmA==", + "dev": true, + "license": "MIT", + "engines": { + "node": "^18.18.0 || ^20.9.0 || >=21.1.0" + }, + "funding": { + "type": "opencollective", + "url": "https://opencollective.com/typescript-eslint" + } + }, + "node_modules/@typescript-eslint/utils/node_modules/@typescript-eslint/typescript-estree": { + "version": "8.19.0", + "resolved": "https://registry.npmjs.org/@typescript-eslint/typescript-estree/-/typescript-estree-8.19.0.tgz", + "integrity": "sha512-WW9PpDaLIFW9LCbucMSdYUuGeFUz1OkWYS/5fwZwTA+l2RwlWFdJvReQqMUMBw4yJWJOfqd7An9uwut2Oj8sLw==", + "dev": true, + "license": "MIT", + "dependencies": { + "@typescript-eslint/types": "8.19.0", + "@typescript-eslint/visitor-keys": "8.19.0", + "debug": "^4.3.4", + "fast-glob": "^3.3.2", + "is-glob": "^4.0.3", + "minimatch": "^9.0.4", + "semver": "^7.6.0", + "ts-api-utils": "^1.3.0" + }, + "engines": { + "node": "^18.18.0 || ^20.9.0 || >=21.1.0" }, "funding": { "type": "opencollective", "url": "https://opencollective.com/typescript-eslint" }, "peerDependencies": { - "eslint": "^6.0.0 || ^7.0.0 || ^8.0.0" + "typescript": ">=4.8.4 <5.8.0" + } + }, + "node_modules/@typescript-eslint/utils/node_modules/@typescript-eslint/visitor-keys": { + "version": "8.19.0", + "resolved": "https://registry.npmjs.org/@typescript-eslint/visitor-keys/-/visitor-keys-8.19.0.tgz", + "integrity": "sha512-mCFtBbFBJDCNCWUl5y6sZSCHXw1DEFEk3c/M3nRK2a4XUB8StGFtmcEMizdjKuBzB6e/smJAAWYug3VrdLMr1w==", + "dev": true, + "license": "MIT", + "dependencies": { + "@typescript-eslint/types": "8.19.0", + "eslint-visitor-keys": "^4.2.0" + }, + "engines": { + "node": "^18.18.0 || ^20.9.0 || >=21.1.0" + }, + "funding": { + "type": "opencollective", + "url": "https://opencollective.com/typescript-eslint" + } + }, + "node_modules/@typescript-eslint/utils/node_modules/eslint-visitor-keys": { + "version": "4.2.0", + "resolved": "https://registry.npmjs.org/eslint-visitor-keys/-/eslint-visitor-keys-4.2.0.tgz", + "integrity": "sha512-UyLnSehNt62FFhSwjZlHmeokpRK59rcz29j+F1/aDgbkbRTk7wIc9XzdoasMUbRNKDM0qQt/+BJ4BrpFeABemw==", + "dev": true, + "license": "Apache-2.0", + "engines": { + "node": "^18.18.0 || ^20.9.0 || >=21.1.0" + }, + "funding": { + "url": "https://opencollective.com/eslint" } }, "node_modules/@typescript-eslint/visitor-keys": { @@ -15045,6 +15350,7 @@ "version": "5.1.1", "dev": true, "license": "BSD-2-Clause", + "peer": true, "dependencies": { "esrecurse": "^4.3.0", "estraverse": "^4.1.1" @@ -15413,6 +15719,7 @@ "version": "4.3.0", "dev": true, "license": "BSD-2-Clause", + "peer": true, "engines": { "node": ">=4.0" } @@ -17167,7 +17474,9 @@ "license": "BSD-3-Clause" }, "node_modules/ignore": { - "version": "5.3.0", + "version": "5.3.2", + "resolved": "https://registry.npmjs.org/ignore/-/ignore-5.3.2.tgz", + "integrity": "sha512-hsBTNUqQTDwkWtcdYI2i06Y/nUBEsNEDJKjWdigLvegy8kDuJAS8uRlpkkcQpyEXL0Z/pjDy5HBmMjRCJ2gq+g==", "license": "MIT", "engines": { "node": ">= 4" @@ -20421,11 +20730,6 @@ "dev": true, "license": "MIT" }, - "node_modules/natural-compare-lite": { - "version": "1.4.0", - "dev": true, - "license": "MIT" - }, "node_modules/negotiator": { "version": "0.6.3", "dev": true, @@ -25001,6 +25305,19 @@ "node": ">= 14.0.0" } }, + "node_modules/ts-api-utils": { + "version": "1.4.3", + "resolved": "https://registry.npmjs.org/ts-api-utils/-/ts-api-utils-1.4.3.tgz", + "integrity": "sha512-i3eMG77UTMD0hZhgRS562pv83RC6ukSAC2GMNWc+9dieh/+jDM5u5YG+NHX6VNDRHQcHwmsTHctP9LhbC3WxVw==", + "dev": true, + "license": "MIT", + "engines": { + "node": ">=16" + }, + "peerDependencies": { + "typescript": ">=4.2.0" + } + }, "node_modules/ts-node": { "version": "10.9.2", "license": "MIT", diff --git a/package.json b/package.json index 2fa8fa2cd6..cf6986c28e 100644 --- a/package.json +++ b/package.json @@ -49,7 +49,7 @@ "devDependencies": { "@commitlint/cli": "^17.1.2", "@commitlint/config-conventional": "^17.1.0", - "@typescript-eslint/eslint-plugin": "^5.39.0", + "@typescript-eslint/eslint-plugin": "^8.0.0", "ci-info": "^4.0.0", "eslint": "^8.24.0", "eslint-config-prettier": "^9.0.0", From aafd7ec2fa667a5cfdf3171d3db2779c0cc51e11 Mon Sep 17 00:00:00 2001 From: jake champion Date: Fri, 3 Jan 2025 17:25:22 +0000 Subject: [PATCH 2/3] chore: fix all the issues found from updating @typescript-eslint/eslint-plugin to v8 --- .../build-info/src/frameworks/nuxt.test.ts | 1 - packages/build-info/src/metrics.test.ts | 12 +-- .../src/node/get-build-info.test.ts | 6 +- packages/build-info/src/runtime/runtime.ts | 5 -- .../src/workspaces/get-workspace-packages.ts | 2 +- packages/build/src/error/types.ts | 73 +++++++++---------- packages/build/src/plugins/options.ts | 2 +- .../src/plugins_core/pre_dev_cleanup/index.ts | 2 +- packages/build/src/utils/resolve.js | 2 +- packages/config/src/api/site_info.ts | 2 +- .../tests/main.test.ts | 2 +- .../opentelemetry-utils/tests/main.test.ts | 4 +- .../zip-it-and-ship-it/tests/main.test.ts | 5 +- 13 files changed, 55 insertions(+), 63 deletions(-) diff --git a/packages/build-info/src/frameworks/nuxt.test.ts b/packages/build-info/src/frameworks/nuxt.test.ts index a2215f482d..85a123c487 100644 --- a/packages/build-info/src/frameworks/nuxt.test.ts +++ b/packages/build-info/src/frameworks/nuxt.test.ts @@ -51,7 +51,6 @@ describe('Nuxt V3', () => { NODE_VERSION: '18', }) - // eslint-disable-next-line @typescript-eslint/no-non-null-assertion const settings = await getSettings(detected![0], project, cwd) expect(settings.clearPublishDirectory).toBeTruthy() }) diff --git a/packages/build-info/src/metrics.test.ts b/packages/build-info/src/metrics.test.ts index 351e2a6621..b185e7340b 100644 --- a/packages/build-info/src/metrics.test.ts +++ b/packages/build-info/src/metrics.test.ts @@ -10,7 +10,7 @@ describe('metrics', () => { test('returns an error when passed a string', async () => { const errorSpy = vi.spyOn(console, 'error') report('error happened', { client: mockClient }) - expect(errorSpy).toHaveBeenCalledOnce + expect(errorSpy).toHaveBeenCalledOnce() expect(errorSpy.mock.calls[0][0]).toBeInstanceOf(Error) expect(errorSpy.mock.calls[0][0].message).toBe('error happened') }) @@ -18,7 +18,7 @@ describe('metrics', () => { test('returns an error when passed an error', async () => { const errorSpy = vi.spyOn(console, 'error') report(new Error('error happened'), { client: mockClient }) - expect(errorSpy).toHaveBeenCalledOnce + expect(errorSpy).toHaveBeenCalledOnce() expect(errorSpy.mock.calls[0][0]).toBeInstanceOf(Error) expect(errorSpy.mock.calls[0][0].message).toBe('error happened') }) @@ -26,7 +26,7 @@ describe('metrics', () => { test('returns an object when passed an object in an expected format (1)', async () => { const errorSpy = vi.spyOn(console, 'error') report({ name: 'Error', message: 'error happened' }, { client: mockClient }) - expect(errorSpy).toHaveBeenCalledOnce + expect(errorSpy).toHaveBeenCalledOnce() expect(errorSpy.mock.calls[0][0]).not.toBeInstanceOf(Error) expect(errorSpy.mock.calls[0][0].name).toBe('Error') expect(errorSpy.mock.calls[0][0].message).toBe('error happened') @@ -35,7 +35,7 @@ describe('metrics', () => { test('returns an object when passed an object in an expected format (2)', async () => { const errorSpy = vi.spyOn(console, 'error') report({ errorClass: 'Error', errorMessage: 'error happened' }, { client: mockClient }) - expect(errorSpy).toHaveBeenCalledOnce + expect(errorSpy).toHaveBeenCalledOnce() expect(errorSpy.mock.calls[0][0]).not.toBeInstanceOf(Error) expect(errorSpy.mock.calls[0][0].errorClass).toBe('Error') expect(errorSpy.mock.calls[0][0].errorMessage).toBe('error happened') @@ -44,7 +44,7 @@ describe('metrics', () => { test('returns an error when passed an object in an unexpected format but includes a message', async () => { const errorSpy = vi.spyOn(console, 'error') report({ message: 'error happened', documentation_url: 'bar' }, { client: mockClient }) - expect(errorSpy).toHaveBeenCalledOnce + expect(errorSpy).toHaveBeenCalledOnce() expect(errorSpy.mock.calls[0][0]).toBeInstanceOf(Error) expect(errorSpy.mock.calls[0][0].message).toBe('error happened') }) @@ -52,7 +52,7 @@ describe('metrics', () => { test('returns an error when passed an object in an unexpected format', async () => { const errorSpy = vi.spyOn(console, 'error') report({ foo: 'bar' }, { client: mockClient }) - expect(errorSpy).toHaveBeenCalledOnce + expect(errorSpy).toHaveBeenCalledOnce() expect(errorSpy.mock.calls[0][0]).toBeInstanceOf(Error) expect(errorSpy.mock.calls[0][0].message).toBe('Unexpected error format: {"foo":"bar"}') }) diff --git a/packages/build-info/src/node/get-build-info.test.ts b/packages/build-info/src/node/get-build-info.test.ts index 7a2ba7b167..65a962747b 100644 --- a/packages/build-info/src/node/get-build-info.test.ts +++ b/packages/build-info/src/node/get-build-info.test.ts @@ -66,7 +66,7 @@ test('should not crash on invalid projects', async (ctx) => { test.skipIf(platform() === 'win32')('should retrieve the build info for providing a rootDir', async (ctx) => { const fixture = await createFixture('pnpm-workspace', ctx) const info = await getBuildInfo({ rootDir: fixture.cwd }) - // eslint-disable-next-line @typescript-eslint/no-non-null-assertion + info.jsWorkspaces!.rootDir = '/cleaned-for-snapshot' expect(info).toMatchSnapshot() }) @@ -76,7 +76,7 @@ test.skipIf(platform() === 'win32')( async (ctx) => { const fixture = await createFixture('pnpm-workspace', ctx) const info = await getBuildInfo({ rootDir: fixture.cwd, projectDir: fixture.cwd }) - // eslint-disable-next-line @typescript-eslint/no-non-null-assertion + info.jsWorkspaces!.rootDir = '/cleaned-for-snapshot' expect(info).toMatchSnapshot() }, @@ -87,7 +87,7 @@ test.skipIf(platform() === 'win32')( async (ctx) => { const fixture = await createFixture('pnpm-workspace', ctx) const info = await getBuildInfo({ rootDir: fixture.cwd, projectDir: join(fixture.cwd, 'packages/blog') }) - // eslint-disable-next-line @typescript-eslint/no-non-null-assertion + info.jsWorkspaces!.rootDir = '/cleaned-for-snapshot' expect(info).toMatchSnapshot() }, diff --git a/packages/build-info/src/runtime/runtime.ts b/packages/build-info/src/runtime/runtime.ts index b6156b3268..98397fdd04 100644 --- a/packages/build-info/src/runtime/runtime.ts +++ b/packages/build-info/src/runtime/runtime.ts @@ -1,10 +1,5 @@ import { Project } from '../project.js' -export interface LangRuntime { - id: string - name: string -} - export abstract class LangRuntime { id: string name: string diff --git a/packages/build-info/src/workspaces/get-workspace-packages.ts b/packages/build-info/src/workspaces/get-workspace-packages.ts index eac0d43f9b..b35c11a66f 100644 --- a/packages/build-info/src/workspaces/get-workspace-packages.ts +++ b/packages/build-info/src/workspaces/get-workspace-packages.ts @@ -70,7 +70,7 @@ export async function findPackages( : project.fs.resolve(dir) try { content = await project.fs.readDir(startDir, true) - } catch (err) { + } catch { // noop } diff --git a/packages/build/src/error/types.ts b/packages/build/src/error/types.ts index fe61f987c3..110ec47536 100644 --- a/packages/build/src/error/types.ts +++ b/packages/build/src/error/types.ts @@ -26,46 +26,44 @@ export type BasicErrorInfo = { /** * Error severity groups the errors emitted by build and used to translate to exit code via SEVERITY_MAP */ -enum ErrorSeverity { +type ErrorSeverity = /** * build success */ - success = 'success', + | 'success' /** * not an error, e.g. build cancellation */ - none = 'none', + | 'none' /** * user error */ - info = 'info', + | 'info' /** * community plugin error */ - warning = 'warning', + | 'warning' /** * system error, including core plugin error */ - error = 'Error', -} + | 'error' /** * How the stack trace should appear in the build error logs */ -enum StackType { +type StackType = /** * not printed */ - none = 'none', + | 'none' /* * printed as is */ - stack = 'stack', + | 'stack' /** * printed as is, but taken from `error.message`. Used when `error.stack` is not being correct due to the error being passed between different processes. */ - message = 'message', -} + | 'message' type GroupFunction = ({ location }: { location: ErrorLocation }) => string export type TitleFunction = ({ location }: { location: ErrorLocation }) => string @@ -274,42 +272,41 @@ export interface ErrorType { /** * error severity (also used by Bugsnag) */ - severity: keyof typeof ErrorSeverity + severity: ErrorSeverity /** * how the stack trace should appear in build error logs */ - stackType: keyof typeof StackType + stackType: StackType } -const ErrorTypeMap = { +type ErrorTypeMap = /** * Plugin called `utils.build.cancelBuild()` */ - cancelBuild: 'cancelBuild', - resolveConfig: 'resolveConfig', - dependencies: 'dependencies', - pluginInput: 'pluginInput', - pluginUnsupportedVersion: 'pluginUnsupportedVersion', - buildCommand: 'buildCommand', - functionsBundling: 'functionsBundling', - secretScanningFoundSecrets: 'secretScanningFoundSecrets', - failPlugin: 'failPlugin', - failBuild: 'failBuild', - pluginValidation: 'pluginValidation', - pluginInternal: 'pluginInternal', - ipc: 'ipc', - corePlugin: 'corePlugin', - trustedPlugin: 'trustedPlugin', - coreStep: 'coreStep', - api: 'api', - deploy: 'deploy', - deployInternal: 'deployInternal', - exception: 'exception', - telemetry: 'telemetry', -} as const + | 'cancelBuild' + | 'resolveConfig' + | 'dependencies' + | 'pluginInput' + | 'pluginUnsupportedVersion' + | 'buildCommand' + | 'functionsBundling' + | 'secretScanningFoundSecrets' + | 'failPlugin' + | 'failBuild' + | 'pluginValidation' + | 'pluginInternal' + | 'ipc' + | 'corePlugin' + | 'trustedPlugin' + | 'coreStep' + | 'api' + | 'deploy' + | 'deployInternal' + | 'exception' + | 'telemetry' /* Error classes for build executions */ -export type ErrorTypes = keyof typeof ErrorTypeMap +export type ErrorTypes = ErrorTypeMap /** * List of error types, and their related properties diff --git a/packages/build/src/plugins/options.ts b/packages/build/src/plugins/options.ts index e9347f7bba..88239ca85b 100644 --- a/packages/build/src/plugins/options.ts +++ b/packages/build/src/plugins/options.ts @@ -113,7 +113,7 @@ export const getSpawnInfo = (): { } } => { // we know that this package.json has a name as it's ours - // eslint-disable-next-line @typescript-eslint/no-non-null-assertion + const packageName = ROOT_PACKAGE_JSON.name! return { plugin: { packageName, pluginPackageJson: ROOT_PACKAGE_JSON }, diff --git a/packages/build/src/plugins_core/pre_dev_cleanup/index.ts b/packages/build/src/plugins_core/pre_dev_cleanup/index.ts index 95c50eefa1..e2fa763841 100644 --- a/packages/build/src/plugins_core/pre_dev_cleanup/index.ts +++ b/packages/build/src/plugins_core/pre_dev_cleanup/index.ts @@ -9,7 +9,7 @@ const dirExists = async (path: string): Promise => { try { await stat(path) return true - } catch (error) { + } catch { return false } } diff --git a/packages/build/src/utils/resolve.js b/packages/build/src/utils/resolve.js index e27134cdae..f5269f3ade 100644 --- a/packages/build/src/utils/resolve.js +++ b/packages/build/src/utils/resolve.js @@ -23,7 +23,7 @@ export const resolvePath = async function (path, basedir) { // Fallback. // `resolve` sometimes gives unhelpful error messages. // https://github.com/browserify/resolve/issues/223 - } catch (e) { + } catch { return require.resolve(path, { paths: [basedir] }) } } diff --git a/packages/config/src/api/site_info.ts b/packages/config/src/api/site_info.ts index 807623c634..173384bfb7 100644 --- a/packages/config/src/api/site_info.ts +++ b/packages/config/src/api/site_info.ts @@ -160,7 +160,7 @@ const getIntegrations = async function ({ const response = await fetch(url) const integrations = await response.json() return Array.isArray(integrations) ? integrations : [] - } catch (error) { + } catch { return [] } } diff --git a/packages/opentelemetry-sdk-setup/tests/main.test.ts b/packages/opentelemetry-sdk-setup/tests/main.test.ts index 20eaac279c..7100555b40 100644 --- a/packages/opentelemetry-sdk-setup/tests/main.test.ts +++ b/packages/opentelemetry-sdk-setup/tests/main.test.ts @@ -126,7 +126,7 @@ test('Tracing - trace id and resource definition', async () => { const tracer = trace.getTracer('test') const span = tracer.startSpan('test', {}, ctx) as Span - expect(span.spanContext().traceId).not.empty + expect(span.spanContext().traceId).toBeDefined() expect(span.parentSpanId).toBeUndefined() }) diff --git a/packages/opentelemetry-utils/tests/main.test.ts b/packages/opentelemetry-utils/tests/main.test.ts index f3fe743358..91f7dcb403 100644 --- a/packages/opentelemetry-utils/tests/main.test.ts +++ b/packages/opentelemetry-utils/tests/main.test.ts @@ -64,7 +64,7 @@ test('addErrorToActiveSpan - no attributes are added', async () => { const firstEvent = span.events[0] expect(firstEvent.name).equal('exception') - expect(firstEvent.attributes?.['exception.stacktrace']).to.exist + expect(firstEvent.attributes?.['exception.stacktrace']).toBeDefined() expect(firstEvent.attributes?.['exception.type']).equal('Error') }) }) @@ -90,7 +90,7 @@ test('addErrorToActiveSpan - attributes are added', async () => { const firstEvent = span.events[0] expect(firstEvent.name).equal('exception') - expect(firstEvent.attributes?.['exception.stacktrace']).to.exist + expect(firstEvent.attributes?.['exception.stacktrace']).toBeDefined() expect(firstEvent.attributes?.['exception.type']).equal('Error') }) }) diff --git a/packages/zip-it-and-ship-it/tests/main.test.ts b/packages/zip-it-and-ship-it/tests/main.test.ts index 6c9199b3d2..e25a1c99bc 100644 --- a/packages/zip-it-and-ship-it/tests/main.test.ts +++ b/packages/zip-it-and-ship-it/tests/main.test.ts @@ -53,9 +53,10 @@ interface CustomMatchers { } declare module 'vitest' { - // eslint-disable-next-line @typescript-eslint/no-empty-interface + // eslint-disable-next-line @typescript-eslint/no-empty-object-type interface Assertion extends CustomMatchers {} - // eslint-disable-next-line @typescript-eslint/no-empty-interface + + // eslint-disable-next-line @typescript-eslint/no-empty-object-type interface AsymmetricMatchersContaining extends CustomMatchers {} } From d346579102df7b5e1d9d046e2819fde7841c7356 Mon Sep 17 00:00:00 2001 From: Mateusz Bocian Date: Fri, 17 Jan 2025 16:37:02 -0500 Subject: [PATCH 3/3] fix: adjust eslint ignore rules for NetlifyAPI as the rules were renamed --- packages/js-client/src/index.ts | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/packages/js-client/src/index.ts b/packages/js-client/src/index.ts index 8a17b297d8..189267fa49 100644 --- a/packages/js-client/src/index.ts +++ b/packages/js-client/src/index.ts @@ -40,9 +40,11 @@ type APIOptions = { * const sites = await client.listSites() * ``` */ -// eslint-disable-next-line @typescript-eslint/no-empty-interface -- NetlifyAPI is a class and the interface just inherits mapped types +// NetlifyAPI is a class and the interface just inherits mapped types +// eslint-disable-next-line @typescript-eslint/no-empty-object-type, @typescript-eslint/no-unsafe-declaration-merging export interface NetlifyAPI extends DynamicMethods {} +// eslint-disable-next-line @typescript-eslint/no-unsafe-declaration-merging export class NetlifyAPI { #accessToken: string | undefined | null = null