Skip to content

fix(ci): repo-wide lint gate fixes (eslint, lint-ga, lint-k8s, text) - #28

Merged
vitaliytv merged 1 commit into
mainfrom
fix/ci-lint-repo-wide
Jul 29, 2026
Merged

fix(ci): repo-wide lint gate fixes (eslint, lint-ga, lint-k8s, text)#28
vitaliytv merged 1 commit into
mainfrom
fix/ci-lint-repo-wide

Conversation

@vitaliytv

Copy link
Copy Markdown
Member

Summary

Four CI checks (eslint, lint-ga, lint-k8s, text) were failing on #26, independent of the mt-core dependency fix that PR shipped. This PR addresses those four, each root-caused separately:

  • eslint/knip: knip.json's ignore list still pointed at .pi/extensions/n-cursor-adr/** — the directory was renamed to n-rules-adr a while back — plus rtk.ts was never added to the ignore list at all. Also @7n/rules-ci-github/-lang-js/-lang-rust were flagged as unused devDependencies; they're actually consumed as plugins by the @7n/rules CLI, not via JS import, so knip's static analysis can't see the usage.
  • lint-ga / lint-js / lint-text: on.pull_request.paths was missing or incomplete on three workflow files. push.paths filtered the trigger correctly, but pull_request ran unconditionally on every PR — and then failed its own drift-check against canon for not matching the expected glob set.
  • text: .cspell.json was missing a handful of legitimate Ukrainian words (мейнтейнера, недовірений, стрімоване, plus доставки/залежнісного that showed up in freshly-regenerated docs). Also fixed pre-existing oxfmt/eslint/stylelint formatting drift in PullRequestsDialog.vue and TaskGraph.vue — found a wrapping style compatible with all three linters at once (oxfmt's own preferred wrap for a q-badge mustache conflicted with eslint's vue/multiline-html-element-content-newline, and its CSS reflow needed stylelint's rule-empty-line-before blank lines added).
  • k8s: k8s/teleport/ingress.yaml actually contained a NetworkPolicy resource (not an Ingress) under the wrong filename, so the mandatory-NetworkPolicy check couldn't find it for the teleport StatefulSet. Renamed to networkpolicy.yaml and added the intra-replica ingress/egress rules required by the StatefulSet canon snippet.

Also regenerated the two doc files (docs/PullRequestsDialog.md, docs/TaskGraph.md) per this repo's doc-files convention, since their source files changed.

Deliberately out of scope (discussed and agreed)

  • kubescape: kubescape scan k8s surfaces ~17 distinct security-posture controls across the whole k8s/ tree (RBAC delete capabilities, non-root containers, immutable filesystem, naked pods, a second missing NetworkPolicy for the naked Pod in k8s/dev-pod/template.yaml, etc.). This is a pre-existing hardening backlog, not a quick CI fix — several findings need functional judgment calls (e.g. does teleport's container actually need root, is the RBAC delete capability load-bearing) that are better handled as their own scoped effort.
  • doc-files: ~19 other files (app/src/*.js, owner/src/*.js) have stale docs unrelated to this PR's diff — left alone to keep this change focused.

Verification

Ran each fixed check locally with the exact tool version pinned in bun.lock (1.51.0 — my first pass used a stale 1.45.0 install and chased a couple of false positives/negatives before catching that):

  • npx @7n/rules lint ga --no-fix → clean
  • npx @7n/rules lint js --no-fix → clean
  • npx @7n/rules lint text --no-fix → clean
  • npx @7n/rules lint style --no-fix → clean
  • bunx knip --no-config-hints → clean
  • npx @7n/rules lint k8s --no-fix → only the deliberately-deferred kubescape backlog remains (missing-NetworkPolicy violation for teleport is gone)

Test plan

  • CI green on eslint, lint-ga, lint-js, lint-text for this PR
  • lint-k8s still shows the kubescape security-posture backlog (expected, tracked separately)

🤖 Generated with Claude Code

Чотири CI-перевірки падали на PR #26 незалежно від mt-core фіксу:

- eslint/knip: knip.json ігнорував .pi/extensions/n-cursor-adr/** — тека
  давно перейменована на n-rules-adr, плюс rtk.ts ніколи не був у ignore;
  @7n/rules-ci-github/-lang-js/-lang-rust помилково вважались unused
  devDependencies (насправді підключаються плагінами @7n/rules, не імпортом).
- lint-ga / lint-js / lint-text: on.pull_request.paths був відсутній або
  неповний у трьох workflow — push.paths фільтрував тригер, а pull_request
  ганяв лінт на кожен PR незалежно від зачеплених файлів (і одразу падав на
  policy-deny drift-перевірці на невідповідність канону).
- text: .cspell.json бракувало кількох легітимних українських слів
  (мейнтейнера, недовірений, стрімоване, доставки, залежнісного) — частина
  з'явилась у щойно перегенерованих доках; oxfmt/eslint/stylelint дрейф у
  PullRequestsDialog.vue/TaskGraph.vue (сумісний формат для всіх трьох
  лінтерів одночасно).
- k8s: k8s/teleport/ingress.yaml насправді містив NetworkPolicy (не Ingress)
  під невірною назвою файлу — мандатор-перевірка не бачила її для
  StatefulSet teleport. Перейменовано на networkpolicy.yaml + додано
  intra-replica ingress/egress правила зі stateful-set-канону.

Поза скоупом (свідомо відкладено, обговорено з користувачем):
- kubescape виявляє ~17 контролів security posture по всьому k8s/ дереву
  (RBAC, securityContext, naked pods, missing NetworkPolicy для naked Pod
  у dev-pod/) — не квапливий CI-фікс, потребує функціональних рішень поза
  скоупом цієї задачі.
- doc-files: ще ~19 файлів (app/src/*.js, owner/src/*.js) мають застарілі
  доки не повʼязані з цим PR — залишено як є.

Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>
@vitaliytv
vitaliytv merged commit dd8781d into main Jul 29, 2026
5 of 8 checks passed
@vitaliytv
vitaliytv deleted the fix/ci-lint-repo-wide branch July 31, 2026 05:15
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant