Skip to content

Add a zero-tolerance TypeDoc documentation gate#47

Open
leynos wants to merge 2 commits into
mainfrom
typedoc-rollout
Open

Add a zero-tolerance TypeDoc documentation gate#47
leynos wants to merge 2 commits into
mainfrom
typedoc-rollout

Conversation

@leynos

@leynos leynos commented Jul 17, 2026

Copy link
Copy Markdown
Owner

Summary

This branch adds a zero-tolerance TypeDoc documentation gate to
make all. TypeDoc's notDocumented validation runs over the package
entry point (src/index.ts, resolve strategy) with emit: "none"
and warnings treated as errors: every declaration in the public surface
must carry a JSDoc comment. The gate reports the qualified name of each
undocumented declaration, writes no documentation artefacts, and fails
on a single omission. CI already runs make all, so it reaches the
gate with no workflow changes.

A small preparatory commit fixes a pre-existing Oxford-spelling
violation in AGENTS.md that the shared typos base now flags.

Review walkthrough

  • Start with typedoc.json
    for the gate's configuration, then the
    Makefile
    and package.json
    for the wiring: docs-check sits between typecheck and lint in
    make all (after typecheck so the generated GraphQL types exist).
  • The documentation itself:
    src/simulation.ts
    (the GitHubSimulatorArgs surface) and the zod schema constants under
    src/store/entities/,
    each tagged with a documented /** … @internal */ block so TypeDoc
    does not recurse into their inferred field types — the named
    GitHub* output types remain the public vocabulary.
  • src/index.ts
    converts the entry header from @file (unknown to TypeDoc) to the
    @module form, preserving the description.
  • docs/developers-guide.md
    documents the local command.

Validation

  • make all (check-fmt, typecheck, docs-check, lint, test,
    spelling): exit 0.
  • Mutation check: deleting the JSDoc line from the exported
    InitialState alias makes bun run docs:check exit 4 naming the
    symbol; restoring it returns the gate to green.
  • A clean docs:check run emits no files and no output.

Notes

leynos added 2 commits July 18, 2026 00:06
Add `docs-check` to `make all`: TypeDoc's `notDocumented` validation
over the package entry point (`src/index.ts`, `resolve` strategy,
`emit: "none"`, warnings as errors), configured by `typedoc.json` and
run through `bun run docs:check`. The gate requires 100% documentation
of the public surface, reports the qualified name of each undocumented
declaration, and writes no documentation artefacts. CI already runs
`make all`, so the gate needs no workflow changes.

Document the public surface to match: the `GitHubSimulatorArgs` members
in `src/simulation.ts`, and the zod schema constants tagged with
documented `/** … @internal */` blocks so TypeDoc does not recurse into
their inferred field types — their meaning is carried by the named
`GitHub*` output types. Convert the entry point's `@file` header to
TypeDoc's `@module` form (TypeDoc does not know the `@file` tag).

@sourcery-ai sourcery-ai Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Sorry @leynos, you have reached your weekly rate limit of 500000 diff characters.

Please try again later or upgrade to continue using Sourcery

@coderabbitai

coderabbitai Bot commented Jul 17, 2026

Copy link
Copy Markdown

Warning

Review limit reached

You’ve reached a temporary PR review limit under our Fair Usage Limits Policy.

Your recent review volume is higher than typical usage, so adaptive limits are currently applied.

Next review available in: 50 seconds

Enable usage-based reviews in Billing to review now. Otherwise, wait until the next included review is available.
You're only billed for reviews past your plan's rate limits ($0.25/file).

How can I continue?

After more reviews become available, a review can be triggered using the @coderabbitai review command as a PR comment. Alternatively, push new commits to this PR.

To avoid repeated limits, reduce automatic review volume by pausing incremental auto-reviews earlier, using label-based review opt-in, excluding WIP or generated PR titles, or requesting reviews manually when the PR is ready. If your team needs uninterrupted high-volume reviews, an organization admin can enable usage-based reviews.

How do review limits work?

CodeRabbit enforces per-developer PR review limits for each organization. Most developers receive the normal plan review availability.

For paid Pro and Pro+ PR reviews, CodeRabbit uses adaptive limits for sustained high-volume activity. When a developer's recent PR review activity reaches the 95th percentile or higher among CodeRabbit users, additional reviews become available more gradually as earlier reviews age out of the rolling window.

Please refer docs for additional details.

Review details
⚙️ Run configuration

Configuration used: Organization UI

Review profile: ASSERTIVE

Plan: Pro Plus

Run ID: d7e58792-cb97-4c6a-93f7-629db58f336a

📥 Commits

Reviewing files that changed from the base of the PR and between 0d1208a and 453c40e.

⛔ Files ignored due to path filters (1)
  • bun.lock is excluded by !**/*.lock
📒 Files selected for processing (13)
  • AGENTS.md
  • Makefile
  • docs/developers-guide.md
  • package.json
  • src/index.ts
  • src/simulation.ts
  • src/store/entities.ts
  • src/store/entities/blob.ts
  • src/store/entities/branch.ts
  • src/store/entities/organization.ts
  • src/store/entities/repository.ts
  • typedoc.json
  • typos.toml
✨ Finishing Touches
🧪 Generate unit tests (beta)
  • Create PR with unit tests
  • Commit unit tests in branch typedoc-rollout

Comment @coderabbitai help to get the list of available commands.

@chatgpt-codex-connector chatgpt-codex-connector Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

💡 Codex Review

Here are some automated review suggestions for this pull request.

Reviewed commit: 453c40e42d

ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review".

If Codex has suggestions, it will comment; otherwise it will react with 👍.

Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".

Comment thread Makefile
Comment on lines +22 to +23
docs-check:
bun run docs:check

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

P2 Badge Make docs-check depend on typecheck

On a clean checkout, make docs-check reaches TypeDoc before check:types generates the ignored src/__generated__/resolvers-types.ts, which is transitively imported from the package entry point via simulation and src/graphql/resolvers.ts; TypeDoc therefore fails on the missing module rather than checking documentation. The same race occurs under make -j all because listing typecheck before docs-check does not establish a dependency between them (make --help confirms that -j allows multiple jobs at once). Declare typecheck as a prerequisite of this target so standalone and parallel gate runs are reliable.

Useful? React with 👍 / 👎.

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