Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
91 changes: 46 additions & 45 deletions AGENTS.md
Original file line number Diff line number Diff line change
Expand Up @@ -80,50 +80,51 @@ Verify a boundary against the imports a developer or agent would plausibly write

### What enforces what

| Rule | Enforced by |
| ------------------------------------------------------------------------------ | --------------------------------------------------- |
| Formatting | oxfmt |
| Lint findings are errors; no rule warns | oxlint preset |
| Comments are TSDoc, directives, or `SAFETY:` only | `antelopejs/no-comments` |
| Every test asserts | `antelopejs/require-assertion` |
| Tests read no files outside fixtures, helpers, locales | `antelopejs/no-fs-read-in-tests` |
| Tests import the code under test from local source, not their own package name | `antelopejs/no-self-import-in-tests` |
| No assertion that restates a constant | `antelopejs/no-constant-value-assertion` |
| No test whose only check is "is a function" | `antelopejs/no-typeof-function-only-test` |
| String-keyed object tables are read through own keys only | `antelopejs/no-inherited-key-lookup` |
| A type guard checks each member it narrows to; keys with `Object.hasOwn` | `antelopejs/no-presence-only-type-guard` |
| A type guard checks the nested elements and values it claims | review; no tool |
| A startup read does not decide an insert another replica can race | `antelopejs/no-read-then-insert` |
| `Object.assign` writes no `unknown`, `any` or mistyped value over a field | `antelopejs/no-unsafe-object-assign` |
| Every file type-aware lint reads is listed by a tsconfig | `antelopejs/require-tsconfig-include` |
| Params ≤ 5, function ≤ 120 lines, file ≤ 500 lines, depth ≤ 4, complexity ≤ 20 | `eslint/max-*`, `eslint/complexity` |
| Cleanup preserves declarations, runtime exports and DMS auto-imports | `antelopejs-api-diff <base-ref>` |
| Comment-only changes preserve JavaScript emit | `antelopejs-comment-proof <base-ref>` |
| PR-body proof tables are copied unedited from the current head | `antelopejs-body-check <body.md>` |
| PR-body findings-left lines are live diagnostics at HEAD | `antelopejs-body-check <body.md>` |
| Receiver, positional and unpublished-module behaviour | `antelopejs-api-diff <base-ref> --probe <file.cjs>` |
| Directive and `SAFETY:` reasons are true of the code | review; no tool |
| Evasion-only and patched-internal findings go under Attention | review; no tool |
| No-upward rules reject same-tier peers | review and import probes |
| No `@ts-ignore` | `typescript/ban-ts-comment` |
| No once-used type parameter standing in for `unknown` | `typescript/no-unnecessary-type-parameters` |
| No `any` passed, assigned or returned where a type is declared | `typescript/no-unsafe-{argument,assignment,return}` |
| Files ≤ 20,000 bytes, tests and agent files included | `antelopejs-check-size` (pre-commit) |
| Suppressions stay within `guardrails.suppressions.json` | `antelopejs-suppressions` (pre-commit, checks) |
| No lint config switches off a rule to stay under the budget | `antelopejs-suppressions` (pre-commit, checks) |
| No added directive disables the `SAFETY:`, comment or test rules | `antelopejs-suppressions` (pre-commit, checks) |
| An added suppression gives a specific reason | `antelopejs-suppressions` (pre-commit, checks) |
| A directive in a file a change touches suppresses something and gives a reason | `antelopejs-suppressions` (pre-commit, checks) |
| A block disable is closed in its file | `antelopejs-suppressions` (pre-commit, checks) |
| Types check | `tsc` (pre-push) |
| No dead files, exports, or dependencies | knip |
| Managed files match the pack | `antelopejs-sync --check` |
| A CI gate reads `needs.<id>` only of jobs in its `needs` | `antelopejs-sync --check` |
| Entry-only rules exempt no tracked outsider | `antelopejs-sync --check` |
| A DMS layer's `build/backend-boundary.ts` is the pack's plugin | `antelopejs-sync --check` |
| No `skipLibCheck` in the root tsconfig or one `typecheck` or `build` uses | `antelopejs-sync --check` |
| `build` skips the lib check only over what `typecheck` checks | `antelopejs-sync --check` |
| `release` runs `typecheck` | `antelopejs-sync --check` |
| A test names the wrong implementation it catches | review; no tool |
| Rule | Enforced by |
| ---------------------------------------------------------------------------------- | --------------------------------------------------- |
| Formatting | oxfmt |
| Lint findings are errors; no rule warns | oxlint preset |
| Comments are TSDoc, directives, or `SAFETY:` only | `antelopejs/no-comments` |
| Every test asserts | `antelopejs/require-assertion` |
| Tests read no files outside fixtures, helpers, locales | `antelopejs/no-fs-read-in-tests` |
| Tests import the code under test from local source, not their own package name | `antelopejs/no-self-import-in-tests` |
| No assertion that restates a constant | `antelopejs/no-constant-value-assertion` |
| No test whose only check is "is a function" | `antelopejs/no-typeof-function-only-test` |
| String-keyed object tables are read through own keys only | `antelopejs/no-inherited-key-lookup` |
| A type guard checks each member it narrows to; keys with `Object.hasOwn` | `antelopejs/no-presence-only-type-guard` |
| A type guard checks the nested elements and values it claims | review; no tool |
| A startup read does not decide an insert another replica can race | `antelopejs/no-read-then-insert` |
| An async function or promise callback returns no unrun database query | `antelopejs/no-unrun-query` |
| `Object.assign` writes no `unknown`, `any` or mistyped value over a field | `antelopejs/no-unsafe-object-assign` |
| Every file type-aware lint reads is listed by a tsconfig that resolves its imports | `antelopejs/require-tsconfig-include` |
| Params ≤ 5, function ≤ 120 lines, file ≤ 500 lines, depth ≤ 4, complexity ≤ 20 | `eslint/max-*`, `eslint/complexity` |
| Cleanup preserves declarations, runtime exports and DMS auto-imports | `antelopejs-api-diff <base-ref>` |
| Comment-only changes preserve JavaScript emit | `antelopejs-comment-proof <base-ref>` |
| PR-body proof tables are copied unedited from the current head | `antelopejs-body-check <body.md>` |
| PR-body findings-left lines are live diagnostics at HEAD | `antelopejs-body-check <body.md>` |
| Receiver, positional and unpublished-module behaviour | `antelopejs-api-diff <base-ref> --probe <file.cjs>` |
| Directive and `SAFETY:` reasons are true of the code | review; no tool |
| Evasion-only and patched-internal findings go under Attention | review; no tool |
| No-upward rules reject same-tier peers | review and import probes |
| No `@ts-ignore` | `typescript/ban-ts-comment` |
| No once-used type parameter standing in for `unknown` | `typescript/no-unnecessary-type-parameters` |
| No `any` passed, assigned or returned where a type is declared | `typescript/no-unsafe-{argument,assignment,return}` |
| Files ≤ 20,000 bytes, tests and agent files included | `antelopejs-check-size` (pre-commit) |
| Suppressions stay within `guardrails.suppressions.json` | `antelopejs-suppressions` (pre-commit, checks) |
| No lint config switches off a rule to stay under the budget | `antelopejs-suppressions` (pre-commit, checks) |
| No added directive disables the `SAFETY:`, comment or test rules | `antelopejs-suppressions` (pre-commit, checks) |
| An added suppression gives a specific reason | `antelopejs-suppressions` (pre-commit, checks) |
| A directive in a file a change touches suppresses something and gives a reason | `antelopejs-suppressions` (pre-commit, checks) |
| A block disable is closed in its file | `antelopejs-suppressions` (pre-commit, checks) |
| Types check | `tsc` (pre-push) |
| No dead files, exports, or dependencies | knip |
| Managed files match the pack | `antelopejs-sync --check` |
| A CI gate reads `needs.<id>` only of jobs in its `needs` | `antelopejs-sync --check` |
| Entry-only rules exempt no tracked outsider | `antelopejs-sync --check` |
| A DMS layer's `build/backend-boundary.ts` is the pack's plugin | `antelopejs-sync --check` |
| No `skipLibCheck` in the root tsconfig or one `typecheck` or `build` uses | `antelopejs-sync --check` |
| `build` skips the lib check only over what `typecheck` checks | `antelopejs-sync --check` |
| `release` runs `typecheck` | `antelopejs-sync --check` |
| A test names the wrong implementation it catches | review; no tool |

