{"_id":"@interfere/landmines","_rev":"4-24b8a95f4698a9f1ec682839a0d89a43","name":"@interfere/landmines","dist-tags":{"latest":"0.1.0"},"versions":{"0.0.0-stage":{"name":"@interfere/landmines","version":"0.0.0-stage","_id":"@interfere/landmines@0.0.0-stage","stub":true,"maintainers":[{"name":"skve","email":"7uhz1jnri@mozmail.com"}],"dist":{"shasum":"514479a0a328dedf587ffd43029f073ad220d6b6","tarball":"https://registry.npmjs.org/@interfere/landmines/-/landmines-0.0.0-stage.tgz","fileCount":2,"integrity":"sha512-w1wpZWLY8kTBnJe+m6F1cz2W+LjRLGQ5JC0AGrrajtnrMdjixa1orlPIUux/IuznRUkVBunTqoJxRbHWOFAyPQ==","signatures":[{"sig":"MEYCIQC20SGjmu6X7wHicBXGl83xlZQTKCVYk/i7zydVO7EbcwIhAOTxAelbkw03WVxtP1z95/lileRTTedsW3/MRoGULOW0","keyid":"SHA256:DhQ8wR5APBvFHLF/+Tc+AYvPOdTpcIDqOhxsBHRwC7U"}],"unpackedSize":342},"_npmUser":{"name":"skve","email":"7uhz1jnri@mozmail.com"},"description":"Temporary package placeholder for staged publishing","directories":{}},"0.0.0":{"name":"@interfere/landmines","version":"0.0.0","keywords":["agents","ai","lint","msw","oxlint","oxlint-plugin","testing"],"author":{"name":"Interfere, Inc."},"license":"MIT","_id":"@interfere/landmines@0.0.0","maintainers":[{"name":"skve","email":"7uhz1jnri@mozmail.com"}],"homepage":"https://github.com/interfere-inc/landmines#readme","bugs":{"url":"https://github.com/interfere-inc/landmines/issues"},"dist":{"shasum":"e71b3d61d959188759fd223ede13900c7cecb466","tarball":"https://registry.npmjs.org/@interfere/landmines/-/landmines-0.0.0.tgz","fileCount":12,"integrity":"sha512-Mgx9QPWP4QrBZ2wj+sUvYxLi8mA4/hkEUR0r7cwgmvdXI6ktF4k1ADi+uzQAptGnB0MVIn5XlOSSV9hsZXqmnA==","signatures":[{"sig":"MEYCIQDad+KKwhGQQZyyXa/DSqiZxu1ZIWdptGoNUSwpuVD+pAIhAMQg4R51ADp1yZR61aBkrEAGkWEGggucbdNdXaktMAZc","keyid":"SHA256:DhQ8wR5APBvFHLF/+Tc+AYvPOdTpcIDqOhxsBHRwC7U"},{"sig":"MEUCIQChY103GbjK1KhRW/iFAUK4ltq7ke51dll1Pad+OPoHJQIgHgNfy0P+NlB6BuFwzzoDrdTFwmTG6dbMhQyrIOtpyYo=","keyid":"SHA256:DhQ8wR5APBvFHLF/+Tc+AYvPOdTpcIDqOhxsBHRwC7U"}],"unpackedSize":89450},"type":"module","engines":{"node":">=22.18.0"},"exports":{"./style":{"types":"./dist/style.d.mts","default":"./dist/style.mjs"},"./types":{"types":"./dist/types.d.mts","default":"./dist/types.mjs"},"./testing":{"types":"./dist/testing.d.mts","default":"./dist/testing.mjs"},"./structure":{"types":"./dist/structure.d.mts","default":"./dist/structure.mjs"},"./package.json":"./package.json","./configs/recommended.json":"./configs/recommended.json"},"gitHead":"8b400e9392b6358694df40992ad61fe646174838","scripts":{"test":"vitest run","build":"tsdown","clean":"git clean -xdf .cache .turbo dist node_modules","typecheck":"tsc"},"_npmUser":{"name":"skve","email":"7uhz1jnri@mozmail.com"},"repository":{"url":"git+https://github.com/interfere-inc/landmines.git","type":"git","directory":"packages/landmines"},"_npmVersion":"11.20.0","description":"Oxlint rules that keep AI-written code honest: real implementations, real signals, no flake masking.","directories":{},"_nodeVersion":"26.11.1","dependencies":{"zod":"4.6.6","@babel/types":"8.0.4","oxc-resolver":"11.24.2","@babel/parser":"8.0.4","@oxlint/plugins":"1.81.0"},"publishConfig":{"access":"public","provenance":true},"_hasShrinkwrap":false,"devDependencies":{"oxlint":"1.81.0","tsdown":"0.23.0","vitest":"5.0.5","typescript":"7.0.2","@types/node":"26.4.1"},"peerDependencies":{"oxlint":">=1.81.0"},"_npmOperationalInternal":{"tmp":"tmp/landmines_0.0.0_1793214590084_0.7592062301495486","host":"s3://npm-registry-packages-npm-production"}},"0.1.0":{"_id":"@interfere/landmines@0.1.0","bugs":{"url":"https://github.com/interfere-inc/landmines/issues"},"dist":{"shasum":"4f31e1e2321c938908ac4136152f587dadcb1079","tarball":"https://registry.npmjs.org/@interfere/landmines/-/landmines-0.1.0.tgz","fileCount":12,"integrity":"sha512-pbKVVTRBlkv395GbApiF9/AY8r9ZS85IlqzRXn4mhuQWFisC6sNEkOUHckXtSaTyhplLrODMrEkbzv0mwOwqew==","signatures":[{"sig":"MEQCIBOWxrvlVyDYAdlW8XLwIu4+cCeX9frLVDlPL+AeZggwAiAknj365oglHUMvlMeBlxImmHjyOwPhxRHEdwtg1LPpbg==","keyid":"SHA256:DhQ8wR5APBvFHLF/+Tc+AYvPOdTpcIDqOhxsBHRwC7U"},{"keyid":"SHA256:DhQ8wR5APBvFHLF/+Tc+AYvPOdTpcIDqOhxsBHRwC7U","sig":"MEYCIQD3mjS3nKBKiw5XkHkilTyXdOolWviHUq/4TRJ5LoS4RQIhAKvt7X9ydj3RTuwuikOBkbwqn15x3xVRb/jPJqZ8AAHD"}],"attestations":{"url":"https://registry.npmjs.org/-/npm/v1/attestations/@interfere%2flandmines@0.1.0","provenance":{"predicateType":"https://slsa.dev/provenance/v1"}},"unpackedSize":89450},"name":"@interfere/landmines","type":"module","_from":"file:../../../../_temp/changeset-pack-14365308636-1794957289706/packages/interfere-landmines-0.1.0.tgz","author":{"name":"Interfere, Inc."},"engines":{"node":">=22.18.0"},"exports":{"./style":{"types":"./dist/style.d.mts","default":"./dist/style.mjs"},"./types":{"types":"./dist/types.d.mts","default":"./dist/types.mjs"},"./testing":{"types":"./dist/testing.d.mts","default":"./dist/testing.mjs"},"./structure":{"types":"./dist/structure.d.mts","default":"./dist/structure.mjs"},"./package.json":"./package.json","./configs/recommended.json":"./configs/recommended.json"},"license":"MIT","scripts":{"test":"vitest run","build":"tsdown","clean":"git clean -xdf .cache .turbo dist node_modules","typecheck":"tsc"},"version":"0.1.0","_npmUser":{"name":"GitHub Actions","email":"npm-oidc-no-reply@github.com","trustedPublisher":{"id":"github","oidcConfigId":"f13bf68c-9161-4a53-b842-b9b4baf85078"}},"homepage":"https://github.com/interfere-inc/landmines#readme","keywords":["agents","ai","lint","msw","oxlint","oxlint-plugin","testing"],"_resolved":"/home/runner/work/_temp/changeset-pack-14365308636-1794957289706/packages/interfere-landmines-0.1.0.tgz","_integrity":"sha512-pbKVVTRBlkv395GbApiF9/AY8r9ZS85IlqzRXn4mhuQWFisC6sNEkOUHckXtSaTyhplLrODMrEkbzv0mwOwqew==","repository":{"url":"git+https://github.com/interfere-inc/landmines.git","type":"git","directory":"packages/landmines"},"_npmVersion":"11.19.0","description":"Oxlint rules that keep AI-written code honest: real implementations, real signals, no flake masking.","directories":{},"maintainers":[{"name":"psny-interfere","email":"philip@interfere.com"},{"name":"skve","email":"7uhz1jnri@mozmail.com"}],"_nodeVersion":"24.22.2","dependencies":{"zod":"4.6.6","@babel/types":"8.0.4","oxc-resolver":"11.24.2","@babel/parser":"8.0.4","@oxlint/plugins":"1.81.0"},"publishConfig":{"access":"public","provenance":true},"_hasShrinkwrap":false,"devDependencies":{"oxlint":"1.81.0","tsdown":"0.23.0","vitest":"5.0.5","typescript":"7.0.2","@types/node":"26.4.1"},"peerDependencies":{"oxlint":">=1.81.0"},"_npmOperationalInternal":{"host":"s3://npm-registry-packages-npm-production","tmp":"tmp/landmines_0.1.0_1794957374977_0.39751299666187845"}}},"time":{"created":"2026-10-28T19:07:41.282Z","modified":"2026-11-17T23:16:15.436Z","0.0.0-stage":"2026-10-28T19:07:41.282Z","0.0.0":"2026-10-28T19:09:50.181Z","0.1.0":"2026-11-17T23:16:15.084Z"},"bugs":{"url":"https://github.com/interfere-inc/landmines/issues"},"author":{"name":"Interfere, Inc."},"license":"MIT","homepage":"https://github.com/interfere-inc/landmines#readme","keywords":["agents","ai","lint","msw","oxlint","oxlint-plugin","testing"],"repository":{"url":"git+https://github.com/interfere-inc/landmines.git","type":"git","directory":"packages/landmines"},"description":"Oxlint rules that keep AI-written code honest: real implementations, real signals, no flake masking.","maintainers":[{"name":"psny-interfere","email":"philip@interfere.com"},{"name":"skve","email":"7uhz1jnri@mozmail.com"}],"readme":"# landmines\n\nOxlint rules that keep AI-written code honest.\n\nCoding agents are fast, and they optimise for green checks. Left alone, they\nmock the thing under test, sleep until a race usually goes their way, retry\nthe flake, raise the timeout, and narrate the diff in comments. Every one of\nthose passes CI. None of them is true.\n\n`landmines` makes the honest path the only one that lints. Each rule fails\nwith a message that tells the agent (or the human) what to do instead, so the\nfix lands in the same loop that tripped it.\n\nBuilt and used in production at [Interfere](https://interfere.com).\n\n## Install\n\n```sh\nbun add -d oxlint @interfere/landmines\n```\n\nExtend the recommended configuration in `.oxlintrc.json`:\n\n```json\n{\n  \"extends\": [\"./node_modules/@interfere/landmines/configs/recommended.json\"]\n}\n```\n\nOr register only the plugins you want:\n\n```json\n{\n  \"jsPlugins\": [\n    { \"name\": \"landmines-testing\", \"specifier\": \"@interfere/landmines/testing\" }\n  ],\n  \"rules\": {\n    \"landmines-testing/no-test-doubles\": \"error\"\n  }\n}\n```\n\nRequires Oxlint 1.81 or later and Node 22.18 or later.\n\n## Rules\n\n### `landmines-testing`\n\nTests that can't lie.\n\n| Rule                 | What it stops                                                                                                                                                                                                                                 |\n| -------------------- | --------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |\n| `no-test-doubles`    | Replacing dependency behaviour in tests: module mocks, `vi.fn(impl)`, stubbed globals, patched prototypes, hand-written bindings and fake responses. Use the real implementation and MSW for the network. Observation-only spies are allowed. |\n| `strict-msw`         | Starting MSW without `onUnhandledRequest: \"error\"`, so unmocked requests silently reach the network.                                                                                                                                          |\n| `no-fixed-sleep`     | Awaiting a fixed real-time delay in a test or hook. Await the operation or a signal it emits.                                                                                                                                                 |\n| `no-unsignaled-poll` | `expect.poll` and `vi.waitFor` on request recorders and spy state, which race a deadline instead of awaiting an event.                                                                                                                        |\n| `no-flake-masking`   | Test retries and raised timeouts. A test that passes on rerun is a flake to fix.                                                                                                                                                              |\n\n`no-fixed-sleep`, `strict-msw` and `no-flake-masking` accept a per-file\nallowlist with an exact count, so you can adopt them in an existing codebase\nand ratchet down:\n\n```json\n{\n  \"landmines-testing/no-flake-masking\": [\n    \"error\",\n    { \"allow\": { \"src/legacy/slow.test.ts\": 2 } }\n  ]\n}\n```\n\nThe rule reports when a file has fewer violations than its allowance, so the\nlist only shrinks.\n\n### `landmines-style`\n\n| Rule          | What it stops                                                                                                                                                                                                                                                   |\n| ------------- | --------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |\n| `no-comments` | Prose comments. Allowed: functional directives (`oxlint-disable`, `@ts-expect-error`, `/* @__PURE__ */`, licence headers…), single-line `// WARNING:` comments for dangerous recurring footguns, and TSDoc on exported public API. Rationale belongs in the PR. |\n\nPass `publicApi` (regular expressions matched against the file path) to allow\nTSDoc only in your published packages:\n\n```json\n{\n  \"landmines-style/no-comments\": [\"error\", { \"publicApi\": [\"/packages/sdk/\"] }]\n}\n```\n\n### `landmines-structure`\n\n| Rule              | What it stops                                                                                                                         |\n| ----------------- | ------------------------------------------------------------------------------------------------------------------------------------- |\n| `colocated-tests` | Tests detached from the implementation they import. Tests live beside their subject or in its local `tests/` directory.               |\n| `test-file-names` | `.spec.ts`, `.tests.ts`, `helpers.ts`, `mocks.ts` and friends. Use `.test.ts`, `.fixture.ts` and `.test-utils.ts`.                    |\n| `package-exports` | Unrestricted source exports such as `\"./*\": \"./src/*.ts\"`. Declare explicit entrypoints or named public namespaces in `package.json`. |\n\n### `landmines-types`\n\n| Rule                       | What it stops                                                                                                      |\n| -------------------------- | ------------------------------------------------------------------------------------------------------------------ |\n| `no-explicit-return-types` | Annotated return types on implementations. Let them be inferred; pin a contract with `satisfies` where it matters. |\n\n## Pairs well with\n\n- [anti-slop](https://github.com/dmmulroy/anti-slop) for type-level slop:\n  chained assertions, unsafe dictionaries, `unknown` plumbing.\n\n## Contributing\n\n```sh\nbun install\nbun run lint && bun run typecheck && bun run test\n```\n\nAdd a changeset with `bun changeset` for any user-facing change.\n\n## License\n\nMIT\n","readmeFilename":"README.md"}