From 1789f8c75ec2d0ad2f14a38b27022b74bb962543 Mon Sep 17 00:00:00 2001 From: Philippe Serhal Date: Wed, 7 Oct 2026 08:33:04 -0400 Subject: [PATCH 1/3] chore(eslint): use eslint's native bulk suppressions instead We seeingly came up with the same strategy that was later added to eslint itself: "bulk suppressions". This replaces our custom approach with the native one. As a bonus, eslint now fails when the suppressions become stale, --- .oxfmtrc.json | 2 +- CONTRIBUTING.md | 5 + eslint-suppressions.json | 1855 ++++++++++++++++++++++++++++++ eslint.config.js | 18 +- eslint_temporary_suppressions.js | 1421 ----------------------- 5 files changed, 1874 insertions(+), 1427 deletions(-) create mode 100644 eslint-suppressions.json delete mode 100644 eslint_temporary_suppressions.js diff --git a/.oxfmtrc.json b/.oxfmtrc.json index dc3940d871d..ed00ea46d00 100644 --- a/.oxfmtrc.json +++ b/.oxfmtrc.json @@ -3,5 +3,5 @@ "semi": false, "singleQuote": true, "sortPackageJson": true, - "ignorePatterns": ["node_modules", "CHANGELOG.md", "docs/**", "**/package-lock.json"] + "ignorePatterns": ["node_modules", "CHANGELOG.md", "docs/**", "**/package-lock.json", "eslint-suppressions.json"] } diff --git a/CONTRIBUTING.md b/CONTRIBUTING.md index 8314d2367ab..d22978836ec 100644 --- a/CONTRIBUTING.md +++ b/CONTRIBUTING.md @@ -74,6 +74,11 @@ npm run format npm run lint:fix ``` +Pre-existing lint violations are tracked in `eslint-suppressions.json` using ESLint's +[bulk suppressions](https://eslint.org/docs/latest/use/suppressions). When you fix a suppressed violation, run +`npx eslint --prune-suppressions` to remove the stale entry (ESLint fails until you do). Please don't add new +suppressions. + To run the CLI locally: ```bash diff --git a/eslint-suppressions.json b/eslint-suppressions.json new file mode 100644 index 00000000000..fb0dce4f4b8 --- /dev/null +++ b/eslint-suppressions.json @@ -0,0 +1,1855 @@ +{ + "bin/run.js": { + "n/no-unpublished-bin": { + "count": 1 + } + }, + "e2e/install.e2e.ts": { + "@typescript-eslint/await-thenable": { + "count": 3 + }, + "@typescript-eslint/prefer-nullish-coalescing": { + "count": 7 + } + }, + "src/commands/api/api.ts": { + "@typescript-eslint/no-unsafe-argument": { + "count": 1 + }, + "@typescript-eslint/no-unsafe-assignment": { + "count": 3 + }, + "@typescript-eslint/restrict-template-expressions": { + "count": 1 + } + }, + "src/commands/api/index.ts": { + "@typescript-eslint/no-unsafe-argument": { + "count": 3 + } + }, + "src/commands/base-command.ts": { + "@typescript-eslint/no-explicit-any": { + "count": 3 + }, + "@typescript-eslint/no-floating-promises": { + "count": 1 + }, + "@typescript-eslint/no-unnecessary-boolean-literal-compare": { + "count": 2 + }, + "@typescript-eslint/no-unnecessary-condition": { + "count": 5 + }, + "@typescript-eslint/no-unnecessary-type-parameters": { + "count": 1 + }, + "@typescript-eslint/no-unsafe-argument": { + "count": 7 + }, + "@typescript-eslint/no-unsafe-assignment": { + "count": 14 + }, + "@typescript-eslint/no-unsafe-call": { + "count": 2 + }, + "@typescript-eslint/no-unsafe-member-access": { + "count": 7 + }, + "@typescript-eslint/prefer-nullish-coalescing": { + "count": 18 + }, + "@typescript-eslint/restrict-template-expressions": { + "count": 5 + } + }, + "src/commands/blobs/blobs-delete.ts": { + "@typescript-eslint/no-explicit-any": { + "count": 1 + }, + "@typescript-eslint/no-unsafe-assignment": { + "count": 3 + }, + "@typescript-eslint/no-unsafe-member-access": { + "count": 5 + }, + "@typescript-eslint/restrict-template-expressions": { + "count": 2 + } + }, + "src/commands/blobs/blobs-get.ts": { + "@typescript-eslint/no-unnecessary-condition": { + "count": 3 + } + }, + "src/commands/build/build.ts": { + "@typescript-eslint/no-unsafe-assignment": { + "count": 1 + } + }, + "src/commands/build/index.ts": { + "@typescript-eslint/no-unsafe-argument": { + "count": 2 + }, + "@typescript-eslint/prefer-nullish-coalescing": { + "count": 1 + } + }, + "src/commands/completion/completion.ts": { + "@typescript-eslint/prefer-nullish-coalescing": { + "count": 1 + } + }, + "src/commands/create/create-action.ts": { + "@typescript-eslint/no-empty-function": { + "count": 1 + }, + "@typescript-eslint/prefer-nullish-coalescing": { + "count": 2 + } + }, + "src/commands/deploy/deploy.ts": { + "@typescript-eslint/ban-ts-comment": { + "count": 2 + }, + "@typescript-eslint/no-dynamic-delete": { + "count": 2 + }, + "@typescript-eslint/no-empty-function": { + "count": 7 + }, + "@typescript-eslint/no-unnecessary-condition": { + "count": 2 + }, + "@typescript-eslint/no-unsafe-argument": { + "count": 13 + }, + "@typescript-eslint/no-unsafe-assignment": { + "count": 63 + }, + "@typescript-eslint/no-unsafe-call": { + "count": 2 + }, + "@typescript-eslint/no-unsafe-member-access": { + "count": 56 + }, + "@typescript-eslint/no-unsafe-return": { + "count": 1 + }, + "@typescript-eslint/prefer-nullish-coalescing": { + "count": 13 + }, + "@typescript-eslint/restrict-template-expressions": { + "count": 15 + } + }, + "src/commands/dev/dev.ts": { + "@typescript-eslint/no-unsafe-argument": { + "count": 2 + }, + "@typescript-eslint/no-unsafe-assignment": { + "count": 14 + }, + "@typescript-eslint/prefer-nullish-coalescing": { + "count": 1 + }, + "n/no-process-exit": { + "count": 1 + } + }, + "src/commands/env/env-clone.ts": { + "@typescript-eslint/no-unnecessary-boolean-literal-compare": { + "count": 1 + }, + "@typescript-eslint/no-unsafe-argument": { + "count": 2 + }, + "@typescript-eslint/no-unsafe-assignment": { + "count": 27 + }, + "@typescript-eslint/no-unsafe-call": { + "count": 9 + }, + "@typescript-eslint/no-unsafe-member-access": { + "count": 22 + }, + "@typescript-eslint/no-unsafe-return": { + "count": 3 + }, + "@typescript-eslint/prefer-nullish-coalescing": { + "count": 1 + } + }, + "src/commands/env/env-get.ts": { + "@typescript-eslint/no-unsafe-argument": { + "count": 2 + }, + "@typescript-eslint/no-unsafe-assignment": { + "count": 4 + }, + "@typescript-eslint/prefer-nullish-coalescing": { + "count": 1 + } + }, + "src/commands/env/env-import.ts": { + "@typescript-eslint/no-unsafe-argument": { + "count": 5 + }, + "@typescript-eslint/no-unsafe-assignment": { + "count": 13 + }, + "@typescript-eslint/no-unsafe-call": { + "count": 8 + }, + "@typescript-eslint/no-unsafe-member-access": { + "count": 12 + }, + "@typescript-eslint/no-unsafe-return": { + "count": 3 + } + }, + "src/commands/env/env-list.ts": { + "@typescript-eslint/no-unsafe-argument": { + "count": 1 + }, + "@typescript-eslint/no-unsafe-assignment": { + "count": 2 + }, + "@typescript-eslint/no-unsafe-member-access": { + "count": 2 + }, + "@typescript-eslint/restrict-template-expressions": { + "count": 2 + } + }, + "src/commands/env/env-set.ts": { + "@typescript-eslint/no-unnecessary-boolean-literal-compare": { + "count": 1 + }, + "@typescript-eslint/no-unnecessary-condition": { + "count": 1 + }, + "@typescript-eslint/no-unsafe-argument": { + "count": 8 + }, + "@typescript-eslint/no-unsafe-assignment": { + "count": 35 + }, + "@typescript-eslint/no-unsafe-call": { + "count": 13 + }, + "@typescript-eslint/no-unsafe-member-access": { + "count": 24 + }, + "@typescript-eslint/no-unsafe-return": { + "count": 1 + }, + "@typescript-eslint/prefer-nullish-coalescing": { + "count": 5 + }, + "@typescript-eslint/restrict-template-expressions": { + "count": 1 + } + }, + "src/commands/env/env-unset.ts": { + "@typescript-eslint/no-dynamic-delete": { + "count": 1 + }, + "@typescript-eslint/no-unnecessary-boolean-literal-compare": { + "count": 1 + }, + "@typescript-eslint/no-unsafe-argument": { + "count": 4 + }, + "@typescript-eslint/no-unsafe-assignment": { + "count": 20 + }, + "@typescript-eslint/no-unsafe-call": { + "count": 8 + }, + "@typescript-eslint/no-unsafe-member-access": { + "count": 20 + }, + "@typescript-eslint/no-unsafe-return": { + "count": 2 + }, + "@typescript-eslint/prefer-nullish-coalescing": { + "count": 4 + } + }, + "src/commands/functions/functions-create.ts": { + "@typescript-eslint/await-thenable": { + "count": 1 + }, + "@typescript-eslint/no-confusing-void-expression": { + "count": 1 + }, + "@typescript-eslint/no-floating-promises": { + "count": 1 + }, + "@typescript-eslint/no-unnecessary-condition": { + "count": 2 + }, + "@typescript-eslint/no-unnecessary-type-conversion": { + "count": 1 + }, + "@typescript-eslint/no-unsafe-argument": { + "count": 36 + }, + "@typescript-eslint/no-unsafe-assignment": { + "count": 64 + }, + "@typescript-eslint/no-unsafe-call": { + "count": 11 + }, + "@typescript-eslint/no-unsafe-member-access": { + "count": 59 + }, + "@typescript-eslint/no-unsafe-return": { + "count": 11 + }, + "@typescript-eslint/prefer-nullish-coalescing": { + "count": 4 + }, + "@typescript-eslint/prefer-optional-chain": { + "count": 1 + }, + "@typescript-eslint/restrict-plus-operands": { + "count": 6 + }, + "@typescript-eslint/restrict-template-expressions": { + "count": 29 + }, + "n/no-process-exit": { + "count": 2 + } + }, + "src/commands/functions/functions-invoke.ts": { + "@typescript-eslint/no-unsafe-argument": { + "count": 4 + }, + "@typescript-eslint/no-unsafe-assignment": { + "count": 13 + }, + "@typescript-eslint/no-unsafe-call": { + "count": 3 + }, + "@typescript-eslint/no-unsafe-member-access": { + "count": 5 + }, + "@typescript-eslint/no-unsafe-return": { + "count": 7 + }, + "@typescript-eslint/prefer-nullish-coalescing": { + "count": 3 + }, + "@typescript-eslint/restrict-template-expressions": { + "count": 3 + }, + "no-empty": { + "count": 1 + } + }, + "src/commands/functions/functions-serve.ts": { + "@typescript-eslint/no-unnecessary-condition": { + "count": 1 + }, + "@typescript-eslint/no-unsafe-assignment": { + "count": 7 + }, + "@typescript-eslint/prefer-nullish-coalescing": { + "count": 1 + } + }, + "src/commands/init/init.ts": { + "@typescript-eslint/no-unsafe-assignment": { + "count": 3 + } + }, + "src/commands/link/link.ts": { + "@typescript-eslint/no-unnecessary-condition": { + "count": 3 + }, + "@typescript-eslint/prefer-nullish-coalescing": { + "count": 3 + }, + "@typescript-eslint/prefer-optional-chain": { + "count": 1 + }, + "@typescript-eslint/restrict-template-expressions": { + "count": 2 + } + }, + "src/commands/logs/build.ts": { + "@typescript-eslint/no-explicit-any": { + "count": 3 + }, + "@typescript-eslint/no-unsafe-argument": { + "count": 1 + }, + "@typescript-eslint/no-unsafe-assignment": { + "count": 7 + }, + "@typescript-eslint/no-unsafe-call": { + "count": 1 + }, + "@typescript-eslint/no-unsafe-member-access": { + "count": 6 + }, + "@typescript-eslint/prefer-nullish-coalescing": { + "count": 1 + }, + "@typescript-eslint/restrict-template-expressions": { + "count": 2 + } + }, + "src/commands/logs/index.ts": { + "@typescript-eslint/restrict-template-expressions": { + "count": 1 + } + }, + "src/commands/main.ts": { + "@typescript-eslint/no-floating-promises": { + "count": 1 + }, + "@typescript-eslint/no-misused-promises": { + "count": 1 + }, + "@typescript-eslint/no-unnecessary-condition": { + "count": 1 + }, + "@typescript-eslint/no-unsafe-argument": { + "count": 2 + }, + "@typescript-eslint/no-unsafe-assignment": { + "count": 2 + }, + "@typescript-eslint/no-unsafe-call": { + "count": 11 + }, + "@typescript-eslint/no-unsafe-member-access": { + "count": 23 + }, + "@typescript-eslint/no-unsafe-return": { + "count": 1 + }, + "@typescript-eslint/prefer-nullish-coalescing": { + "count": 1 + }, + "@typescript-eslint/restrict-template-expressions": { + "count": 6 + }, + "n/no-process-exit": { + "count": 2 + } + }, + "src/commands/recipes/common.ts": { + "@typescript-eslint/no-unsafe-argument": { + "count": 1 + }, + "@typescript-eslint/no-unsafe-assignment": { + "count": 2 + }, + "@typescript-eslint/no-unsafe-return": { + "count": 3 + } + }, + "src/commands/recipes/recipes-list.ts": { + "@typescript-eslint/no-unsafe-argument": { + "count": 2 + } + }, + "src/commands/recipes/recipes.ts": { + "@typescript-eslint/no-explicit-any": { + "count": 1 + }, + "@typescript-eslint/no-unsafe-assignment": { + "count": 1 + }, + "@typescript-eslint/no-unsafe-call": { + "count": 1 + }, + "@typescript-eslint/no-unsafe-member-access": { + "count": 1 + }, + "@typescript-eslint/no-unsafe-return": { + "count": 2 + } + }, + "src/commands/serve/serve.ts": { + "@typescript-eslint/no-unsafe-argument": { + "count": 3 + }, + "@typescript-eslint/no-unsafe-assignment": { + "count": 12 + } + }, + "src/commands/sites/sites-create.ts": { + "@typescript-eslint/no-floating-promises": { + "count": 1 + }, + "@typescript-eslint/no-unsafe-argument": { + "count": 2 + }, + "@typescript-eslint/no-unsafe-assignment": { + "count": 1 + }, + "@typescript-eslint/prefer-nullish-coalescing": { + "count": 1 + }, + "@typescript-eslint/restrict-template-expressions": { + "count": 3 + } + }, + "src/commands/sites/sites-delete.ts": { + "@typescript-eslint/no-unsafe-argument": { + "count": 1 + }, + "@typescript-eslint/restrict-template-expressions": { + "count": 2 + } + }, + "src/commands/sites/sites-list.ts": { + "@typescript-eslint/no-unnecessary-condition": { + "count": 2 + }, + "@typescript-eslint/prefer-optional-chain": { + "count": 1 + }, + "@typescript-eslint/restrict-template-expressions": { + "count": 1 + } + }, + "src/commands/switch/switch.ts": { + "@typescript-eslint/prefer-nullish-coalescing": { + "count": 1 + } + }, + "src/commands/types.d.ts": { + "@typescript-eslint/related-getter-setter-pairs": { + "count": 1 + } + }, + "src/commands/unlink/unlink.ts": { + "@typescript-eslint/no-unnecessary-condition": { + "count": 3 + }, + "@typescript-eslint/prefer-optional-chain": { + "count": 1 + } + }, + "src/commands/watch/watch.ts": { + "@typescript-eslint/no-unnecessary-condition": { + "count": 1 + }, + "@typescript-eslint/prefer-nullish-coalescing": { + "count": 1 + } + }, + "src/lib/blobs/blobs.ts": { + "@typescript-eslint/restrict-template-expressions": { + "count": 1 + } + }, + "src/lib/build.ts": { + "@typescript-eslint/no-explicit-any": { + "count": 2 + }, + "@typescript-eslint/no-unsafe-assignment": { + "count": 6 + }, + "@typescript-eslint/prefer-nullish-coalescing": { + "count": 1 + } + }, + "src/lib/completion/generate-autocompletion.ts": { + "@typescript-eslint/no-unsafe-assignment": { + "count": 5 + }, + "@typescript-eslint/no-unsafe-call": { + "count": 9 + }, + "@typescript-eslint/no-unsafe-member-access": { + "count": 12 + }, + "@typescript-eslint/no-unsafe-return": { + "count": 1 + }, + "@typescript-eslint/restrict-template-expressions": { + "count": 1 + } + }, + "src/lib/completion/script.ts": { + "@typescript-eslint/no-unsafe-argument": { + "count": 1 + }, + "@typescript-eslint/no-unsafe-assignment": { + "count": 1 + }, + "n/hashbang": { + "count": 1 + } + }, + "src/lib/edge-functions/editor-helper.ts": { + "@typescript-eslint/no-unsafe-assignment": { + "count": 1 + }, + "@typescript-eslint/no-unsafe-call": { + "count": 4 + }, + "@typescript-eslint/no-unsafe-member-access": { + "count": 5 + }, + "@typescript-eslint/restrict-template-expressions": { + "count": 2 + } + }, + "src/lib/edge-functions/headers.ts": { + "@typescript-eslint/no-unsafe-assignment": { + "count": 1 + }, + "@typescript-eslint/no-unsafe-call": { + "count": 1 + }, + "@typescript-eslint/no-unsafe-member-access": { + "count": 1 + }, + "@typescript-eslint/no-unsafe-return": { + "count": 1 + } + }, + "src/lib/edge-functions/proxy.ts": { + "@typescript-eslint/no-non-null-assertion": { + "count": 2 + }, + "@typescript-eslint/no-unnecessary-condition": { + "count": 3 + }, + "@typescript-eslint/no-unsafe-argument": { + "count": 2 + }, + "@typescript-eslint/no-unsafe-assignment": { + "count": 5 + }, + "@typescript-eslint/restrict-template-expressions": { + "count": 4 + } + }, + "src/lib/edge-functions/registry.ts": { + "@typescript-eslint/no-floating-promises": { + "count": 1 + }, + "@typescript-eslint/no-misused-promises": { + "count": 4 + }, + "@typescript-eslint/no-unnecessary-condition": { + "count": 11 + }, + "@typescript-eslint/no-unsafe-argument": { + "count": 1 + }, + "@typescript-eslint/no-unsafe-assignment": { + "count": 5 + }, + "@typescript-eslint/no-unsafe-member-access": { + "count": 7 + }, + "@typescript-eslint/no-unsafe-return": { + "count": 2 + }, + "@typescript-eslint/prefer-nullish-coalescing": { + "count": 2 + }, + "@typescript-eslint/restrict-template-expressions": { + "count": 1 + }, + "no-empty": { + "count": 1 + } + }, + "src/lib/exec-fetcher.ts": { + "@typescript-eslint/no-unnecessary-condition": { + "count": 1 + }, + "@typescript-eslint/prefer-regexp-exec": { + "count": 1 + } + }, + "src/lib/extensions.ts": { + "@typescript-eslint/prefer-nullish-coalescing": { + "count": 1 + } + }, + "src/lib/functions/form-submissions-handler.ts": { + "@typescript-eslint/no-deprecated": { + "count": 1 + }, + "@typescript-eslint/no-unnecessary-type-conversion": { + "count": 1 + }, + "@typescript-eslint/no-unsafe-assignment": { + "count": 9 + }, + "@typescript-eslint/no-unsafe-member-access": { + "count": 1 + } + }, + "src/lib/functions/local-proxy.ts": { + "@typescript-eslint/prefer-nullish-coalescing": { + "count": 1 + } + }, + "src/lib/functions/netlify-function.ts": { + "@typescript-eslint/no-unnecessary-condition": { + "count": 8 + }, + "@typescript-eslint/no-unsafe-assignment": { + "count": 2 + }, + "@typescript-eslint/prefer-nullish-coalescing": { + "count": 1 + }, + "@typescript-eslint/restrict-template-expressions": { + "count": 1 + } + }, + "src/lib/functions/registry.ts": { + "@typescript-eslint/no-floating-promises": { + "count": 4 + }, + "@typescript-eslint/no-non-null-assertion": { + "count": 1 + }, + "@typescript-eslint/no-unnecessary-condition": { + "count": 2 + }, + "@typescript-eslint/no-unnecessary-type-conversion": { + "count": 1 + } + }, + "src/lib/functions/server.ts": { + "@typescript-eslint/no-deprecated": { + "count": 1 + }, + "@typescript-eslint/no-dynamic-delete": { + "count": 2 + }, + "@typescript-eslint/no-unnecessary-condition": { + "count": 1 + }, + "@typescript-eslint/no-unsafe-assignment": { + "count": 4 + }, + "@typescript-eslint/no-unsafe-call": { + "count": 1 + }, + "@typescript-eslint/no-unsafe-member-access": { + "count": 2 + }, + "@typescript-eslint/prefer-nullish-coalescing": { + "count": 4 + } + }, + "src/lib/http-agent.ts": { + "@typescript-eslint/no-unsafe-argument": { + "count": 4 + }, + "@typescript-eslint/no-unsafe-assignment": { + "count": 6 + }, + "@typescript-eslint/no-unsafe-call": { + "count": 2 + }, + "@typescript-eslint/no-unsafe-member-access": { + "count": 2 + }, + "@typescript-eslint/no-unsafe-return": { + "count": 2 + }, + "@typescript-eslint/prefer-nullish-coalescing": { + "count": 2 + } + }, + "src/lib/spinner.ts": { + "@typescript-eslint/no-unnecessary-condition": { + "count": 1 + } + }, + "src/recipes/ai-context/context.ts": { + "@typescript-eslint/prefer-regexp-exec": { + "count": 2 + }, + "no-empty": { + "count": 1 + } + }, + "src/recipes/ai-context/index.ts": { + "@typescript-eslint/no-unnecessary-condition": { + "count": 3 + }, + "@typescript-eslint/prefer-nullish-coalescing": { + "count": 1 + } + }, + "src/recipes/blobs-migrate/index.ts": { + "@typescript-eslint/restrict-template-expressions": { + "count": 1 + } + }, + "src/recipes/vscode/index.ts": { + "@typescript-eslint/no-floating-promises": { + "count": 1 + }, + "@typescript-eslint/no-unsafe-argument": { + "count": 2 + }, + "@typescript-eslint/no-unsafe-assignment": { + "count": 9 + }, + "@typescript-eslint/no-unsafe-member-access": { + "count": 1 + }, + "@typescript-eslint/no-unsafe-return": { + "count": 1 + }, + "@typescript-eslint/prefer-nullish-coalescing": { + "count": 1 + } + }, + "src/recipes/vscode/settings.ts": { + "@typescript-eslint/no-unsafe-argument": { + "count": 6 + }, + "@typescript-eslint/no-unsafe-assignment": { + "count": 3 + }, + "@typescript-eslint/no-unsafe-call": { + "count": 2 + }, + "@typescript-eslint/no-unsafe-member-access": { + "count": 7 + }, + "@typescript-eslint/no-unsafe-return": { + "count": 1 + }, + "@typescript-eslint/prefer-nullish-coalescing": { + "count": 1 + }, + "@typescript-eslint/restrict-template-expressions": { + "count": 2 + } + }, + "src/utils/addons/prepare.ts": { + "@typescript-eslint/no-unsafe-assignment": { + "count": 4 + }, + "@typescript-eslint/no-unsafe-call": { + "count": 3 + }, + "@typescript-eslint/no-unsafe-member-access": { + "count": 4 + }, + "@typescript-eslint/no-unsafe-return": { + "count": 3 + } + }, + "src/utils/agent-detection.ts": { + "@typescript-eslint/prefer-nullish-coalescing": { + "count": 1 + } + }, + "src/utils/build-info.ts": { + "@typescript-eslint/no-unnecessary-condition": { + "count": 5 + }, + "@typescript-eslint/restrict-template-expressions": { + "count": 4 + } + }, + "src/utils/command-helpers.ts": { + "@typescript-eslint/restrict-template-expressions": { + "count": 1 + }, + "n/no-process-exit": { + "count": 1 + }, + "no-restricted-imports": { + "count": 1 + } + }, + "src/utils/copy-template-dir/copy-template-dir.ts": { + "@typescript-eslint/no-misused-promises": { + "count": 1 + }, + "@typescript-eslint/prefer-nullish-coalescing": { + "count": 1 + }, + "@typescript-eslint/prefer-promise-reject-errors": { + "count": 1 + } + }, + "src/utils/create-stream-promise.ts": { + "@typescript-eslint/no-unnecessary-condition": { + "count": 1 + } + }, + "src/utils/deploy/deploy-site.ts": { + "@typescript-eslint/await-thenable": { + "count": 1 + }, + "@typescript-eslint/no-confusing-void-expression": { + "count": 2 + }, + "@typescript-eslint/no-unsafe-argument": { + "count": 6 + }, + "@typescript-eslint/no-unsafe-assignment": { + "count": 28 + }, + "@typescript-eslint/no-unsafe-call": { + "count": 1 + }, + "@typescript-eslint/no-unsafe-member-access": { + "count": 11 + }, + "@typescript-eslint/restrict-template-expressions": { + "count": 1 + } + }, + "src/utils/deploy/deploy-source.ts": { + "@typescript-eslint/prefer-nullish-coalescing": { + "count": 1 + } + }, + "src/utils/deploy/drop-api.ts": { + "@typescript-eslint/no-empty-function": { + "count": 1 + } + }, + "src/utils/deploy/hash-config.ts": { + "@typescript-eslint/no-unused-vars": { + "count": 1 + } + }, + "src/utils/deploy/hash-files.ts": { + "@typescript-eslint/no-unsafe-argument": { + "count": 1 + }, + "@typescript-eslint/no-unsafe-assignment": { + "count": 4 + } + }, + "src/utils/deploy/hash-fns.ts": { + "@typescript-eslint/no-unnecessary-condition": { + "count": 20 + }, + "@typescript-eslint/no-unsafe-argument": { + "count": 3 + }, + "@typescript-eslint/no-unsafe-assignment": { + "count": 10 + }, + "@typescript-eslint/no-unsafe-call": { + "count": 4 + }, + "@typescript-eslint/prefer-nullish-coalescing": { + "count": 9 + } + }, + "src/utils/deploy/hasher-segments.ts": { + "@typescript-eslint/no-misused-promises": { + "count": 1 + }, + "@typescript-eslint/no-unsafe-argument": { + "count": 5 + }, + "@typescript-eslint/no-unsafe-assignment": { + "count": 2 + }, + "@typescript-eslint/no-unsafe-member-access": { + "count": 13 + }, + "@typescript-eslint/restrict-template-expressions": { + "count": 1 + } + }, + "src/utils/deploy/upload-files.ts": { + "@typescript-eslint/no-floating-promises": { + "count": 1 + }, + "@typescript-eslint/prefer-promise-reject-errors": { + "count": 3 + }, + "@typescript-eslint/restrict-template-expressions": { + "count": 2 + } + }, + "src/utils/deploy/upload-source-zip.ts": { + "@typescript-eslint/no-empty-function": { + "count": 1 + } + }, + "src/utils/deploy/util.ts": { + "@typescript-eslint/no-unsafe-argument": { + "count": 2 + }, + "@typescript-eslint/no-unsafe-assignment": { + "count": 12 + }, + "@typescript-eslint/no-unsafe-call": { + "count": 3 + }, + "@typescript-eslint/no-unsafe-member-access": { + "count": 9 + }, + "@typescript-eslint/no-unsafe-return": { + "count": 2 + }, + "@typescript-eslint/prefer-nullish-coalescing": { + "count": 2 + }, + "@typescript-eslint/restrict-template-expressions": { + "count": 3 + } + }, + "src/utils/detect-server-settings.ts": { + "@typescript-eslint/no-unsafe-argument": { + "count": 2 + }, + "@typescript-eslint/no-unsafe-assignment": { + "count": 5 + }, + "@typescript-eslint/no-unsafe-member-access": { + "count": 3 + }, + "@typescript-eslint/no-unsafe-return": { + "count": 1 + }, + "@typescript-eslint/prefer-nullish-coalescing": { + "count": 13 + }, + "@typescript-eslint/restrict-template-expressions": { + "count": 3 + } + }, + "src/utils/dev.ts": { + "@typescript-eslint/no-unsafe-argument": { + "count": 5 + }, + "@typescript-eslint/no-unsafe-assignment": { + "count": 15 + }, + "@typescript-eslint/no-unsafe-call": { + "count": 4 + }, + "@typescript-eslint/no-unsafe-member-access": { + "count": 16 + }, + "@typescript-eslint/no-unsafe-return": { + "count": 5 + }, + "@typescript-eslint/prefer-nullish-coalescing": { + "count": 2 + }, + "@typescript-eslint/restrict-template-expressions": { + "count": 6 + } + }, + "src/utils/dot-env.ts": { + "@typescript-eslint/no-unsafe-argument": { + "count": 1 + }, + "@typescript-eslint/no-unsafe-assignment": { + "count": 2 + }, + "@typescript-eslint/restrict-template-expressions": { + "count": 1 + } + }, + "src/utils/env/index.ts": { + "@typescript-eslint/no-unnecessary-condition": { + "count": 1 + }, + "@typescript-eslint/no-unsafe-member-access": { + "count": 1 + }, + "@typescript-eslint/prefer-optional-chain": { + "count": 1 + } + }, + "src/utils/execa.ts": { + "@typescript-eslint/no-unsafe-assignment": { + "count": 2 + }, + "@typescript-eslint/no-unsafe-member-access": { + "count": 1 + } + }, + "src/utils/framework-server.ts": { + "@typescript-eslint/no-floating-promises": { + "count": 2 + }, + "@typescript-eslint/prefer-nullish-coalescing": { + "count": 3 + }, + "@typescript-eslint/restrict-template-expressions": { + "count": 6 + } + }, + "src/utils/frameworks-api.ts": { + "@typescript-eslint/no-unsafe-assignment": { + "count": 1 + }, + "@typescript-eslint/prefer-nullish-coalescing": { + "count": 1 + } + }, + "src/utils/functions/get-functions.ts": { + "@typescript-eslint/no-unsafe-argument": { + "count": 3 + }, + "@typescript-eslint/no-unsafe-assignment": { + "count": 7 + }, + "@typescript-eslint/no-unsafe-call": { + "count": 1 + }, + "@typescript-eslint/no-unsafe-member-access": { + "count": 1 + }, + "@typescript-eslint/restrict-template-expressions": { + "count": 1 + } + }, + "src/utils/get-repo-data.ts": { + "@typescript-eslint/no-unnecessary-condition": { + "count": 1 + }, + "@typescript-eslint/no-unsafe-argument": { + "count": 4 + }, + "@typescript-eslint/no-unsafe-assignment": { + "count": 2 + }, + "@typescript-eslint/no-unsafe-member-access": { + "count": 3 + }, + "@typescript-eslint/prefer-nullish-coalescing": { + "count": 1 + }, + "@typescript-eslint/prefer-optional-chain": { + "count": 1 + }, + "@typescript-eslint/restrict-template-expressions": { + "count": 3 + } + }, + "src/utils/headers.ts": { + "@typescript-eslint/no-unsafe-assignment": { + "count": 1 + }, + "@typescript-eslint/no-unsafe-return": { + "count": 1 + } + }, + "src/utils/init/config-github.ts": { + "@typescript-eslint/no-unsafe-assignment": { + "count": 14 + }, + "@typescript-eslint/no-unsafe-call": { + "count": 5 + }, + "@typescript-eslint/no-unsafe-member-access": { + "count": 9 + }, + "@typescript-eslint/no-unsafe-return": { + "count": 2 + } + }, + "src/utils/init/config.ts": { + "@typescript-eslint/restrict-template-expressions": { + "count": 1 + } + }, + "src/utils/init/utils.ts": { + "@typescript-eslint/ban-ts-comment": { + "count": 1 + }, + "@typescript-eslint/no-unsafe-argument": { + "count": 1 + }, + "@typescript-eslint/no-unsafe-assignment": { + "count": 1 + }, + "@typescript-eslint/no-unsafe-member-access": { + "count": 4 + }, + "@typescript-eslint/prefer-nullish-coalescing": { + "count": 2 + }, + "@typescript-eslint/restrict-template-expressions": { + "count": 3 + } + }, + "src/utils/login-url.ts": { + "@typescript-eslint/prefer-nullish-coalescing": { + "count": 1 + } + }, + "src/utils/parse-raw-flags.ts": { + "@typescript-eslint/no-unsafe-assignment": { + "count": 2 + } + }, + "src/utils/proxy-server.ts": { + "@typescript-eslint/no-unsafe-member-access": { + "count": 1 + }, + "@typescript-eslint/prefer-nullish-coalescing": { + "count": 1 + }, + "@typescript-eslint/restrict-template-expressions": { + "count": 1 + } + }, + "src/utils/proxy.ts": { + "@typescript-eslint/no-deprecated": { + "count": 1 + }, + "@typescript-eslint/no-empty-function": { + "count": 1 + }, + "@typescript-eslint/no-explicit-any": { + "count": 1 + }, + "@typescript-eslint/no-misused-promises": { + "count": 7 + }, + "@typescript-eslint/no-unnecessary-condition": { + "count": 7 + }, + "@typescript-eslint/no-unsafe-argument": { + "count": 38 + }, + "@typescript-eslint/no-unsafe-assignment": { + "count": 69 + }, + "@typescript-eslint/no-unsafe-call": { + "count": 28 + }, + "@typescript-eslint/no-unsafe-member-access": { + "count": 98 + }, + "@typescript-eslint/no-unsafe-return": { + "count": 13 + }, + "@typescript-eslint/no-unused-vars": { + "count": 1 + }, + "@typescript-eslint/prefer-nullish-coalescing": { + "count": 10 + }, + "@typescript-eslint/prefer-optional-chain": { + "count": 1 + }, + "@typescript-eslint/restrict-template-expressions": { + "count": 23 + } + }, + "src/utils/read-repo-url.ts": { + "@typescript-eslint/no-deprecated": { + "count": 2 + } + }, + "src/utils/redirects.ts": { + "@typescript-eslint/no-unsafe-assignment": { + "count": 11 + }, + "@typescript-eslint/no-unsafe-call": { + "count": 2 + }, + "@typescript-eslint/no-unsafe-member-access": { + "count": 4 + }, + "@typescript-eslint/no-unsafe-return": { + "count": 3 + }, + "@typescript-eslint/prefer-nullish-coalescing": { + "count": 1 + }, + "@typescript-eslint/restrict-template-expressions": { + "count": 1 + } + }, + "src/utils/rules-proxy.ts": { + "@typescript-eslint/prefer-nullish-coalescing": { + "count": 7 + }, + "@typescript-eslint/restrict-template-expressions": { + "count": 2 + } + }, + "src/utils/run-build.ts": { + "@typescript-eslint/no-unsafe-assignment": { + "count": 10 + }, + "@typescript-eslint/no-unsafe-member-access": { + "count": 11 + }, + "@typescript-eslint/prefer-nullish-coalescing": { + "count": 1 + } + }, + "src/utils/scripted-commands.ts": { + "@typescript-eslint/no-unnecessary-type-conversion": { + "count": 2 + } + }, + "src/utils/sign-redirect.ts": { + "@typescript-eslint/no-unsafe-argument": { + "count": 1 + }, + "@typescript-eslint/no-unsafe-assignment": { + "count": 3 + } + }, + "src/utils/static-server.ts": { + "@typescript-eslint/no-unsafe-argument": { + "count": 2 + }, + "@typescript-eslint/no-unsafe-assignment": { + "count": 1 + }, + "@typescript-eslint/no-unsafe-member-access": { + "count": 3 + } + }, + "src/utils/telemetry/report-error.ts": { + "@typescript-eslint/no-unsafe-assignment": { + "count": 8 + }, + "@typescript-eslint/no-unsafe-member-access": { + "count": 5 + } + }, + "src/utils/telemetry/request.ts": { + "@typescript-eslint/no-floating-promises": { + "count": 1 + }, + "@typescript-eslint/no-unsafe-assignment": { + "count": 1 + }, + "@typescript-eslint/no-unsafe-member-access": { + "count": 2 + }, + "@typescript-eslint/prefer-nullish-coalescing": { + "count": 3 + }, + "n/no-process-exit": { + "count": 2 + } + }, + "src/utils/telemetry/telemetry.ts": { + "@typescript-eslint/no-unsafe-assignment": { + "count": 7 + } + }, + "src/utils/telemetry/utils.ts": { + "@typescript-eslint/no-unsafe-call": { + "count": 1 + }, + "@typescript-eslint/no-unsafe-member-access": { + "count": 1 + }, + "@typescript-eslint/no-unsafe-return": { + "count": 1 + } + }, + "src/utils/telemetry/validation.ts": { + "@typescript-eslint/no-unsafe-argument": { + "count": 1 + }, + "@typescript-eslint/no-unsafe-assignment": { + "count": 5 + }, + "@typescript-eslint/no-unsafe-call": { + "count": 4 + }, + "@typescript-eslint/no-unsafe-member-access": { + "count": 8 + }, + "@typescript-eslint/prefer-nullish-coalescing": { + "count": 3 + }, + "@typescript-eslint/restrict-template-expressions": { + "count": 7 + } + }, + "src/utils/types.ts": { + "@typescript-eslint/no-redundant-type-constituents": { + "count": 3 + } + }, + "tests/integration/commands/blobs/blobs-delete.test.ts": { + "@typescript-eslint/no-explicit-any": { + "count": 6 + }, + "@typescript-eslint/no-unsafe-assignment": { + "count": 2 + }, + "@typescript-eslint/no-unsafe-call": { + "count": 6 + }, + "@typescript-eslint/no-unsafe-member-access": { + "count": 6 + }, + "no-restricted-imports": { + "count": 1 + } + }, + "tests/integration/commands/blobs/blobs-set.test.ts": { + "@typescript-eslint/no-explicit-any": { + "count": 7 + }, + "@typescript-eslint/no-unsafe-assignment": { + "count": 2 + }, + "@typescript-eslint/no-unsafe-call": { + "count": 7 + }, + "@typescript-eslint/no-unsafe-member-access": { + "count": 7 + }, + "no-restricted-imports": { + "count": 1 + } + }, + "tests/integration/commands/blobs/blobs.test.ts": { + "@typescript-eslint/no-floating-promises": { + "count": 1 + }, + "@typescript-eslint/restrict-template-expressions": { + "count": 1 + } + }, + "tests/integration/commands/build/build-program.test.ts": { + "@typescript-eslint/no-empty-function": { + "count": 1 + }, + "@typescript-eslint/unbound-method": { + "count": 1 + } + }, + "tests/integration/commands/build/build.test.ts": { + "@typescript-eslint/no-floating-promises": { + "count": 2 + }, + "@typescript-eslint/no-unnecessary-condition": { + "count": 1 + }, + "prefer-const": { + "count": 4 + }, + "vitest/expect-expect": { + "count": 14 + } + }, + "tests/integration/commands/deploy/deploy-api-routes.ts": { + "@typescript-eslint/prefer-nullish-coalescing": { + "count": 2 + } + }, + "tests/integration/commands/deploy/deploy-non-interactive.test.ts": { + "@typescript-eslint/prefer-nullish-coalescing": { + "count": 1 + } + }, + "tests/integration/commands/deploy/deploy.test.ts": { + "@typescript-eslint/ban-ts-comment": { + "count": 1 + }, + "@typescript-eslint/no-non-null-assertion": { + "count": 63 + }, + "@typescript-eslint/no-require-imports": { + "count": 5 + }, + "@typescript-eslint/no-unsafe-assignment": { + "count": 8 + }, + "@typescript-eslint/no-unsafe-member-access": { + "count": 4 + }, + "@typescript-eslint/no-unsafe-return": { + "count": 3 + }, + "@typescript-eslint/prefer-nullish-coalescing": { + "count": 7 + }, + "@typescript-eslint/prefer-regexp-exec": { + "count": 9 + }, + "@typescript-eslint/require-await": { + "count": 22 + }, + "@typescript-eslint/restrict-template-expressions": { + "count": 9 + } + }, + "tests/integration/commands/dev/dev-miscellaneous.test.ts": { + "@typescript-eslint/no-deprecated": { + "count": 1 + }, + "@typescript-eslint/no-non-null-assertion": { + "count": 2 + }, + "@typescript-eslint/no-unsafe-assignment": { + "count": 1 + }, + "@typescript-eslint/prefer-regexp-exec": { + "count": 1 + }, + "@typescript-eslint/require-await": { + "count": 15 + }, + "@typescript-eslint/restrict-template-expressions": { + "count": 17 + }, + "@typescript-eslint/unbound-method": { + "count": 2 + } + }, + "tests/integration/commands/dev/dev.test.ts": { + "@typescript-eslint/await-thenable": { + "count": 2 + }, + "@typescript-eslint/no-non-null-assertion": { + "count": 2 + }, + "@typescript-eslint/no-require-imports": { + "count": 1 + }, + "@typescript-eslint/no-unnecessary-type-conversion": { + "count": 1 + }, + "@typescript-eslint/require-await": { + "count": 1 + } + }, + "tests/integration/commands/dev/dev.zisi.test.ts": { + "@typescript-eslint/no-explicit-any": { + "count": 1 + }, + "@typescript-eslint/no-unsafe-argument": { + "count": 1 + }, + "@typescript-eslint/no-unsafe-assignment": { + "count": 1 + }, + "@typescript-eslint/unbound-method": { + "count": 1 + } + }, + "tests/integration/commands/dev/edge-functions.test.ts": { + "@typescript-eslint/no-non-null-assertion": { + "count": 21 + }, + "@typescript-eslint/restrict-template-expressions": { + "count": 19 + } + }, + "tests/integration/commands/dev/functions.test.ts": { + "@typescript-eslint/no-require-imports": { + "count": 1 + }, + "@typescript-eslint/no-unsafe-assignment": { + "count": 1 + }, + "@typescript-eslint/no-unsafe-call": { + "count": 3 + } + }, + "tests/integration/commands/dev/redirects.test.ts": { + "@typescript-eslint/no-non-null-assertion": { + "count": 4 + }, + "@typescript-eslint/no-unnecessary-type-conversion": { + "count": 1 + }, + "@typescript-eslint/restrict-template-expressions": { + "count": 4 + } + }, + "tests/integration/commands/dev/scheduled-functions.test.ts": { + "@typescript-eslint/no-non-null-assertion": { + "count": 3 + }, + "@typescript-eslint/restrict-template-expressions": { + "count": 3 + } + }, + "tests/integration/commands/dev/serve.test.ts": { + "@typescript-eslint/no-floating-promises": { + "count": 1 + }, + "@typescript-eslint/no-require-imports": { + "count": 1 + }, + "@typescript-eslint/no-unsafe-assignment": { + "count": 1 + }, + "@typescript-eslint/no-unsafe-call": { + "count": 2 + }, + "@typescript-eslint/require-await": { + "count": 1 + }, + "@typescript-eslint/restrict-template-expressions": { + "count": 1 + } + }, + "tests/integration/commands/dev/v2-api.test.ts": { + "@typescript-eslint/no-non-null-assertion": { + "count": 30 + }, + "@typescript-eslint/no-unsafe-argument": { + "count": 2 + }, + "@typescript-eslint/restrict-template-expressions": { + "count": 27 + } + }, + "tests/integration/commands/env/env-clone.test.ts": { + "@typescript-eslint/no-unsafe-assignment": { + "count": 1 + } + }, + "tests/integration/commands/env/env-get.test.ts": { + "@typescript-eslint/no-floating-promises": { + "count": 1 + } + }, + "tests/integration/commands/env/env-list.test.ts": { + "@typescript-eslint/no-floating-promises": { + "count": 1 + } + }, + "tests/integration/commands/env/env-set.test.ts": { + "@typescript-eslint/no-unsafe-assignment": { + "count": 1 + }, + "no-restricted-imports": { + "count": 1 + } + }, + "tests/integration/commands/env/env-unset.test.ts": { + "@typescript-eslint/no-unsafe-assignment": { + "count": 1 + } + }, + "tests/integration/commands/env/env.test.ts": { + "@typescript-eslint/no-non-null-assertion": { + "count": 1 + }, + "@typescript-eslint/no-unsafe-assignment": { + "count": 12 + }, + "@typescript-eslint/no-unsafe-return": { + "count": 2 + }, + "@typescript-eslint/use-unknown-in-catch-callback-variable": { + "count": 2 + } + }, + "tests/integration/commands/envelope/envelope.test.ts": { + "@typescript-eslint/no-non-null-assertion": { + "count": 1 + } + }, + "tests/integration/commands/functions-invoke/functions-invoke.test.ts": { + "@typescript-eslint/no-non-null-assertion": { + "count": 7 + } + }, + "tests/integration/commands/logs/functions.test.ts": { + "@typescript-eslint/no-unsafe-call": { + "count": 2 + } + }, + "tests/integration/commands/sites/sites.test.ts": { + "@typescript-eslint/no-empty-function": { + "count": 1 + } + }, + "tests/integration/framework-detection.test.ts": { + "@typescript-eslint/no-empty-function": { + "count": 13 + } + }, + "tests/integration/frameworks/hugo.test.ts": { + "@typescript-eslint/no-floating-promises": { + "count": 1 + }, + "@typescript-eslint/restrict-template-expressions": { + "count": 1 + } + }, + "tests/integration/rules-proxy.test.ts": { + "@typescript-eslint/no-misused-promises": { + "count": 1 + }, + "@typescript-eslint/no-unnecessary-condition": { + "count": 1 + }, + "@typescript-eslint/restrict-template-expressions": { + "count": 1 + } + }, + "tests/integration/telemetry.test.ts": { + "@typescript-eslint/no-non-null-assertion": { + "count": 17 + }, + "@typescript-eslint/no-unsafe-assignment": { + "count": 9 + } + }, + "tests/integration/utils/dev-server.ts": { + "@typescript-eslint/no-explicit-any": { + "count": 3 + }, + "@typescript-eslint/no-non-null-assertion": { + "count": 6 + }, + "@typescript-eslint/no-unsafe-argument": { + "count": 2 + }, + "@typescript-eslint/restrict-template-expressions": { + "count": 3 + } + }, + "tests/integration/utils/fixture.ts": { + "@typescript-eslint/no-explicit-any": { + "count": 2 + }, + "@typescript-eslint/no-non-null-assertion": { + "count": 1 + }, + "@typescript-eslint/no-unnecessary-condition": { + "count": 2 + }, + "@typescript-eslint/no-unsafe-assignment": { + "count": 3 + }, + "@typescript-eslint/no-unsafe-call": { + "count": 1 + }, + "@typescript-eslint/no-unsafe-member-access": { + "count": 2 + }, + "@typescript-eslint/require-await": { + "count": 1 + } + }, + "tests/integration/utils/mock-api-vitest.ts": { + "@typescript-eslint/no-explicit-any": { + "count": 1 + }, + "@typescript-eslint/prefer-nullish-coalescing": { + "count": 1 + } + }, + "tests/integration/utils/mock-api.ts": { + "@typescript-eslint/no-explicit-any": { + "count": 1 + } + }, + "tests/integration/utils/site-builder.ts": { + "@typescript-eslint/no-explicit-any": { + "count": 4 + }, + "@typescript-eslint/no-unsafe-argument": { + "count": 1 + }, + "@typescript-eslint/restrict-template-expressions": { + "count": 2 + } + }, + "tests/unit/commands/clone/clone.test.ts": { + "@typescript-eslint/no-empty-function": { + "count": 2 + } + }, + "tests/unit/lib/completion/generate-autocompletion.test.ts": { + "@typescript-eslint/no-empty-function": { + "count": 1 + } + }, + "tests/unit/lib/functions/registry.test.ts": { + "@typescript-eslint/no-empty-function": { + "count": 5 + } + }, + "tests/unit/lib/functions/server.test.ts": { + "@typescript-eslint/no-empty-function": { + "count": 1 + } + }, + "tests/unit/lib/geo-location.test.ts": { + "@typescript-eslint/no-empty-function": { + "count": 6 + } + }, + "tests/unit/utils/deploy/hash-edge-functions.test.ts": { + "@typescript-eslint/no-empty-function": { + "count": 3 + } + }, + "tests/unit/utils/deploy/hash-files.test.ts": { + "@typescript-eslint/no-empty-function": { + "count": 1 + } + }, + "tests/unit/utils/deploy/hash-fns.test.ts": { + "@typescript-eslint/no-empty-function": { + "count": 4 + } + }, + "tests/unit/utils/deploy/upload-files.test.ts": { + "@typescript-eslint/no-empty-function": { + "count": 1 + }, + "no-empty": { + "count": 1 + } + }, + "tests/unit/utils/deploy/upload-source-zip.test.ts": { + "@typescript-eslint/no-empty-function": { + "count": 7 + } + }, + "tests/unit/utils/headers.test.ts": { + "@typescript-eslint/no-empty-function": { + "count": 1 + } + }, + "tests/unit/utils/init/config-github.test.ts": { + "@typescript-eslint/no-empty-function": { + "count": 1 + } + }, + "tests/unit/utils/rules-proxy-matcher.test.ts": { + "@typescript-eslint/no-empty-function": { + "count": 2 + } + }, + "tests/unit/utils/telemetry/validation.test.ts": { + "@typescript-eslint/no-empty-function": { + "count": 1 + } + }, + "types/ascii-table/index.d.ts": { + "@typescript-eslint/unified-signatures": { + "count": 4 + } + } +} \ No newline at end of file diff --git a/eslint.config.js b/eslint.config.js index 2ea4282c6a7..367745e72ee 100644 --- a/eslint.config.js +++ b/eslint.config.js @@ -8,8 +8,6 @@ import node from 'eslint-plugin-n' import vitest from '@vitest/eslint-plugin' import tseslint from 'typescript-eslint' -import cliTemporarySuppressions from './eslint_temporary_suppressions.js' - const __filename = fileURLToPath(import.meta.url) const __dirname = path.dirname(__filename) @@ -55,7 +53,19 @@ export default tseslint.config( // Project-specific rules { - ignores: ['.github/styles/', '**/__fixtures__/'], + ignores: ['.github/styles/', '**/__fixtures__/', 'functions-templates/**', 'site/**'], + }, + { + rules: { + // We use these globals even though they're technically unstable features on our minimum + // supported node version. + 'n/no-unsupported-features/node-builtins': [ + 'error', + { + ignores: ['FormData', 'ReadableStream', 'Response', 'Request', 'fetch', 'fs/promises.cp'], + }, + ], + }, }, { files: ['**/*.?(c|m)ts?(x)'], @@ -142,8 +152,6 @@ export default tseslint.config( }, }, - ...cliTemporarySuppressions, - // Must be last prettier, ) diff --git a/eslint_temporary_suppressions.js b/eslint_temporary_suppressions.js deleted file mode 100644 index 56200551369..00000000000 --- a/eslint_temporary_suppressions.js +++ /dev/null @@ -1,1421 +0,0 @@ -/* - * XXX: Temporary suppressions - * - * These rules are suppressed because we haven't yet fixed offending code. - * - * Want to help? Remove the suppression, fix any lint errors, and submit a PR. - */ - -/** @type { import("eslint").Linter.Config[] } */ -export default [ - /* Global rule suppressions */ - - { - rules: { - // Empty functions and blocks are useful (e.g `noop() {}`, `catch {}`) but can mask unintentionally omitted - // implementation. We should add explanatory comments like `// intentionally empty` and `// ignore error` in these - // scenarios to communicate intent. - 'no-empty': 'off', - '@typescript-eslint/no-empty-function': 'off', - '@typescript-eslint/prefer-nullish-coalescing': 'off', - - // We use these globals even though they're technically unstable features on our minimum - // supported node version. - 'n/no-unsupported-features/node-builtins': [ - 'error', - { - ignores: ['FormData', 'ReadableStream', 'Response', 'Request', 'fetch', 'fs/promises.cp'], - }, - ], - }, - }, - - /* Per-file rule suppressions */ - - { ignores: ['functions-templates/**'] }, - { ignores: ['site/**'] }, - { - files: ['bin/run.js'], - rules: { - 'n/no-unpublished-bin': 'off', - }, - }, - { - files: ['e2e/install.e2e.ts'], - rules: { - '@typescript-eslint/await-thenable': 'off', - }, - }, - { - files: ['src/commands/api/api.ts'], - rules: { - '@typescript-eslint/no-unsafe-assignment': 'off', - '@typescript-eslint/no-unsafe-argument': 'off', - '@typescript-eslint/restrict-template-expressions': 'off', - }, - }, - { - files: ['src/commands/api/index.ts'], - rules: { - '@typescript-eslint/no-unsafe-argument': 'off', - }, - }, - { - files: ['src/commands/base-command.ts'], - rules: { - '@typescript-eslint/prefer-nullish-coalescing': 'off', - '@typescript-eslint/no-unsafe-assignment': 'off', - '@typescript-eslint/no-unsafe-return': 'off', - '@typescript-eslint/no-unnecessary-condition': 'off', - '@typescript-eslint/restrict-template-expressions': 'off', - '@typescript-eslint/no-explicit-any': 'off', - '@typescript-eslint/no-unsafe-member-access': 'off', - '@typescript-eslint/no-unnecessary-boolean-literal-compare': 'off', - '@typescript-eslint/no-unsafe-call': 'off', - '@typescript-eslint/no-unsafe-argument': 'off', - '@typescript-eslint/no-floating-promises': 'off', - '@typescript-eslint/no-unnecessary-type-parameters': 'off', - }, - }, - { - files: ['src/commands/blobs/blobs-delete.ts'], - rules: { - '@typescript-eslint/no-explicit-any': 'off', - '@typescript-eslint/no-unsafe-assignment': 'off', - '@typescript-eslint/no-unsafe-member-access': 'off', - '@typescript-eslint/restrict-template-expressions': 'off', - }, - }, - { - files: ['src/commands/blobs/blobs-get.ts'], - rules: { - '@typescript-eslint/no-unnecessary-condition': 'off', - }, - }, - { - files: ['src/commands/build/build.ts'], - rules: { - '@typescript-eslint/no-unsafe-assignment': 'off', - }, - }, - { - files: ['src/commands/build/index.ts'], - rules: { - '@typescript-eslint/prefer-nullish-coalescing': 'off', - '@typescript-eslint/no-unsafe-argument': 'off', - }, - }, - { - files: ['src/commands/completion/completion.ts'], - rules: { - '@typescript-eslint/prefer-nullish-coalescing': 'off', - '@typescript-eslint/no-unsafe-assignment': 'off', - }, - }, - { - files: ['src/commands/deploy/deploy.ts'], - rules: { - '@typescript-eslint/no-unsafe-assignment': 'off', - '@typescript-eslint/no-unsafe-call': 'off', - '@typescript-eslint/no-unsafe-member-access': 'off', - '@typescript-eslint/restrict-template-expressions': 'off', - '@typescript-eslint/no-unsafe-argument': 'off', - '@typescript-eslint/prefer-nullish-coalescing': 'off', - '@typescript-eslint/no-unnecessary-condition': 'off', - '@typescript-eslint/no-unsafe-return': 'off', - '@typescript-eslint/no-dynamic-delete': 'off', - '@typescript-eslint/ban-ts-comment': 'off', - }, - }, - { - files: ['src/commands/dev/dev-exec.ts'], - rules: { - '@typescript-eslint/no-unsafe-assignment': 'off', - }, - }, - { - files: ['src/commands/dev/dev.ts'], - rules: { - '@typescript-eslint/no-unsafe-assignment': 'off', - 'n/no-process-exit': 'off', - '@typescript-eslint/prefer-nullish-coalescing': 'off', - '@typescript-eslint/no-unsafe-argument': 'off', - }, - }, - { - files: ['src/commands/env/env-clone.ts'], - rules: { - '@typescript-eslint/no-unsafe-assignment': 'off', - '@typescript-eslint/no-unsafe-call': 'off', - '@typescript-eslint/no-unsafe-member-access': 'off', - '@typescript-eslint/no-unsafe-return': 'off', - '@typescript-eslint/no-unnecessary-boolean-literal-compare': 'off', - '@typescript-eslint/no-unsafe-argument': 'off', - }, - }, - { - files: ['src/commands/env/env-get.ts'], - rules: { - '@typescript-eslint/no-unsafe-assignment': 'off', - '@typescript-eslint/no-unsafe-member-access': 'off', - '@typescript-eslint/no-unsafe-argument': 'off', - }, - }, - { - files: ['src/commands/env/env-import.ts'], - rules: { - '@typescript-eslint/no-unsafe-assignment': 'off', - '@typescript-eslint/no-unsafe-member-access': 'off', - '@typescript-eslint/no-unsafe-argument': 'off', - '@typescript-eslint/no-unsafe-call': 'off', - '@typescript-eslint/no-unsafe-return': 'off', - }, - }, - { - files: ['src/commands/env/env-list.ts'], - rules: { - '@typescript-eslint/no-unsafe-return': 'off', - '@typescript-eslint/no-unsafe-assignment': 'off', - '@typescript-eslint/no-unsafe-argument': 'off', - '@typescript-eslint/no-unsafe-member-access': 'off', - '@typescript-eslint/restrict-template-expressions': 'off', - }, - }, - { - files: ['src/commands/env/env-set.ts'], - rules: { - '@typescript-eslint/no-unsafe-assignment': 'off', - '@typescript-eslint/no-unsafe-member-access': 'off', - '@typescript-eslint/no-unsafe-call': 'off', - '@typescript-eslint/no-unsafe-argument': 'off', - '@typescript-eslint/no-unnecessary-boolean-literal-compare': 'off', - '@typescript-eslint/no-unsafe-return': 'off', - '@typescript-eslint/restrict-template-expressions': 'off', - '@typescript-eslint/no-unnecessary-condition': 'off', - }, - }, - { - files: ['src/commands/env/env-unset.ts'], - rules: { - '@typescript-eslint/no-unsafe-assignment': 'off', - '@typescript-eslint/no-unsafe-member-access': 'off', - '@typescript-eslint/no-unsafe-call': 'off', - '@typescript-eslint/no-unsafe-argument': 'off', - '@typescript-eslint/no-unnecessary-boolean-literal-compare': 'off', - '@typescript-eslint/no-unsafe-return': 'off', - '@typescript-eslint/no-dynamic-delete': 'off', - }, - }, - { - files: ['src/commands/env/env.ts'], - rules: { - '@typescript-eslint/no-unsafe-return': 'off', - }, - }, - { - files: ['src/commands/functions/functions-create.ts'], - rules: { - '@typescript-eslint/no-unsafe-member-access': 'off', - '@typescript-eslint/no-unsafe-return': 'off', - '@typescript-eslint/no-unsafe-assignment': 'off', - '@typescript-eslint/no-unsafe-argument': 'off', - '@typescript-eslint/no-unsafe-call': 'off', - '@typescript-eslint/restrict-plus-operands': 'off', - '@typescript-eslint/no-unnecessary-condition': 'off', - '@typescript-eslint/restrict-template-expressions': 'off', - 'n/no-process-exit': 'off', - '@typescript-eslint/prefer-optional-chain': 'off', - '@typescript-eslint/await-thenable': 'off', - '@typescript-eslint/no-confusing-void-expression': 'off', - '@typescript-eslint/no-floating-promises': 'off', - '@typescript-eslint/no-unnecessary-type-conversion': 'off', - }, - }, - { - files: ['src/commands/functions/functions-invoke.ts'], - rules: { - '@typescript-eslint/no-unsafe-assignment': 'off', - '@typescript-eslint/no-unsafe-argument': 'off', - '@typescript-eslint/no-unsafe-return': 'off', - '@typescript-eslint/restrict-template-expressions': 'off', - '@typescript-eslint/no-unsafe-call': 'off', - '@typescript-eslint/no-unsafe-member-access': 'off', - '@typescript-eslint/no-unnecessary-condition': 'off', - }, - }, - { - files: ['src/commands/functions/functions-serve.ts'], - rules: { - '@typescript-eslint/no-unsafe-assignment': 'off', - '@typescript-eslint/no-unnecessary-condition': 'off', - }, - }, - { - files: ['src/commands/init/init.ts'], - rules: { - '@typescript-eslint/no-unsafe-assignment': 'off', - }, - }, - { - files: ['src/commands/link/link.ts'], - rules: { - '@typescript-eslint/no-unsafe-assignment': 'off', - '@typescript-eslint/restrict-template-expressions': 'off', - '@typescript-eslint/no-unnecessary-condition': 'off', - '@typescript-eslint/no-unsafe-member-access': 'off', - '@typescript-eslint/no-unsafe-return': 'off', - '@typescript-eslint/prefer-nullish-coalescing': 'off', - '@typescript-eslint/prefer-optional-chain': 'off', - }, - }, - { - files: ['src/commands/logs/build.ts'], - rules: { - '@typescript-eslint/no-explicit-any': 'off', - '@typescript-eslint/no-unsafe-member-access': 'off', - '@typescript-eslint/no-unsafe-assignment': 'off', - '@typescript-eslint/restrict-template-expressions': 'off', - '@typescript-eslint/no-unsafe-call': 'off', - '@typescript-eslint/prefer-nullish-coalescing': 'off', - '@typescript-eslint/no-unsafe-argument': 'off', - }, - }, - { - files: ['src/commands/logs/functions.ts'], - rules: { - '@typescript-eslint/no-unsafe-call': 'off', - '@typescript-eslint/no-unsafe-member-access': 'off', - '@typescript-eslint/restrict-template-expressions': 'off', - '@typescript-eslint/no-unsafe-assignment': 'off', - '@typescript-eslint/no-non-null-assertion': 'off', - '@typescript-eslint/no-explicit-any': 'off', - '@typescript-eslint/no-unsafe-return': 'off', - '@typescript-eslint/no-unsafe-argument': 'off', - }, - }, - { - files: ['src/commands/logs/index.ts'], - rules: { - '@typescript-eslint/restrict-template-expressions': 'off', - }, - }, - { - files: ['src/commands/main.ts'], - rules: { - '@typescript-eslint/no-misused-promises': 'off', - '@typescript-eslint/no-unnecessary-condition': 'off', - '@typescript-eslint/restrict-template-expressions': 'off', - '@typescript-eslint/prefer-nullish-coalescing': 'off', - '@typescript-eslint/no-floating-promises': 'off', - 'n/no-process-exit': 'off', - '@typescript-eslint/no-unsafe-member-access': 'off', - '@typescript-eslint/no-unsafe-call': 'off', - '@typescript-eslint/no-unsafe-assignment': 'off', - '@typescript-eslint/no-unsafe-return': 'off', - '@typescript-eslint/no-unsafe-argument': 'off', - }, - }, - { - files: ['src/commands/recipes/common.ts'], - rules: { - '@typescript-eslint/no-unsafe-argument': 'off', - '@typescript-eslint/no-unsafe-assignment': 'off', - '@typescript-eslint/no-unsafe-return': 'off', - }, - }, - { - files: ['src/commands/recipes/recipes-list.ts'], - rules: { - '@typescript-eslint/no-unsafe-argument': 'off', - }, - }, - { - files: ['src/commands/recipes/recipes.ts'], - rules: { - '@typescript-eslint/no-unsafe-assignment': 'off', - '@typescript-eslint/no-unsafe-return': 'off', - '@typescript-eslint/no-unsafe-call': 'off', - '@typescript-eslint/no-unsafe-member-access': 'off', - '@typescript-eslint/no-explicit-any': 'off', - '@typescript-eslint/no-floating-promises': 'off', - }, - }, - { - files: ['src/commands/serve/serve.ts'], - rules: { - '@typescript-eslint/no-unsafe-assignment': 'off', - '@typescript-eslint/no-unsafe-argument': 'off', - }, - }, - { - files: ['src/commands/sites/sites-create-template.ts'], - rules: { - '@typescript-eslint/no-unsafe-assignment': 'off', - '@typescript-eslint/return-await': 'off', - '@typescript-eslint/no-unsafe-argument': 'off', - '@typescript-eslint/prefer-optional-chain': 'off', - '@typescript-eslint/restrict-plus-operands': 'off', - '@typescript-eslint/restrict-template-expressions': 'off', - '@typescript-eslint/no-floating-promises': 'off', - }, - }, - { - files: ['src/commands/sites/sites-create.ts'], - rules: { - '@typescript-eslint/no-unsafe-assignment': 'off', - '@typescript-eslint/no-unsafe-argument': 'off', - '@typescript-eslint/restrict-template-expressions': 'off', - '@typescript-eslint/no-floating-promises': 'off', - }, - }, - { - files: ['src/commands/sites/sites-delete.ts'], - rules: { - '@typescript-eslint/no-unsafe-argument': 'off', - '@typescript-eslint/no-unsafe-assignment': 'off', - '@typescript-eslint/restrict-template-expressions': 'off', - }, - }, - { - files: ['src/commands/sites/sites-list.ts'], - rules: { - '@typescript-eslint/no-unnecessary-condition': 'off', - '@typescript-eslint/prefer-optional-chain': 'off', - '@typescript-eslint/restrict-template-expressions': 'off', - }, - }, - { - files: ['src/commands/sites/sites.ts'], - rules: { - '@typescript-eslint/restrict-template-expressions': 'off', - '@typescript-eslint/no-unsafe-return': 'off', - }, - }, - { - files: ['src/commands/status/status-hooks.ts'], - rules: { - '@typescript-eslint/no-unsafe-member-access': 'off', - }, - }, - { - files: ['src/commands/switch/switch.ts'], - rules: { - '@typescript-eslint/no-unsafe-argument': 'off', - '@typescript-eslint/no-unsafe-assignment': 'off', - '@typescript-eslint/restrict-template-expressions': 'off', - }, - }, - { - files: ['src/commands/types.d.ts'], - rules: { - '@typescript-eslint/related-getter-setter-pairs': 'off', - }, - }, - { - files: ['src/commands/unlink/unlink.ts'], - rules: { - '@typescript-eslint/no-unnecessary-condition': 'off', - '@typescript-eslint/prefer-optional-chain': 'off', - }, - }, - { - files: ['src/commands/watch/watch.ts'], - rules: { - '@typescript-eslint/no-unnecessary-condition': 'off', - '@typescript-eslint/prefer-nullish-coalescing': 'off', - }, - }, - { - files: ['src/lib/account.ts'], - rules: { - '@typescript-eslint/no-unsafe-member-access': 'off', - }, - }, - { - files: ['src/lib/blobs/blobs.ts'], - rules: { - '@typescript-eslint/restrict-template-expressions': 'off', - }, - }, - { - files: ['src/lib/build.ts'], - rules: { - '@typescript-eslint/no-explicit-any': 'off', - '@typescript-eslint/no-unsafe-assignment': 'off', - }, - }, - { - files: ['src/lib/completion/generate-autocompletion.ts'], - rules: { - '@typescript-eslint/no-unsafe-assignment': 'off', - '@typescript-eslint/no-unsafe-call': 'off', - '@typescript-eslint/no-unsafe-member-access': 'off', - '@typescript-eslint/no-unsafe-return': 'off', - '@typescript-eslint/restrict-template-expressions': 'off', - }, - }, - { - files: ['src/lib/completion/get-autocompletion.ts'], - rules: { - '@typescript-eslint/no-unsafe-member-access': 'off', - '@typescript-eslint/no-unsafe-argument': 'off', - '@typescript-eslint/no-unsafe-assignment': 'off', - '@typescript-eslint/no-unsafe-return': 'off', - '@typescript-eslint/no-unsafe-call': 'off', - }, - }, - { - files: ['src/lib/completion/script.ts'], - rules: { - 'n/hashbang': 'off', - '@typescript-eslint/no-unsafe-assignment': 'off', - '@typescript-eslint/no-unsafe-member-access': 'off', - '@typescript-eslint/no-unsafe-argument': 'off', - }, - }, - { - files: ['src/lib/edge-functions/deploy.ts'], - rules: { - '@typescript-eslint/no-unsafe-member-access': 'off', - '@typescript-eslint/no-unsafe-assignment': 'off', - '@typescript-eslint/restrict-template-expressions': 'off', - '@typescript-eslint/no-unsafe-return': 'off', - }, - }, - { - files: ['src/lib/edge-functions/editor-helper.ts'], - rules: { - '@typescript-eslint/no-unsafe-call': 'off', - '@typescript-eslint/no-unsafe-member-access': 'off', - '@typescript-eslint/no-unsafe-assignment': 'off', - '@typescript-eslint/restrict-template-expressions': 'off', - }, - }, - { - files: ['src/lib/edge-functions/headers.ts'], - rules: { - '@typescript-eslint/no-unsafe-assignment': 'off', - '@typescript-eslint/no-unsafe-call': 'off', - '@typescript-eslint/no-unsafe-member-access': 'off', - '@typescript-eslint/no-unsafe-return': 'off', - }, - }, - { - files: ['src/lib/edge-functions/proxy.ts'], - rules: { - '@typescript-eslint/no-unnecessary-condition': 'off', - '@typescript-eslint/no-unsafe-argument': 'off', - '@typescript-eslint/no-unsafe-assignment': 'off', - '@typescript-eslint/restrict-template-expressions': 'off', - '@typescript-eslint/no-unsafe-call': 'off', - '@typescript-eslint/no-unsafe-member-access': 'off', - '@typescript-eslint/no-non-null-assertion': 'off', - }, - }, - { - files: ['src/lib/edge-functions/registry.ts'], - rules: { - '@typescript-eslint/no-unnecessary-condition': 'off', - '@typescript-eslint/no-unsafe-assignment': 'off', - '@typescript-eslint/no-floating-promises': 'off', - '@typescript-eslint/no-unsafe-member-access': 'off', - '@typescript-eslint/no-unsafe-return': 'off', - '@typescript-eslint/restrict-template-expressions': 'off', - '@typescript-eslint/prefer-nullish-coalescing': 'off', - '@typescript-eslint/no-unsafe-argument': 'off', - '@typescript-eslint/no-misused-promises': 'off', - }, - }, - { - files: ['src/lib/exec-fetcher.ts'], - rules: { - '@typescript-eslint/prefer-regexp-exec': 'off', - '@typescript-eslint/no-unnecessary-condition': 'off', - }, - }, - { - files: ['src/lib/functions/form-submissions-handler.ts'], - rules: { - '@typescript-eslint/no-misused-promises': 'off', - '@typescript-eslint/no-unsafe-assignment': 'off', - '@typescript-eslint/no-unsafe-member-access': 'off', - '@typescript-eslint/no-deprecated': 'off', - '@typescript-eslint/no-unnecessary-type-conversion': 'off', - }, - }, - { - files: ['src/lib/functions/netlify-function.ts'], - rules: { - '@typescript-eslint/no-unsafe-assignment': 'off', - '@typescript-eslint/no-unnecessary-condition': 'off', - '@typescript-eslint/restrict-template-expressions': 'off', - }, - }, - { - files: ['src/lib/functions/registry.ts'], - rules: { - '@typescript-eslint/no-unnecessary-condition': 'off', - '@typescript-eslint/no-floating-promises': 'off', - '@typescript-eslint/prefer-regexp-exec': 'off', - '@typescript-eslint/no-non-null-assertion': 'off', - '@typescript-eslint/no-unnecessary-type-conversion': 'off', - }, - }, - { - files: ['src/lib/functions/server.ts'], - rules: { - '@typescript-eslint/no-misused-promises': 'off', - '@typescript-eslint/no-dynamic-delete': 'off', - '@typescript-eslint/no-unsafe-assignment': 'off', - '@typescript-eslint/no-unsafe-call': 'off', - '@typescript-eslint/no-unsafe-member-access': 'off', - '@typescript-eslint/prefer-nullish-coalescing': 'off', - '@typescript-eslint/no-deprecated': 'off', - '@typescript-eslint/no-unnecessary-condition': 'off', - }, - }, - { - files: ['src/lib/geo-location.ts'], - rules: { - '@typescript-eslint/no-unsafe-assignment': 'off', - '@typescript-eslint/no-unsafe-call': 'off', - '@typescript-eslint/no-unsafe-member-access': 'off', - '@typescript-eslint/no-unsafe-return': 'off', - }, - }, - { - files: ['src/lib/http-agent.ts'], - rules: { - '@typescript-eslint/no-unsafe-call': 'off', - '@typescript-eslint/no-unsafe-assignment': 'off', - '@typescript-eslint/no-unsafe-member-access': 'off', - '@typescript-eslint/no-unsafe-return': 'off', - '@typescript-eslint/no-unsafe-argument': 'off', - '@typescript-eslint/restrict-template-expressions': 'off', - }, - }, - { - files: ['src/lib/images/proxy.ts'], - rules: { - '@typescript-eslint/no-unnecessary-condition': 'off', - '@typescript-eslint/prefer-nullish-coalescing': 'off', - '@typescript-eslint/restrict-template-expressions': 'off', - }, - }, - { - files: ['src/lib/render-error-template.ts'], - rules: { - '@typescript-eslint/no-unsafe-assignment': 'off', - '@typescript-eslint/no-unsafe-argument': 'off', - '@typescript-eslint/no-unsafe-return': 'off', - '@typescript-eslint/no-unsafe-call': 'off', - '@typescript-eslint/no-unsafe-member-access': 'off', - }, - }, - { - files: ['src/lib/spinner.ts'], - rules: { - '@typescript-eslint/no-unnecessary-condition': 'off', - }, - }, - { - files: ['src/lib/string.ts'], - rules: { - '@typescript-eslint/no-unsafe-return': 'off', - '@typescript-eslint/no-unsafe-call': 'off', - '@typescript-eslint/no-unsafe-member-access': 'off', - }, - }, - { - files: ['src/recipes/ai-context/context.ts'], - rules: { - '@typescript-eslint/prefer-regexp-exec': 'off', - }, - }, - { - files: ['src/recipes/ai-context/index.ts'], - rules: { - '@typescript-eslint/no-unsafe-assignment': 'off', - '@typescript-eslint/no-unsafe-return': 'off', - '@typescript-eslint/no-unnecessary-condition': 'off', - }, - }, - { - files: ['src/recipes/blobs-migrate/index.ts'], - rules: { - '@typescript-eslint/no-unsafe-assignment': 'off', - '@typescript-eslint/restrict-template-expressions': 'off', - }, - }, - { - files: ['src/recipes/vscode/index.ts'], - rules: { - '@typescript-eslint/no-unsafe-return': 'off', - '@typescript-eslint/no-unsafe-member-access': 'off', - '@typescript-eslint/no-unsafe-argument': 'off', - '@typescript-eslint/no-unsafe-assignment': 'off', - '@typescript-eslint/no-floating-promises': 'off', - }, - }, - { - files: ['src/recipes/vscode/settings.ts'], - rules: { - '@typescript-eslint/no-unsafe-argument': 'off', - '@typescript-eslint/no-unsafe-assignment': 'off', - '@typescript-eslint/no-unsafe-member-access': 'off', - '@typescript-eslint/no-unsafe-call': 'off', - '@typescript-eslint/no-unsafe-return': 'off', - '@typescript-eslint/restrict-template-expressions': 'off', - }, - }, - { - files: ['src/utils/addons/prepare.ts'], - rules: { - '@typescript-eslint/no-unsafe-return': 'off', - '@typescript-eslint/no-unsafe-call': 'off', - '@typescript-eslint/no-unsafe-member-access': 'off', - '@typescript-eslint/no-unsafe-assignment': 'off', - }, - }, - { - files: ['src/utils/build-info.ts'], - rules: { - '@typescript-eslint/restrict-template-expressions': 'off', - '@typescript-eslint/no-unnecessary-condition': 'off', - }, - }, - { - files: ['src/utils/cli-state.ts'], - rules: { - '@typescript-eslint/no-unsafe-return': 'off', - '@typescript-eslint/restrict-template-expressions': 'off', - '@typescript-eslint/no-unsafe-argument': 'off', - '@typescript-eslint/no-unsafe-assignment': 'off', - }, - }, - { - files: ['src/utils/command-helpers.ts'], - rules: { - 'no-restricted-imports': 'off', - '@typescript-eslint/no-unsafe-return': 'off', - '@typescript-eslint/no-unsafe-call': 'off', - '@typescript-eslint/no-unsafe-member-access': 'off', - '@typescript-eslint/restrict-plus-operands': 'off', - '@typescript-eslint/no-unsafe-argument': 'off', - '@typescript-eslint/no-unsafe-assignment': 'off', - '@typescript-eslint/restrict-template-expressions': 'off', - 'n/no-process-exit': 'off', - '@typescript-eslint/ban-ts-comment': 'off', - }, - }, - { - files: ['src/utils/copy-template-dir/copy-template-dir.ts'], - rules: { - '@typescript-eslint/prefer-nullish-coalescing': 'off', - '@typescript-eslint/no-unsafe-argument': 'off', - '@typescript-eslint/no-unsafe-call': 'off', - '@typescript-eslint/no-unsafe-assignment': 'off', - '@typescript-eslint/no-explicit-any': 'off', - '@typescript-eslint/no-misused-promises': 'off', - '@typescript-eslint/prefer-promise-reject-errors': 'off', - }, - }, - { - files: ['src/utils/create-stream-promise.ts'], - rules: { - '@typescript-eslint/no-unnecessary-condition': 'off', - '@typescript-eslint/restrict-plus-operands': 'off', - '@typescript-eslint/no-unsafe-member-access': 'off', - }, - }, - { - files: ['src/utils/deploy/deploy-site.ts'], - rules: { - '@typescript-eslint/restrict-template-expressions': 'off', - '@typescript-eslint/no-unsafe-assignment': 'off', - '@typescript-eslint/no-unsafe-argument': 'off', - '@typescript-eslint/no-unsafe-member-access': 'off', - '@typescript-eslint/no-unsafe-call': 'off', - '@typescript-eslint/no-confusing-void-expression': 'off', - '@typescript-eslint/await-thenable': 'off', - }, - }, - { - files: ['src/utils/deploy/hash-config.ts'], - rules: { - '@typescript-eslint/no-unused-vars': 'off', - }, - }, - { - files: ['src/utils/deploy/hash-files.ts'], - rules: { - '@typescript-eslint/no-unsafe-argument': 'off', - '@typescript-eslint/no-unsafe-assignment': 'off', - '@typescript-eslint/no-unsafe-call': 'off', - }, - }, - { - files: ['src/utils/deploy/hash-fns.ts'], - rules: { - '@typescript-eslint/no-unsafe-call': 'off', - '@typescript-eslint/no-unsafe-assignment': 'off', - '@typescript-eslint/no-unsafe-argument': 'off', - '@typescript-eslint/no-unsafe-return': 'off', - '@typescript-eslint/no-unnecessary-condition': 'off', - '@typescript-eslint/prefer-nullish-coalescing': 'off', - '@typescript-eslint/no-unsafe-member-access': 'off', - }, - }, - { - files: ['src/utils/deploy/hasher-segments.ts'], - rules: { - '@typescript-eslint/no-unsafe-argument': 'off', - '@typescript-eslint/no-misused-promises': 'off', - '@typescript-eslint/no-unsafe-member-access': 'off', - '@typescript-eslint/no-unsafe-assignment': 'off', - '@typescript-eslint/no-unsafe-return': 'off', - '@typescript-eslint/no-unsafe-call': 'off', - '@typescript-eslint/restrict-template-expressions': 'off', - }, - }, - { - files: ['src/utils/deploy/upload-files.ts'], - rules: { - '@typescript-eslint/no-unsafe-call': 'off', - '@typescript-eslint/restrict-template-expressions': 'off', - '@typescript-eslint/no-unsafe-member-access': 'off', - '@typescript-eslint/no-unsafe-assignment': 'off', - '@typescript-eslint/no-unsafe-return': 'off', - '@typescript-eslint/no-unsafe-argument': 'off', - '@typescript-eslint/prefer-promise-reject-errors': 'off', - '@typescript-eslint/no-floating-promises': 'off', - }, - }, - { - files: ['src/utils/deploy/util.ts'], - rules: { - '@typescript-eslint/no-unsafe-call': 'off', - '@typescript-eslint/no-unsafe-member-access': 'off', - '@typescript-eslint/restrict-template-expressions': 'off', - '@typescript-eslint/no-unsafe-return': 'off', - '@typescript-eslint/no-unsafe-assignment': 'off', - '@typescript-eslint/no-unsafe-argument': 'off', - }, - }, - { - files: ['src/utils/detect-server-settings.ts'], - rules: { - '@typescript-eslint/restrict-template-expressions': 'off', - '@typescript-eslint/no-unsafe-assignment': 'off', - '@typescript-eslint/no-unsafe-argument': 'off', - '@typescript-eslint/prefer-nullish-coalescing': 'off', - '@typescript-eslint/no-unsafe-member-access': 'off', - '@typescript-eslint/no-unsafe-return': 'off', - }, - }, - { - files: ['src/utils/dev.ts'], - rules: { - '@typescript-eslint/no-unsafe-member-access': 'off', - '@typescript-eslint/no-unsafe-assignment': 'off', - '@typescript-eslint/no-unsafe-call': 'off', - '@typescript-eslint/no-unsafe-return': 'off', - '@typescript-eslint/no-unsafe-argument': 'off', - '@typescript-eslint/restrict-template-expressions': 'off', - '@typescript-eslint/prefer-nullish-coalescing': 'off', - }, - }, - { - files: ['src/utils/dot-env.ts'], - rules: { - '@typescript-eslint/no-unsafe-assignment': 'off', - '@typescript-eslint/no-unsafe-argument': 'off', - '@typescript-eslint/restrict-template-expressions': 'off', - }, - }, - { - files: ['src/utils/env/index.ts'], - rules: { - '@typescript-eslint/no-unsafe-return': 'off', - '@typescript-eslint/no-unsafe-assignment': 'off', - '@typescript-eslint/no-unsafe-call': 'off', - '@typescript-eslint/no-unsafe-member-access': 'off', - '@typescript-eslint/no-unsafe-argument': 'off', - '@typescript-eslint/restrict-template-expressions': 'off', - '@typescript-eslint/no-unnecessary-condition': 'off', - '@typescript-eslint/prefer-optional-chain': 'off', - }, - }, - { - files: ['src/utils/execa.ts'], - rules: { - '@typescript-eslint/no-unsafe-assignment': 'off', - '@typescript-eslint/no-unsafe-member-access': 'off', - }, - }, - { - files: ['src/utils/framework-server.ts'], - rules: { - '@typescript-eslint/no-floating-promises': 'off', - '@typescript-eslint/prefer-nullish-coalescing': 'off', - '@typescript-eslint/restrict-template-expressions': 'off', - }, - }, - { - files: ['src/utils/frameworks-api.ts'], - rules: { - '@typescript-eslint/prefer-nullish-coalescing': 'off', - '@typescript-eslint/no-unsafe-assignment': 'off', - }, - }, - { - files: ['src/utils/functions/functions.ts'], - rules: { - '@typescript-eslint/no-unsafe-return': 'off', - }, - }, - { - files: ['src/utils/functions/get-functions.ts'], - rules: { - '@typescript-eslint/restrict-template-expressions': 'off', - '@typescript-eslint/no-unsafe-assignment': 'off', - '@typescript-eslint/no-unsafe-call': 'off', - '@typescript-eslint/no-unsafe-member-access': 'off', - '@typescript-eslint/no-unsafe-argument': 'off', - }, - }, - { - files: ['src/utils/get-global-config-store.ts'], - rules: { - '@typescript-eslint/no-deprecated': 'off', - '@typescript-eslint/no-unsafe-assignment': 'off', - }, - }, - { - files: ['src/utils/get-repo-data.ts'], - rules: { - '@typescript-eslint/prefer-optional-chain': 'off', - '@typescript-eslint/no-unnecessary-condition': 'off', - '@typescript-eslint/no-unsafe-argument': 'off', - '@typescript-eslint/prefer-nullish-coalescing': 'off', - '@typescript-eslint/no-unsafe-member-access': 'off', - '@typescript-eslint/no-unsafe-assignment': 'off', - '@typescript-eslint/restrict-template-expressions': 'off', - }, - }, - { - files: ['src/utils/gitignore.ts'], - rules: { - '@typescript-eslint/prefer-optional-chain': 'off', - '@typescript-eslint/restrict-template-expressions': 'off', - }, - }, - { - files: ['src/utils/headers.ts'], - rules: { - '@typescript-eslint/no-unsafe-assignment': 'off', - '@typescript-eslint/no-unsafe-return': 'off', - }, - }, - { - files: ['src/utils/init/config-github.ts'], - rules: { - '@typescript-eslint/no-unsafe-assignment': 'off', - '@typescript-eslint/prefer-optional-chain': 'off', - '@typescript-eslint/no-unnecessary-condition': 'off', - '@typescript-eslint/no-unsafe-call': 'off', - '@typescript-eslint/no-unsafe-member-access': 'off', - '@typescript-eslint/no-unsafe-return': 'off', - }, - }, - { - files: ['src/utils/init/config.ts'], - rules: { - '@typescript-eslint/restrict-template-expressions': 'off', - }, - }, - { - files: ['src/utils/init/utils.ts'], - rules: { - '@typescript-eslint/prefer-nullish-coalescing': 'off', - '@typescript-eslint/ban-ts-comment': 'off', - '@typescript-eslint/no-unsafe-argument': 'off', - '@typescript-eslint/no-unsafe-assignment': 'off', - '@typescript-eslint/restrict-template-expressions': 'off', - '@typescript-eslint/no-unsafe-member-access': 'off', - }, - }, - { - files: ['src/utils/parse-raw-flags.ts'], - rules: { - '@typescript-eslint/no-unsafe-assignment': 'off', - '@typescript-eslint/no-unsafe-call': 'off', - '@typescript-eslint/no-unsafe-member-access': 'off', - '@typescript-eslint/no-unsafe-argument': 'off', - '@typescript-eslint/restrict-plus-operands': 'off', - '@typescript-eslint/no-unsafe-return': 'off', - '@typescript-eslint/restrict-template-expressions': 'off', - }, - }, - { - files: ['src/utils/prompts/confirm-prompt.ts'], - rules: { - '@typescript-eslint/no-unsafe-assignment': 'off', - }, - }, - { - files: ['src/utils/proxy-server.ts'], - rules: { - '@typescript-eslint/prefer-nullish-coalescing': 'off', - '@typescript-eslint/no-unsafe-member-access': 'off', - '@typescript-eslint/restrict-template-expressions': 'off', - }, - }, - { - files: ['src/utils/proxy.ts'], - rules: { - '@typescript-eslint/no-unnecessary-condition': 'off', - '@typescript-eslint/no-unsafe-assignment': 'off', - '@typescript-eslint/restrict-template-expressions': 'off', - '@typescript-eslint/no-unsafe-call': 'off', - '@typescript-eslint/no-unsafe-member-access': 'off', - '@typescript-eslint/no-unused-vars': 'off', - '@typescript-eslint/no-unsafe-argument': 'off', - '@typescript-eslint/no-unsafe-return': 'off', - '@typescript-eslint/prefer-optional-chain': 'off', - '@typescript-eslint/no-deprecated': 'off', - '@typescript-eslint/no-misused-promises': 'off', - '@typescript-eslint/prefer-nullish-coalescing': 'off', - '@typescript-eslint/no-explicit-any': 'off', - }, - }, - { - files: ['src/utils/read-repo-url.ts'], - rules: { - '@typescript-eslint/no-deprecated': 'off', - '@typescript-eslint/no-unsafe-argument': 'off', - '@typescript-eslint/no-unsafe-assignment': 'off', - '@typescript-eslint/restrict-template-expressions': 'off', - '@typescript-eslint/no-unsafe-call': 'off', - '@typescript-eslint/no-unsafe-member-access': 'off', - '@typescript-eslint/no-unsafe-return': 'off', - }, - }, - { - files: ['src/utils/redirects.ts'], - rules: { - '@typescript-eslint/no-unsafe-assignment': 'off', - '@typescript-eslint/no-unsafe-member-access': 'off', - '@typescript-eslint/no-unsafe-return': 'off', - '@typescript-eslint/no-unsafe-call': 'off', - '@typescript-eslint/restrict-template-expressions': 'off', - }, - }, - { - files: ['src/utils/rules-proxy.ts'], - rules: { - '@typescript-eslint/no-unsafe-member-access': 'off', - '@typescript-eslint/no-unsafe-return': 'off', - '@typescript-eslint/no-unsafe-call': 'off', - '@typescript-eslint/prefer-nullish-coalescing': 'off', - '@typescript-eslint/restrict-template-expressions': 'off', - '@typescript-eslint/no-unsafe-assignment': 'off', - }, - }, - { - files: ['src/utils/run-build.ts'], - rules: { - '@typescript-eslint/no-unsafe-assignment': 'off', - '@typescript-eslint/no-unsafe-member-access': 'off', - '@typescript-eslint/prefer-nullish-coalescing': 'off', - }, - }, - { - files: ['src/utils/scripted-commands.ts'], - rules: { - '@typescript-eslint/no-unnecessary-type-conversion': 'off', - }, - }, - { - files: ['src/utils/sign-redirect.ts'], - rules: { - '@typescript-eslint/no-unsafe-assignment': 'off', - '@typescript-eslint/no-unsafe-argument': 'off', - }, - }, - { - files: ['src/utils/sites/create-template.ts'], - rules: { - '@typescript-eslint/prefer-nullish-coalescing': 'off', - '@typescript-eslint/no-unsafe-argument': 'off', - '@typescript-eslint/no-unsafe-assignment': 'off', - '@typescript-eslint/no-unsafe-return': 'off', - }, - }, - { - files: ['src/utils/static-server.ts'], - rules: { - '@typescript-eslint/no-unsafe-argument': 'off', - '@typescript-eslint/no-unsafe-member-access': 'off', - '@typescript-eslint/no-unsafe-assignment': 'off', - }, - }, - { - files: ['src/utils/telemetry/report-error.ts'], - rules: { - '@typescript-eslint/no-unsafe-assignment': 'off', - '@typescript-eslint/no-unsafe-member-access': 'off', - }, - }, - { - files: ['src/utils/telemetry/request.ts'], - rules: { - '@typescript-eslint/no-unsafe-assignment': 'off', - '@typescript-eslint/prefer-nullish-coalescing': 'off', - '@typescript-eslint/no-unsafe-member-access': 'off', - 'n/no-process-exit': 'off', - '@typescript-eslint/no-floating-promises': 'off', - }, - }, - { - files: ['src/utils/telemetry/telemetry.ts'], - rules: { - '@typescript-eslint/no-unsafe-assignment': 'off', - }, - }, - { - files: ['src/utils/telemetry/utils.ts'], - rules: { - '@typescript-eslint/no-unsafe-return': 'off', - '@typescript-eslint/no-unsafe-call': 'off', - '@typescript-eslint/no-unsafe-member-access': 'off', - }, - }, - { - files: ['src/utils/telemetry/validation.ts'], - rules: { - '@typescript-eslint/no-unsafe-member-access': 'off', - '@typescript-eslint/no-unsafe-assignment': 'off', - '@typescript-eslint/no-unsafe-call': 'off', - '@typescript-eslint/restrict-template-expressions': 'off', - '@typescript-eslint/no-unsafe-argument': 'off', - }, - }, - { - files: ['src/utils/types.ts'], - rules: { - '@typescript-eslint/no-redundant-type-constituents': 'off', - }, - }, - { - files: ['src/utils/validation.ts'], - rules: { - '@typescript-eslint/no-unsafe-argument': 'off', - '@typescript-eslint/restrict-template-expressions': 'off', - '@typescript-eslint/no-unsafe-return': 'off', - '@typescript-eslint/no-unsafe-call': 'off', - '@typescript-eslint/no-unsafe-member-access': 'off', - }, - }, - { - files: ['tests/integration/commands/blobs/blobs-delete.test.ts'], - rules: { - 'no-restricted-imports': 'off', - '@typescript-eslint/no-unsafe-call': 'off', - '@typescript-eslint/no-explicit-any': 'off', - '@typescript-eslint/no-unsafe-member-access': 'off', - '@typescript-eslint/no-unsafe-assignment': 'off', - }, - }, - { - files: ['tests/integration/commands/blobs/blobs-set.test.ts'], - rules: { - 'no-restricted-imports': 'off', - '@typescript-eslint/no-unsafe-call': 'off', - '@typescript-eslint/no-explicit-any': 'off', - '@typescript-eslint/no-unsafe-member-access': 'off', - '@typescript-eslint/no-unsafe-assignment': 'off', - }, - }, - { - files: ['tests/integration/commands/blobs/blobs.test.ts'], - rules: { - '@typescript-eslint/restrict-template-expressions': 'off', - '@typescript-eslint/no-floating-promises': 'off', - }, - }, - { - files: ['tests/integration/commands/build/build-program.test.ts'], - rules: { - '@typescript-eslint/unbound-method': 'off', - }, - }, - { - files: ['tests/integration/commands/build/build.test.ts'], - rules: { - 'prefer-const': 'off', - 'vitest/expect-expect': 'off', - '@typescript-eslint/no-unnecessary-condition': 'off', - '@typescript-eslint/no-floating-promises': 'off', - }, - }, - { - files: ['tests/integration/commands/deploy/deploy.test.ts'], - rules: { - '@typescript-eslint/no-unsafe-assignment': 'off', - 'vitest/expect-expect': 'off', - '@typescript-eslint/no-unsafe-return': 'off', - '@typescript-eslint/require-await': 'off', - '@typescript-eslint/no-require-imports': 'off', - '@typescript-eslint/no-unsafe-member-access': 'off', - '@typescript-eslint/restrict-template-expressions': 'off', - '@typescript-eslint/prefer-regexp-exec': 'off', - '@typescript-eslint/ban-ts-comment': 'off', - '@typescript-eslint/no-non-null-assertion': 'off', - '@typescript-eslint/no-floating-promises': 'off', - }, - }, - { - files: ['tests/integration/commands/dev/dev-miscellaneous.test.ts'], - rules: { - '@typescript-eslint/no-unsafe-assignment': 'off', - '@typescript-eslint/no-non-null-assertion': 'off', - '@typescript-eslint/prefer-regexp-exec': 'off', - '@typescript-eslint/no-deprecated': 'off', - '@typescript-eslint/require-await': 'off', - '@typescript-eslint/restrict-template-expressions': 'off', - '@typescript-eslint/unbound-method': 'off', - }, - }, - { - files: ['tests/integration/commands/dev/dev.test.ts'], - rules: { - '@typescript-eslint/no-non-null-assertion': 'off', - '@typescript-eslint/no-require-imports': 'off', - '@typescript-eslint/require-await': 'off', - '@typescript-eslint/no-unnecessary-type-conversion': 'off', - '@typescript-eslint/await-thenable': 'off', - }, - }, - { - files: ['tests/integration/commands/dev/dev.zisi.test.ts'], - rules: { - '@typescript-eslint/unbound-method': 'off', - '@typescript-eslint/no-unsafe-assignment': 'off', - '@typescript-eslint/no-unsafe-argument': 'off', - '@typescript-eslint/no-explicit-any': 'off', - }, - }, - { - files: ['tests/integration/commands/dev/edge-functions.test.ts'], - rules: { - '@typescript-eslint/restrict-template-expressions': 'off', - '@typescript-eslint/no-non-null-assertion': 'off', - }, - }, - { - files: ['tests/integration/commands/dev/functions.test.ts'], - rules: { - '@typescript-eslint/no-unsafe-assignment': 'off', - '@typescript-eslint/no-require-imports': 'off', - '@typescript-eslint/no-unsafe-call': 'off', - }, - }, - { - files: ['tests/integration/commands/dev/redirects.test.ts'], - rules: { - '@typescript-eslint/restrict-template-expressions': 'off', - '@typescript-eslint/no-non-null-assertion': 'off', - '@typescript-eslint/no-unnecessary-type-conversion': 'off', - }, - }, - { - files: ['tests/integration/commands/dev/scheduled-functions.test.ts'], - rules: { - '@typescript-eslint/restrict-template-expressions': 'off', - '@typescript-eslint/no-non-null-assertion': 'off', - }, - }, - { - files: ['tests/integration/commands/dev/serve.test.ts'], - rules: { - '@typescript-eslint/no-floating-promises': 'off', - '@typescript-eslint/restrict-template-expressions': 'off', - '@typescript-eslint/no-unsafe-assignment': 'off', - '@typescript-eslint/no-require-imports': 'off', - '@typescript-eslint/no-unsafe-call': 'off', - '@typescript-eslint/require-await': 'off', - }, - }, - { - files: ['tests/integration/commands/dev/v2-api.test.ts'], - rules: { - '@typescript-eslint/restrict-template-expressions': 'off', - '@typescript-eslint/no-non-null-assertion': 'off', - '@typescript-eslint/no-unsafe-argument': 'off', - '@typescript-eslint/no-unsafe-return': 'off', - '@typescript-eslint/no-unsafe-call': 'off', - '@typescript-eslint/no-unsafe-member-access': 'off', - }, - }, - { - files: ['tests/integration/commands/env/env-clone.test.ts'], - rules: { - '@typescript-eslint/no-unsafe-assignment': 'off', - }, - }, - { - files: ['tests/integration/commands/env/env-get.test.ts'], - rules: { - '@typescript-eslint/no-floating-promises': 'off', - }, - }, - { - files: ['tests/integration/commands/env/env-list.test.ts'], - rules: { - '@typescript-eslint/no-floating-promises': 'off', - }, - }, - { - files: ['tests/integration/commands/env/env-set.test.ts'], - rules: { - 'no-restricted-imports': 'off', - '@typescript-eslint/no-unsafe-assignment': 'off', - }, - }, - { - files: ['tests/integration/commands/env/env-unset.test.ts'], - rules: { - '@typescript-eslint/no-unsafe-assignment': 'off', - }, - }, - { - files: ['tests/integration/commands/env/env.test.ts'], - rules: { - '@typescript-eslint/no-unsafe-assignment': 'off', - '@typescript-eslint/use-unknown-in-catch-callback-variable': 'off', - '@typescript-eslint/no-unsafe-return': 'off', - '@typescript-eslint/no-non-null-assertion': 'off', - }, - }, - { - files: ['tests/integration/commands/envelope/envelope.test.ts'], - rules: { - '@typescript-eslint/require-await': 'off', - '@typescript-eslint/no-floating-promises': 'off', - '@typescript-eslint/no-non-null-assertion': 'off', - }, - }, - { - files: ['tests/integration/commands/functions-invoke/functions-invoke.test.ts'], - rules: { - '@typescript-eslint/no-non-null-assertion': 'off', - }, - }, - { - files: ['tests/integration/commands/logs/build.test.ts'], - rules: { - '@typescript-eslint/no-unsafe-assignment': 'off', - '@typescript-eslint/no-unsafe-member-access': 'off', - '@typescript-eslint/no-unsafe-call': 'off', - '@typescript-eslint/no-unsafe-argument': 'off', - }, - }, - { - files: ['tests/integration/commands/logs/functions.test.ts'], - rules: { - 'no-empty-pattern': 'off', - '@typescript-eslint/no-unsafe-assignment': 'off', - '@typescript-eslint/no-unsafe-member-access': 'off', - '@typescript-eslint/no-unsafe-call': 'off', - '@typescript-eslint/no-unsafe-argument': 'off', - }, - }, - { - files: ['tests/integration/commands/sites/sites-create-template.test.ts'], - rules: { - '@typescript-eslint/require-await': 'off', - '@typescript-eslint/no-unnecessary-condition': 'off', - '@typescript-eslint/unbound-method': 'off', - '@typescript-eslint/no-unused-vars': 'off', - 'no-useless-escape': 'off', - }, - }, - { - files: ['tests/integration/frameworks/hugo.test.ts'], - rules: { - '@typescript-eslint/no-floating-promises': 'off', - '@typescript-eslint/restrict-template-expressions': 'off', - }, - }, - { - files: ['tests/integration/rules-proxy.test.ts'], - rules: { - '@typescript-eslint/no-misused-promises': 'off', - '@typescript-eslint/restrict-template-expressions': 'off', - '@typescript-eslint/no-unnecessary-condition': 'off', - }, - }, - { - files: ['tests/integration/telemetry.test.ts'], - rules: { - '@typescript-eslint/no-non-null-assertion': 'off', - '@typescript-eslint/no-unsafe-assignment': 'off', - }, - }, - { - files: ['tests/integration/utils/dev-server.ts'], - rules: { - '@typescript-eslint/no-explicit-any': 'off', - '@typescript-eslint/restrict-template-expressions': 'off', - '@typescript-eslint/no-unnecessary-condition': 'off', - '@typescript-eslint/ban-ts-comment': 'off', - '@typescript-eslint/no-non-null-assertion': 'off', - '@typescript-eslint/no-unsafe-argument': 'off', - '@typescript-eslint/no-unsafe-call': 'off', - '@typescript-eslint/no-unsafe-member-access': 'off', - '@typescript-eslint/no-floating-promises': 'off', - '@typescript-eslint/use-unknown-in-catch-callback-variable': 'off', - '@typescript-eslint/no-confusing-void-expression': 'off', - }, - }, - { - files: ['tests/integration/utils/fixture.ts'], - rules: { - '@typescript-eslint/no-explicit-any': 'off', - '@typescript-eslint/require-await': 'off', - '@typescript-eslint/no-non-null-assertion': 'off', - '@typescript-eslint/no-unsafe-assignment': 'off', - '@typescript-eslint/no-unnecessary-condition': 'off', - '@typescript-eslint/no-unsafe-member-access': 'off', - '@typescript-eslint/no-unsafe-call': 'off', - }, - }, - { - files: ['tests/integration/utils/mock-api-vitest.ts'], - rules: { - '@typescript-eslint/no-explicit-any': 'off', - '@typescript-eslint/prefer-nullish-coalescing': 'off', - }, - }, - { - files: ['tests/integration/utils/mock-api.ts'], - rules: { - '@typescript-eslint/no-explicit-any': 'off', - }, - }, - { - files: ['tests/integration/utils/site-builder.ts'], - rules: { - '@typescript-eslint/no-explicit-any': 'off', - '@typescript-eslint/no-unsafe-argument': 'off', - '@typescript-eslint/restrict-template-expressions': 'off', - }, - }, - { - files: ['types/ascii-table/index.d.ts'], - rules: { - '@typescript-eslint/unified-signatures': 'off', - }, - }, -] From 89f27a443efbac8250e8a7fe5645cba4e2dadcc7 Mon Sep 17 00:00:00 2001 From: Philippe Serhal Date: Wed, 7 Oct 2026 13:27:40 -0400 Subject: [PATCH 2/3] chore(eslint): disable n/hashbang in one file --- eslint-suppressions.json | 5 +---- eslint.config.js | 8 ++++++++ 2 files changed, 9 insertions(+), 4 deletions(-) diff --git a/eslint-suppressions.json b/eslint-suppressions.json index fb0dce4f4b8..5c978e8a2d4 100644 --- a/eslint-suppressions.json +++ b/eslint-suppressions.json @@ -585,9 +585,6 @@ }, "@typescript-eslint/no-unsafe-assignment": { "count": 1 - }, - "n/hashbang": { - "count": 1 } }, "src/lib/edge-functions/editor-helper.ts": { @@ -1852,4 +1849,4 @@ "count": 4 } } -} \ No newline at end of file +} diff --git a/eslint.config.js b/eslint.config.js index 367745e72ee..5bedc42ec65 100644 --- a/eslint.config.js +++ b/eslint.config.js @@ -124,6 +124,14 @@ export default tseslint.config( }, }, + { + files: ['src/lib/completion/script.ts'], + rules: { + // tabtab runs this file directly, so the shebang is intentional + 'n/hashbang': 'off', + }, + }, + // Tests { files: ['**/*.test.?(c|m)[jt]s?(x)'], From 3f7b011b2ac3f747e0701de0a8fdade1e1b70b42 Mon Sep 17 00:00:00 2001 From: Philippe Serhal Date: Wed, 7 Oct 2026 13:29:46 -0400 Subject: [PATCH 3/3] chore(eslint): fix autofixable suppressed rules --- eslint-suppressions.json | 44 +------------------ src/commands/base-command.ts | 4 +- src/commands/env/env-clone.ts | 2 +- src/commands/env/env-set.ts | 2 +- src/commands/env/env-unset.ts | 2 +- src/commands/functions/functions-create.ts | 2 +- src/commands/sites/sites-list.ts | 2 +- src/commands/unlink/unlink.ts | 2 +- src/lib/exec-fetcher.ts | 2 +- src/recipes/ai-context/context.ts | 4 +- src/utils/env/index.ts | 2 +- src/utils/get-repo-data.ts | 2 +- src/utils/proxy.ts | 2 +- .../commands/deploy/deploy.test.ts | 18 ++++---- .../commands/dev/dev-miscellaneous.test.ts | 2 +- 15 files changed, 25 insertions(+), 67 deletions(-) diff --git a/eslint-suppressions.json b/eslint-suppressions.json index 5c978e8a2d4..e9630309b09 100644 --- a/eslint-suppressions.json +++ b/eslint-suppressions.json @@ -35,9 +35,6 @@ "@typescript-eslint/no-floating-promises": { "count": 1 }, - "@typescript-eslint/no-unnecessary-boolean-literal-compare": { - "count": 2 - }, "@typescript-eslint/no-unnecessary-condition": { "count": 5 }, @@ -158,9 +155,6 @@ } }, "src/commands/env/env-clone.ts": { - "@typescript-eslint/no-unnecessary-boolean-literal-compare": { - "count": 1 - }, "@typescript-eslint/no-unsafe-argument": { "count": 2 }, @@ -223,9 +217,6 @@ } }, "src/commands/env/env-set.ts": { - "@typescript-eslint/no-unnecessary-boolean-literal-compare": { - "count": 1 - }, "@typescript-eslint/no-unnecessary-condition": { "count": 1 }, @@ -255,9 +246,6 @@ "@typescript-eslint/no-dynamic-delete": { "count": 1 }, - "@typescript-eslint/no-unnecessary-boolean-literal-compare": { - "count": 1 - }, "@typescript-eslint/no-unsafe-argument": { "count": 4 }, @@ -311,9 +299,6 @@ "@typescript-eslint/prefer-nullish-coalescing": { "count": 4 }, - "@typescript-eslint/prefer-optional-chain": { - "count": 1 - }, "@typescript-eslint/restrict-plus-operands": { "count": 6 }, @@ -513,9 +498,6 @@ "@typescript-eslint/no-unnecessary-condition": { "count": 2 }, - "@typescript-eslint/prefer-optional-chain": { - "count": 1 - }, "@typescript-eslint/restrict-template-expressions": { "count": 1 } @@ -533,9 +515,6 @@ "src/commands/unlink/unlink.ts": { "@typescript-eslint/no-unnecessary-condition": { "count": 3 - }, - "@typescript-eslint/prefer-optional-chain": { - "count": 1 } }, "src/commands/watch/watch.ts": { @@ -667,9 +646,6 @@ "src/lib/exec-fetcher.ts": { "@typescript-eslint/no-unnecessary-condition": { "count": 1 - }, - "@typescript-eslint/prefer-regexp-exec": { - "count": 1 } }, "src/lib/extensions.ts": { @@ -773,9 +749,6 @@ } }, "src/recipes/ai-context/context.ts": { - "@typescript-eslint/prefer-regexp-exec": { - "count": 2 - }, "no-empty": { "count": 1 } @@ -1069,9 +1042,6 @@ }, "@typescript-eslint/no-unsafe-member-access": { "count": 1 - }, - "@typescript-eslint/prefer-optional-chain": { - "count": 1 } }, "src/utils/execa.ts": { @@ -1134,9 +1104,6 @@ "@typescript-eslint/prefer-nullish-coalescing": { "count": 1 }, - "@typescript-eslint/prefer-optional-chain": { - "count": 1 - }, "@typescript-eslint/restrict-template-expressions": { "count": 3 } @@ -1246,9 +1213,6 @@ "@typescript-eslint/prefer-nullish-coalescing": { "count": 10 }, - "@typescript-eslint/prefer-optional-chain": { - "count": 1 - }, "@typescript-eslint/restrict-template-expressions": { "count": 23 } @@ -1483,9 +1447,6 @@ "@typescript-eslint/prefer-nullish-coalescing": { "count": 7 }, - "@typescript-eslint/prefer-regexp-exec": { - "count": 9 - }, "@typescript-eslint/require-await": { "count": 22 }, @@ -1503,9 +1464,6 @@ "@typescript-eslint/no-unsafe-assignment": { "count": 1 }, - "@typescript-eslint/prefer-regexp-exec": { - "count": 1 - }, "@typescript-eslint/require-await": { "count": 15 }, @@ -1849,4 +1807,4 @@ "count": 4 } } -} +} \ No newline at end of file diff --git a/src/commands/base-command.ts b/src/commands/base-command.ts index 2477b20be5a..d7e4acae9a9 100644 --- a/src/commands/base-command.ts +++ b/src/commands/base-command.ts @@ -352,7 +352,7 @@ export default class BaseCommand extends Command { /** override the longestOptionTermLength to react on hide options flag */ help.longestOptionTermLength = (command: BaseCommand, helper: Help): number => - (command.noBaseOptions === false && + (!command.noBaseOptions && helper.visibleOptions(command).reduce((max, option) => Math.max(max, helper.optionTerm(option).length), 0)) || 0 @@ -397,7 +397,7 @@ export default class BaseCommand extends Command { output = [...output, chalk.bold('ARGUMENTS'), formatHelpList(argumentList), ''] } - if (command.#noBaseOptions === false) { + if (!command.#noBaseOptions) { // Options const optionList = helper .visibleOptions(command) diff --git a/src/commands/env/env-clone.ts b/src/commands/env/env-clone.ts index 50b661aa141..0f400349780 100644 --- a/src/commands/env/env-clone.ts +++ b/src/commands/env/env-clone.ts @@ -38,7 +38,7 @@ const cloneEnvVars = async ({ api, force, siteFrom, siteTo }): Promise // @ts-expect-error TS(7031) FIXME: Binding element 'key' implicitly has an 'any' type... Remove this comment to see the full error message const envVarsToDelete = envelopeTo.filter(({ key }) => keysFrom.includes(key)) - if (envVarsToDelete.length !== 0 && Boolean(force) === false) { + if (envVarsToDelete.length !== 0 && !force) { await promptEnvCloneOverwrite(siteTo.id, envVarsToDelete) } // delete marked env vars in parallel diff --git a/src/commands/env/env-set.ts b/src/commands/env/env-set.ts index d1eac1b1e84..bd25d26e1b4 100644 --- a/src/commands/env/env-set.ts +++ b/src/commands/env/env-set.ts @@ -48,7 +48,7 @@ const setInEnvelope = async ({ api, context, force, key, scope, secret, siteInfo // @ts-expect-error TS(7006) FIXME: Parameter 'envVar' implicitly has an 'any' type. const existing = envelopeVariables.find((envVar) => envVar.key === key) // Checks if --force is passed and if it is an existing variaible, then we need to prompt the user - if (Boolean(force) === false && existing) { + if (!force && existing) { await promptOverwriteEnvVariable(key) } diff --git a/src/commands/env/env-unset.ts b/src/commands/env/env-unset.ts index 3e3baebf8e5..e5865258fac 100644 --- a/src/commands/env/env-unset.ts +++ b/src/commands/env/env-unset.ts @@ -27,7 +27,7 @@ const unsetInEnvelope = async ({ api, context, force, key, siteInfo }) => { return env } - if (Boolean(force) === false) { + if (!force) { await promptOverwriteEnvVariable(key) } diff --git a/src/commands/functions/functions-create.ts b/src/commands/functions/functions-create.ts index a3ea6c6d2ca..2758c497402 100644 --- a/src/commands/functions/functions-create.ts +++ b/src/commands/functions/functions-create.ts @@ -565,7 +565,7 @@ const TEMPLATE_PERMISSIONS = 0o777 const createFunctionAddon = async function ({ addonName, addons, api, siteData, siteId }) { try { const addon = getCurrentAddon({ addons, addonName }) - if (addon && addon.id) { + if (addon?.id) { log(`The "${addonName} add-on" already exists for ${siteData.name}`) return false } diff --git a/src/commands/sites/sites-list.ts b/src/commands/sites/sites-list.ts index 113f1a42efb..2a870c5bfe6 100644 --- a/src/commands/sites/sites-list.ts +++ b/src/commands/sites/sites-list.ts @@ -28,7 +28,7 @@ export const sitesList = async (options: OptionValues, command: BaseCommand) => account_name: site.account_name, } - if (site.build_settings && site.build_settings.repo_url) { + if (site.build_settings?.repo_url) { siteInfo.repo_url = site.build_settings.repo_url } diff --git a/src/commands/unlink/unlink.ts b/src/commands/unlink/unlink.ts index d86ce5ac165..8fa706f0649 100644 --- a/src/commands/unlink/unlink.ts +++ b/src/commands/unlink/unlink.ts @@ -22,7 +22,7 @@ export const unlink = async (_options: OptionValues, command: BaseCommand) => { siteId: siteData.id || siteId, }) - if (site && site.configPath) { + if (site?.configPath) { log(`Unlinked ${site.configPath} from ${siteData ? siteData.name : siteId}`) } else { log(`Unlinked from ${siteData ? siteData.name : siteId}`) diff --git a/src/lib/exec-fetcher.ts b/src/lib/exec-fetcher.ts index e30efff17d9..2f27cadeeaf 100644 --- a/src/lib/exec-fetcher.ts +++ b/src/lib/exec-fetcher.ts @@ -140,7 +140,7 @@ export const shouldFetchLatestVersion = async ({ return false } - const match = stdout.match(new RegExp(pattern)) + const match = new RegExp(pattern).exec(stdout) if (!match) { return false } diff --git a/src/recipes/ai-context/context.ts b/src/recipes/ai-context/context.ts index e74d86a8149..a2ccdc884ca 100644 --- a/src/recipes/ai-context/context.ts +++ b/src/recipes/ai-context/context.ts @@ -123,7 +123,7 @@ export const parseContextFile = (contents: string) => { contents, } - const providerContext = contents.match(PROVIDER_CONTEXT_REGEX) + const providerContext = PROVIDER_CONTEXT_REGEX.exec(contents) if (providerContext) { const [, attributes, innerContents] = providerContext @@ -148,7 +148,7 @@ export const parseContextFile = (contents: string) => { } } - const contextOverrides = contents.match(PROVIDER_CONTEXT_OVERRIDES_REGEX) + const contextOverrides = PROVIDER_CONTEXT_OVERRIDES_REGEX.exec(contents) if (contextOverrides) { const [overrideContents, , innerContents] = contextOverrides diff --git a/src/utils/env/index.ts b/src/utils/env/index.ts index 5d5ded867cc..8f5dfa22c95 100644 --- a/src/utils/env/index.ts +++ b/src/utils/env/index.ts @@ -372,7 +372,7 @@ export const translateFromEnvelopeToMongo = ( .sort((a, b) => (a.key.toLowerCase() < b.key.toLowerCase() ? -1 : 1)) .reduce((acc, cur) => { const envVar = cur.values.find((val) => [context, 'all'].includes((val.context_parameter ?? '') || val.context)) - if (envVar && envVar.value) { + if (envVar?.value) { return { ...acc, [cur.key]: envVar.value, diff --git a/src/utils/get-repo-data.ts b/src/utils/get-repo-data.ts index b3aeab41b89..9cd415a484d 100644 --- a/src/utils/get-repo-data.ts +++ b/src/utils/get-repo-data.ts @@ -31,7 +31,7 @@ const getRepoData = async ({ findUp('.git', { cwd: workingDir, type: 'directory' }), ]) - if (!gitDirectory || !gitConfig || !gitConfig.remote || Object.keys(gitConfig.remote).length === 0) { + if (!gitDirectory || !gitConfig?.remote || Object.keys(gitConfig.remote).length === 0) { throw new Error('No Git remote found') } diff --git a/src/utils/proxy.ts b/src/utils/proxy.ts index c88e8b42b19..01d4ea46088 100644 --- a/src/utils/proxy.ts +++ b/src/utils/proxy.ts @@ -590,7 +590,7 @@ const initializeProxy = async function ({ // The request has failed but we might still have a matching redirect // rule (without `force`) that should kick in. This is how we mimic the // file shadowing behavior from the CDN. - if (options && options.match) { + if (options?.match) { return serveRedirect({ // We don't want to match functions at this point because any redirects // to functions will have already been processed, so we don't supply a diff --git a/tests/integration/commands/deploy/deploy.test.ts b/tests/integration/commands/deploy/deploy.test.ts index 36537cd4a6a..3bc6b6de4ee 100644 --- a/tests/integration/commands/deploy/deploy.test.ts +++ b/tests/integration/commands/deploy/deploy.test.ts @@ -515,12 +515,12 @@ describe.concurrent('deploy command', () => { const output: string = await callCli(['deploy'], getCLIOptions({ apiUrl: mockApi.apiUrl, builder })) t.expect(output).toContain('Netlify Build completed in') - const [, deployIdPreBuild] = output.match(/DEPLOY_ID_PREBUILD: (\w+)/) ?? [] - const [, deployURLPreBuild] = output.match(/DEPLOY_URL_PREBUILD: (.+)/) ?? [] - const [, skewProtectionTokenPreBuild] = output.match(/NETLIFY_SKEW_PROTECTION_TOKEN_PREBUILD: (.+)/) ?? [] - const [, deployId] = output.match(/DEPLOY_ID: (\w+)/) ?? [] - const [, deployURL] = output.match(/DEPLOY_URL: (.+)/) ?? [] - const [, skewProtectionToken] = output.match(/NETLIFY_SKEW_PROTECTION_TOKEN: (.+)/) ?? [] + const [, deployIdPreBuild] = /DEPLOY_ID_PREBUILD: (\w+)/.exec(output) ?? [] + const [, deployURLPreBuild] = /DEPLOY_URL_PREBUILD: (.+)/.exec(output) ?? [] + const [, skewProtectionTokenPreBuild] = /NETLIFY_SKEW_PROTECTION_TOKEN_PREBUILD: (.+)/.exec(output) ?? [] + const [, deployId] = /DEPLOY_ID: (\w+)/.exec(output) ?? [] + const [, deployURL] = /DEPLOY_URL: (.+)/.exec(output) ?? [] + const [, skewProtectionToken] = /NETLIFY_SKEW_PROTECTION_TOKEN: (.+)/.exec(output) ?? [] t.expect(deployIdPreBuild).toBeTruthy() t.expect(deployIdPreBuild).toEqual('deploy_id') @@ -571,8 +571,8 @@ describe.concurrent('deploy command', () => { t.expect(output).toMatch(/--build.+is now the default and can safely be omitted./) t.expect(output).toContain('Netlify Build completed in') - const [, deployId] = output.match(/DEPLOY_ID: (\w+)/) ?? [] - const [, deployURL] = output.match(/DEPLOY_URL: (.+)/) ?? [] + const [, deployId] = /DEPLOY_ID: (\w+)/.exec(output) ?? [] + const [, deployURL] = /DEPLOY_URL: (.+)/.exec(output) ?? [] t.expect(deployId).toEqual('deploy_id') t.expect(deployURL).toContain('https://deploy_id--') @@ -1471,7 +1471,7 @@ describe.concurrent('deploy command', () => { getCLIOptions({ apiUrl: mockApi.apiUrl, builder }), ) - const [, branch] = output.match(/TEST_BRANCH: (.+)/) ?? [] + const [, branch] = /TEST_BRANCH: (.+)/.exec(output) ?? [] expect(branch).toBe('custom-alias') const createDeployRequest = mockApi.requests.find( diff --git a/tests/integration/commands/dev/dev-miscellaneous.test.ts b/tests/integration/commands/dev/dev-miscellaneous.test.ts index 97eb52cc595..505da0dbccf 100644 --- a/tests/integration/commands/dev/dev-miscellaneous.test.ts +++ b/tests/integration/commands/dev/dev-miscellaneous.test.ts @@ -191,7 +191,7 @@ describe.concurrent('commands/dev-miscellaneous', () => { await fetch(`${url}/.netlify/functions/hello-background`) const output = outputBuffer.toString() - const context = JSON.parse(output.match(/__CLIENT_CONTEXT__START__(.*)__CLIENT_CONTEXT__END__/)?.[1] ?? '""') + const context = JSON.parse(/__CLIENT_CONTEXT__START__(.*)__CLIENT_CONTEXT__END__/.exec(output)?.[1] ?? '""') t.expect(context).toHaveProperty('clientContext', {}) t.expect(context).toHaveProperty('identity', null) })