Skip to content

normalizeAmount takes an _accountType parameter it never reads #92

Description

@KenTaniguchi-R

Mechanism

pnpm lint exits 1 with 1,024 errors. 981 of the 982 reported files are under .stryker-tmp/, the mutation-testing sandbox.

.stryker-tmp/ is listed in .gitignore:53, but ESLint 9 flat config does not read .gitignore. eslint.config.mjs:15 calls globalIgnores([...]) with only the eslint-config-next defaults (.next/**, out/**, build/**, next-env.d.ts) — .stryker-tmp is not among them.

Impact

Any developer who has ever run pnpm test:mutate has a permanently red pnpm lint locally. CI passes only because the runner starts from a clean checkout, so the failure is invisible where it would be caught and constant where it is most annoying. It also buries the one genuine finding.

Reproduction

$ pnpm test:mutate:incremental   # creates .stryker-tmp/
$ pnpm lint
...
1037 problems (1024 errors, 13 warnings)

Attribution by top-level directory:

981  .stryker-tmp
  1  src

Fix

Add .stryker-tmp/** to globalIgnores in eslint.config.mjs, or wire .gitignore in via includeIgnoreFile from @eslint/compat.

The single real source finding is src/lib/money.ts:28normalizeAmount(amountCents, _accountType) takes an account-type parameter it never reads. Worth deleting the parameter outright: its presence implies account type affects normalization when it does not, which is misleading next to the sign-convention problems in #84.

Found in UI audit 2026-08-29.

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions