Skip to content

docs: implement publishing pipeline (#617)#646

Merged
planetf1 merged 24 commits intomainfrom
dev/jonesn/docs-publish-pipeline
Mar 13, 2026
Merged

docs: implement publishing pipeline (#617)#646
planetf1 merged 24 commits intomainfrom
dev/jonesn/docs-publish-pipeline

Conversation

@planetf1
Copy link
Contributor

@planetf1 planetf1 commented Mar 13, 2026

docs: implement publishing pipeline

Note: Replaces #644 — recreated from an upstream branch so that the
docs-preview label can trigger a full deploy to docs/preview for
pipeline validation (fork PRs lack write access to push deployment branches).

Type of PR

  • Bug Fix
  • New Feature
  • Documentation
  • Other

Description

Fixes #617

This PR completes the end-to-end documentation publishing pipeline for
Mellea.
From a single push to main, the full Mintlify docs site —
hand-authored guides plus generated API reference — is automatically built,
validated, and deployed. Reviewers can now see live docs at the staging
environment without any manual steps.

Live preview: While this PR is open, the pipeline is publishing to
https://ibm-llm-runtime-aaf3a78b.mintlify.app/ via the Mintlify staging
configuration (pointing at docs/preview). This is temporary — once merged,
staging will track main via docs/staging.

See docs/PUBLISHING.md for the full architecture, branch strategy, and local development workflow.

Job summary output: Checks tab → any Docs run → Summary. Example: https://github.com/generative-computing/mellea/actions/runs/23064193854

Example docs job summary output

Screenshot 2026-03-13 at 18 17 32

Changes

  • docs-publish.yml — new unified workflow (replaces docs-autogen-pr.yml). Deploys to docs/staging, docs/production, or docs/preview depending on trigger. Soft-fail validation by default; rich job summaries on every run.
  • quality.yml — additive only: job summary with pre-commit outcome and test pass/fail counts.
  • .pre-commit-config.yaml — MDX validation hook (normal flow) + docstring quality hook (manual-only pending ci: gate doc quality in CI and pre-commit to prevent future degradation #616).
  • audit_coverage.py — fix false-positive GHA annotation; remove noisy per-item annotations.
  • docs/PUBLISHING.md — design doc: architecture, branch strategy, local dev, Mintlify config.

Dependencies

Both prerequisites have merged:

Follow-on

Testing

  • Tests added to the respective file if code was changed
  • New code has 100% coverage if code as added
  • Ensure existing tests and github automation passes (a maintainer will kick off the github automation when the rest of the PR is populated)

Testing plan:

  • docs-preview label is already applied — verify Docs workflow builds,
    validates, and deploys to docs/preview successfully.
  • Review job summaries on the Docs and Run CI checks (Checks tab above).
  • Browse the live preview at https://ibm-llm-runtime-aaf3a78b.mintlify.app/
  • Flip strict_validation via workflow_dispatch when ready to test hard failures.

@planetf1 planetf1 requested a review from a team as a code owner March 13, 2026 14:51
@planetf1 planetf1 added the docs-preview Deploy docs to docs/preview branch for pipeline validation label Mar 13, 2026
@mergify
Copy link

mergify bot commented Mar 13, 2026

Merge Protections

Your pull request matches the following merge protections and will not be merged until they are valid.

🟢 Enforce conventional commit

Wonderful, this rule succeeded.

Make sure that we follow https://www.conventionalcommits.org/en/v1.0.0/

  • title ~= ^(fix|feat|docs|style|refactor|perf|test|build|ci|chore|revert|release)(?:\(.+\))?:

@planetf1
Copy link
Contributor Author

planetf1 commented Mar 13, 2026

Publishing is now running.

This PR is tagged with docs-preview. This causes the build process to publish to the docs/preview branch (there are no checks preventing clashes - this is just an occasional exception to help with testing)

Mintlify has temporarily been updated to publish automatically from this docs/preview / to https://ibm-llm-runtime-aaf3a78b.mintlify.app/

Normally a PR will just do validation, but not publish

@HendrikStrobelt you may want to take a look. Focus is on the process - and only content that fundamentally breaks the process. General content changes can be in other PRs. Issues already open in a few areas, docstrings, and a catchup of changes made over last 1-2 weeks.

I have more things to fix/consolidate in the pipeline, check reported soft-errors etc - just a heads up that we have the core of the end-end process

Add docs-publish.yml workflow that builds, validates, and deploys
docs to orphan deployment branches (docs/staging from main,
docs/production from releases). Replaces docs-autogen-pr.yml.

Includes pre-commit hooks for MDX validation and docstring quality,
docs/PUBLISHING.md strategy document, and .gitignore entries for
generated API docs.

Validation is soft-fail by default with strict_validation toggle.
workflow_dispatch supports force_publish for testing.
Safer default for manual dispatch — testing deploys to docs/preview
rather than docs/staging. The automatic paths (push→staging,
release→production) are unaffected.
PRs with the 'docs-preview' label deploy to docs/preview branch.
PRs without the label only run build + validation (no deploy).
Also triggers on 'labeled' event so adding the label fires the workflow.
Update PUBLISHING.md with docs/preview branch, label-based PR
deployment, and updated manual dispatch instructions.
Fork PRs can't deploy because GITHUB_TOKEN lacks write access to
upstream. Documented the workaround (manual dispatch or push to
upstream). Fixed MD032 blank line warnings.
@planetf1 planetf1 force-pushed the dev/jonesn/docs-publish-pipeline branch from 3aa4f3d to b38140b Compare March 13, 2026 16:11
Copy link
Member

@psschwei psschwei left a comment

Choose a reason for hiding this comment

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

In general, this all makes sense to me and I'm on board.
will hold off on approval in case others want to chime in

markdownlint is already in Docs/build-and-validate with proper path
filtering. Running it in ci.yml on every PR regardless of changed
files was wasteful and duplicated.
Each validation step now tees its output to a temp log file. A final
"Write job summary" step in both workflows writes a markdown table to
$GITHUB_STEP_SUMMARY showing pass/fail per sub-check with key stats
(lint issues, coverage %, symbol counts, test pass/fail counts).

Collapsible <details> blocks include the full output for deeper
inspection without cluttering the summary view.
github-actions bot added a commit that referenced this pull request Mar 13, 2026
github-actions bot added a commit that referenced this pull request Mar 13, 2026
github-actions bot added a commit that referenced this pull request Mar 13, 2026
github-actions bot added a commit that referenced this pull request Mar 13, 2026
…e action versions

audit_coverage.py emitted 'All documented symbols pass quality checks'
even when --quality was not passed (quality_issues always [] without
the flag). Now emits 'skipped' when --quality is absent, so the
annotation is accurate.

Add --quality to the CI audit step so quality is actually run and
surfaced in the job summary.

Update actions to latest versions (Node.js 24 compatible):
- actions/checkout v4 → v6
- astral-sh/setup-uv v5 → v7
- actions/upload-artifact v4 → v7
- actions/download-artifact v4 → v8
github-actions bot added a commit that referenced this pull request Mar 13, 2026
- Split quality row into proper Result/Details columns matching table header
- Strip 'run locally' from annotation message (we run it in CI now)
- Add separate 'Docstring quality details' collapsible extracted from
  the coverage log so quality issues are easy to expand inline
github-actions bot added a commit that referenced this pull request Mar 13, 2026
github-actions bot added a commit that referenced this pull request Mar 13, 2026
Individual annotations per missing docstring don't point to diff lines
so they just create noise in the Annotations panel (14+ entries). The
single summary annotation and the job summary collapsible provide
sufficient visibility. Consistent with markdownlint and MDX validation
which only emit one top-level result, not per-issue annotations.
github-actions bot added a commit that referenced this pull request Mar 13, 2026
…re-commit hook

- Strip ANSI escape codes from captured logs before writing to GITHUB_STEP_SUMMARY
  so collapsible sections render as clean text rather than raw escape sequences
- Move docs-docstring-quality pre-commit hook to stages: [manual] with a TODO
  pointing to #616 — Griffe loads the full package (~10s) which is too slow for
  normal commit flow; re-enable once quality issues reach 0
- CI audit still checks all symbols including methods (no --no-methods) so the
  job summary reports the full picture; hard-fail deferred to #616
github-actions bot added a commit that referenced this pull request Mar 13, 2026
- MDX Validation row now shows per-check error counts (e.g. "1 syntax error(s),
  2 broken link(s)") instead of just PASS/FAIL
- Markdownlint row already showed issue count; API Coverage row shows pct + symbols
- Fix: coverage log is split at the quality section boundary so the docstring
  quality details collapsible no longer duplicates the coverage output
github-actions bot added a commit that referenced this pull request Mar 13, 2026
@planetf1
Copy link
Contributor Author

@planetf1
Copy link
Contributor Author

planetf1 commented Mar 13, 2026

#614 should address many (not all) of the issues reported in the current checks.

I suggest we now get this PR reviewed/merged -- and Monday I'll revisit 614 & finish out the discussion on doc string formatting. If that changes the requirements of the parsers here will update then. One step forward.... it's a bit iterative - but we'll converge!

@planetf1 planetf1 enabled auto-merge March 13, 2026 17:53
@planetf1 planetf1 requested a review from psschwei March 13, 2026 17:56
github-actions bot added a commit that referenced this pull request Mar 13, 2026
@planetf1
Copy link
Contributor Author

Note the job summary I mentioned above had truncated output. That's been fixed ( see https://github.com/generative-computing/mellea/actions/runs/23063949076?pr=646 )

There may be improvements to the reports - but can defer to later.

@planetf1 planetf1 requested a review from nrfulton March 13, 2026 18:07
@planetf1 planetf1 assigned jakelorocco and unassigned jakelorocco Mar 13, 2026
github-actions bot added a commit that referenced this pull request Mar 13, 2026
github-actions bot added a commit that referenced this pull request Mar 13, 2026
Copy link
Member

@psschwei psschwei left a comment

Choose a reason for hiding this comment

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

LGTM

@planetf1 planetf1 added this pull request to the merge queue Mar 13, 2026
Merged via the queue into main with commit 0c5d9c9 Mar 13, 2026
7 checks passed
@planetf1
Copy link
Contributor Author

Updated mintlify so we are now publishing to the staging branch and url from merges to main

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

Labels

docs-preview Deploy docs to docs/preview branch for pipeline validation

Projects

None yet

Development

Successfully merging this pull request may close these issues.

docs: implement publishing pipeline

3 participants