Repository navigation
deps(js): take eslint 10 by moving the config where eslint 10 reads it - #335
Merged
Merged
Conversation
Dependabot's #309 bumped eslint to 10.x alone. That could not be merged: eslint 10 does not read package.json's `eslintConfig` block at all, so the bump would have silently discarded every rule this SDK lints with — including the config fix that had just landed for the same file — and left `npm run lint` either erroring or running with defaults, depending on how it was invoked. So the block moves to sdks/javascript/eslint.config.js, as a port and not a rewrite: same five rules, same severities. Three translation points are recorded in the file, because none of them is visible from a version diff — flat config has no `extends`, `env` splits into `globals` plus `ecmaVersion`, and `.eslintignore` is no longer read so `dist/**` has to be an `ignores` entry or the emitted JavaScript gets linted as source. typescript-eslint 8 then found two real defects, because it defaults `caughtErrors: 'all'` and reports every discarded catch binding. Six of the eight sites were deliberate and are renamed `_error`. The other two threw a new error while dropping the cause of the original: - findBinary() reported every execSync('which objectfs') failure as "not found in PATH", which sends the reader to the wrong place when the cause was a permissions failure or an unwritable cwd. - prepareMountPoint() reported every `access` rejection as "insufficient permissions", including ENOENT for a mount point that does not exist. Both now include the cause. Test files are linted now, which they were not before, and that found a third thing: index.test.ts disabled `@typescript-eslint/no-var-requires`, a rule typescript-eslint 8 renamed to `no-require-imports`, so the directive had been suppressing nothing. Verified: `npm run lint` 0 errors / 19 warnings (all no-explicit-any, `warn` by design), `npm run build` emits dist/, `npm test` 65/65. The config itself was mutation-checked — an unused binding and a formatting violation were introduced and both reported as errors, so the rules are enforced rather than merely present.
scttfrdmn
enabled auto-merge (squash)
August 4, 2026 03:39
… deps/eslint-10-flat-config
scttfrdmn
added a commit
that referenced
this pull request
Aug 4, 2026
Three conflicts, all the same shape: #335 (eslint 10) merged to main, and this branch was cut from #335's tip, so package.json, its lockfile and CHANGELOG all carry both sets of changes. Ours in every case — main's side is the pre-bump value this PR exists to replace. Verified the merged manifest keeps both stacks: typescript ^6, typedoc ^0.28.20, jest and @types/jest ^30 from here; eslint ^10.8.0, typescript-eslint ^8.66.0, globals ^17.9.0 from #335. Lockfile confirmed in sync via npm install --package-lock-only producing no further diff. Re-ran the gates from a clean npm ci after resolving, not before: tsc 0 errors, 65 tests, lint 0 errors / 19 warnings.
This was referenced Aug 4, 2026
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Replaces #309, which could not be merged as opened.
Why the version bump alone was not mergeable
eslint 10 does not read
package.json'seslintConfigblock. It requires a flateslint.config.js. With the bump applied and no such file,npm run linteither errors out or lints with default rules depending on the invocation — and either way every rule this SDK is configured with is gone. That would have quietly undone the config fix #327 had just landed for this same file, where the block was read but named a preset that did not resolve.Dependabot cannot produce this PR: it bumps versions, and this release changed where configuration lives.
What is here
sdks/javascript/eslint.config.js, a port of the old block — same five rules, same severities. Three translation points are recorded in the file, since none is visible from a version diff:extends.eslint:recommended→js.configs.recommended;plugin:@typescript-eslint/recommended→ spread oftseslint.configs.recommended. The string forms are not accepted anywhere.env: {node, es6}was two things at once and splits intolanguageOptions.globalsandecmaVersion..eslintignoreis no longer read, sodist/**must be anignoresentry or the emitted JavaScript gets linted as source.eslint-config-prettieris spread after the recommended presets, not before — its only job is turning off the stylistic rules those presets enable, so anything after it re-enables them.Two real defects the bump surfaced
typescript-eslint 8 defaults
caughtErrors: 'all', so every discardedcatchbinding reports. Eight sites did. I inspected each rather than blanket-renaming, and two were throwing a new error while dropping the cause of the original:client.tsfindBinary()execSync('which objectfs')failure reported as "not found in PATH"which, a permissions failure, or an unwritable cwd all land here and none of them is a missing binarymount.tsprepareMountPoint()accessrejection reported as "insufficient permissions"accessrejectsENOENTfor a path that is simply goneThe other six are genuinely ignored, each already sitting above a comment saying so, and are renamed
_error/_unlinkError, whichcaughtErrorsIgnorePattern: '^_'exempts.A third thing, from linting test files
Test files are linted now; they were not before. Nothing in this config is type-aware, so the usual reason to exclude them does not apply. Doing so found that
index.test.tscarriedeslint-disable-next-line @typescript-eslint/no-var-requires— a rule typescript-eslint 8 renamed tono-require-imports— so the directive had been suppressing nothing.Verification
npm run lint→ 0 errors, 19 warnings, allno-explicit-any, which the config sets towarndeliberately. Matches the pre-change baseline of 0 errors / 23 warnings; the 4 that dropped were "file ignored by pattern" notices, now that tests are linted.npm run build→tscclean,dist/emitted.npm test→ 65/65, 4 suites.src/errors.tstook it to 3 errors; reverting returned it to 0. The rules are enforced, not merely present.package-lock.jsonregenerated and confirmed in sync (npm install --package-lock-onlyproduces no further diff).used-not-defined: []) and markdownlint diagnostics identical to the base branch (361 each side).Closes #309