<!-- antelopejs-guardrails:end -->
14 changes: 7 additions & 7 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -128,13 +128,13 @@ The package declares these `@antelopejs/*` peer dependencies.

<!-- antelopejs-docs-compat:start -->

| Package | Supported | Tested with |
| ------------------------------------------- | ----------------- | ----------- |
| `@antelopejs/interface-api` | `>=0.3.0 <1.0.0` | `0.2.0` |
| `@antelopejs/interface-api-util` | `>=0.1.3 <1.0.0` | `0.3.0` |
| `@antelopejs/interface-core` | `>=0.2.4 <1.0.0` | `0.5.1` |
| `@antelopejs/interface-database` | `>=0.1.10 <1.0.0` | `0.4.0` |
| `@antelopejs/interface-database-decorators` | `>=0.5.0 <1.0.0` | `0.5.2` |
| Package | Supported | Tested with |
| ------------------------------------------- | ---------------- | ----------- |
| `@antelopejs/interface-api` | `>=0.3.0 <0.4.0` | `0.3.2` |
| `@antelopejs/interface-api-util` | `>=0.3.0 <0.4.0` | `0.3.0` |
| `@antelopejs/interface-core` | `>=0.5.1 <0.6.0` | `0.5.1` |
| `@antelopejs/interface-database` | `>=0.4.0 <0.5.0` | `0.4.0` |
| `@antelopejs/interface-database-decorators` | `>=0.5.0 <0.6.0` | `0.5.2` |

