fix(ci): eslint ignores *.generated.ts; restore the contract file's header

The on-merge `npm run fix` bot (bc655bfb40, #118250) ran eslint --fix over
apps/shared/src/gateway-contract.generated.ts and stripped its `/* eslint-disable */`
header. scripts/gen_gateway_contracts.py emits that header, so
tests/tui_gateway/contracts/test_generated.py::test_generated_files_are_current has been
red on main since, and on every PR opened after it. Generated files are not lint targets:
ignore the pattern in the shared config and regenerate the file.
This commit is contained in:
teknium1
2026-09-21 08:07:25 -07:00
committed by Teknium
parent bc655bfb40
commit 75b083e939
2 changed files with 4 additions and 2 deletions

View File

@@ -1,7 +1,7 @@
// GENERATED by scripts/gen_gateway_contracts.py from tui_gateway/contracts — DO NOT EDIT.
// Regenerate: .venv/bin/python scripts/gen_gateway_contracts.py
// tests/tui_gateway/contracts/test_generated.py fails when this file is stale.
/* eslint-disable */
// ── Types ──
/** Any method the desktop may route to a named profile (``requestGatewayForProfile`` adds ``profile``). */
export interface ProfileParams {

View File

@@ -20,7 +20,9 @@ import globals from 'globals'
export default [
{
ignores: ['**/node_modules/**', '**/dist/**', 'src/**/*.js', '**/package-lock.json']
// *.generated.ts is written by scripts/gen_gateway_contracts.py; the on-merge `npm run fix` bot
// must not rewrite it (it stripped the file's own eslint-disable header and left the tree stale).
ignores: ['**/node_modules/**', '**/dist/**', 'src/**/*.js', '**/package-lock.json', '**/*.generated.ts']
},
js.configs.recommended,
{