<!-- antelopejs-docs-compat:end -->

Expand Down
18 changes: 9 additions & 9 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -71,14 +71,14 @@
"suppressions:update": "antelopejs-suppressions --update"
},
"devDependencies": {
"@antelopejs/api": "^1.7.0",
"@antelopejs/core": "~1.22.0",
"@antelopejs/interface-api": ">=0.2.0 <1.0.0",
"@antelopejs/api": "~1.7.0",
"@antelopejs/core": "~1.23.0",
"@antelopejs/interface-api": ">=0.3.0 <0.4.0",
"@antelopejs/interface-api-util": "^0.3.0",
"@antelopejs/interface-core": "^0.5.1",
"@antelopejs/interface-database": "^0.4.0",
"@antelopejs/interface-database-decorators": "^0.5.2",
"@antelopejs/tooling-configs": "^0.5.8",
"@antelopejs/tooling-configs": ">=0.6.0 <0.7.0",
"@types/chai": "^4.3.20",
"@types/mocha": "^10.0.10",
"@types/node": "^22.19.15",
Expand All @@ -98,11 +98,11 @@
"zod": "4.5.4"
},
"peerDependencies": {
"@antelopejs/interface-api": ">=0.3.0 <1.0.0",
"@antelopejs/interface-api-util": ">=0.1.3 <1.0.0",
"@antelopejs/interface-core": ">=0.2.4 <1.0.0",
"@antelopejs/interface-database": ">=0.1.10 <1.0.0",
"@antelopejs/interface-database-decorators": ">=0.5.0 <1.0.0"
"@antelopejs/interface-api": ">=0.3.0 <0.4.0",
"@antelopejs/interface-api-util": ">=0.3.0 <0.4.0",
"@antelopejs/interface-core": ">=0.5.1 <0.6.0",
"@antelopejs/interface-database": ">=0.4.0 <0.5.0",
"@antelopejs/interface-database-decorators": ">=0.5.0 <0.6.0"
},
"packageManager": "pnpm@10.33.0",
"antelopeJs": {
Expand Down
Loading
Loading