Skip to content

docs: Cherry-pick Fern release documentation build.#1033

Merged
saturley-hall merged 1 commit into
release/0.10.0from
0.10.0/fern-cherry-pick
Jun 4, 2026
Merged

docs: Cherry-pick Fern release documentation build.#1033
saturley-hall merged 1 commit into
release/0.10.0from
0.10.0/fern-cherry-pick

Conversation

@FrankD412

@FrankD412 FrankD412 commented Jun 4, 2026

Copy link
Copy Markdown
Contributor

Cherry-picks #1031 that fixes the release documentation publishing for Fern docs.

Summary by CodeRabbit

  • New Features

    • Added dry-run capability for documentation releases via the fern-release-dryrun make target.
  • Bug Fixes

    • Improved error handling for malformed API responses—now gracefully degrades and returns null instead of raising exceptions.
    • Dashboard plots now skip gracefully when required data is unavailable instead of failing.
  • Tests

    • Added comprehensive test coverage for error handling with malformed/missing data scenarios.
…1031)

Signed-off-by: Frank Di Natale <3429989+FrankD412@users.noreply.github.com>
Co-authored-by: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
@FrankD412 FrankD412 requested a review from saturley-hall June 4, 2026 02:20
@FrankD412 FrankD412 self-assigned this Jun 4, 2026
@copy-pr-bot

copy-pr-bot Bot commented Jun 4, 2026

Copy link
Copy Markdown

This pull request requires additional validation before any workflows can run on NVIDIA's runners.

Pull request vetters can view their responsibilities here.

Contributors can view more details about this message here.

@github-actions

github-actions Bot commented Jun 4, 2026

Copy link
Copy Markdown

Try out this PR

Quick install:

pip install --upgrade --force-reinstall git+https://github.com/ai-dynamo/aiperf.git@0f8791e850a235865be53b707e6c32ba72dfc9d2

Recommended with virtual environment (using uv):

uv venv --python 3.12 && source .venv/bin/activate
uv pip install --upgrade --force-reinstall git+https://github.com/ai-dynamo/aiperf.git@0f8791e850a235865be53b707e6c32ba72dfc9d2

Last updated for commit: 0f8791eBrowse code

@FrankD412 FrankD412 changed the base branch from main to release/0.10.0 June 4, 2026 02:23
@FrankD412 FrankD412 changed the title Cherry-pick Fern release documentation build. Jun 4, 2026
@github-actions github-actions Bot added the docs label Jun 4, 2026
@coderabbitai

coderabbitai Bot commented Jun 4, 2026

Copy link
Copy Markdown
Contributor

Review Change Stack

Caution

Review failed

Failed to post review comments

Walkthrough

This PR enhances resilience across three domains: OpenAI response parsing now degrades gracefully for malformed bodies, plot generation skips unavailable metrics without crashing, and the Fern documentation release workflow gains strict validation and local dry-run tooling for pre-publication snapshots.

Changes

Documentation Release Workflow and Tooling

Layer / File(s) Summary
Workflow dispatch input and release setup
.github/workflows/fern-docs.yml
Added force_rebuild boolean input to workflow_dispatch. Reworked release-version job to check out tagged source and initialize isolated docs-checkout worktree.
Content transformation, validation, and publish
.github/workflows/fern-docs.yml
Updated release to convert markdown from tagged commit using md_to_mdx.py, generate version config from tag's docs/index.yml, insert strict validation (broken-link checks) before push, and adjust publish step working directory.
Dry-run tool for local validation
Makefile, tools/fern_release_dryrun.sh
New fern-release-dryrun make target and standalone shell script for local, offline snapshot validation: rebuilds versioned pages, converts markdown, generates config, validates with Fern CLI, and reports success without authentication.

Graceful Degradation in OpenAI Response Parsing

Layer / File(s) Summary
Endpoint parsing behavior changes
src/aiperf/endpoints/openai_chat.py, src/aiperf/endpoints/openai_completions.py
Modified chat and completions endpoints to return None instead of raising ValueError for unrecognized OpenAI object field values, enabling soft degradation for arbitrary/error/proxy response bodies.
Endpoint unit test coverage
tests/unit/endpoints/test_chat_endpoint_parse_response.py, tests/unit/endpoints/test_completions_endpoint_parse_response.py, tests/unit/endpoints/test_openai_chat_attack.py
Added parametrized tests verifying endpoints return None for malformed bodies with missing or error-shaped object fields. Updated chat attack test to expect None instead of ValueError. Tests construct specific malformed payloads using orjson and pytest.param.
Parser integration tests for resilience
tests/unit/records/test_inference_result_parser.py
Added end-to-end test feeding malformed response payloads through real ChatEndpoint (not mocked). Verifies parser records failures as InvalidInferenceResultError without crashing and confirms no "Unsupported OpenAI object type" error messages appear.

Plot Generation Error Handling for Missing Data

Layer / File(s) Summary
Error handling in dashboard and exporter
src/aiperf/plot/dashboard/callbacks.py, src/aiperf/plot/exporters/png/single_run.py
Dashboard callbacks and PNG exporter now catch DataUnavailableError and KeyError during plot creation. Missing-data scenarios log at debug level and return None (dashboard) or skip export (exporter) instead of propagating errors.
Plot generation test coverage
tests/unit/plot/test_dashboard_callbacks.py, tests/unit/plot/test_png_exporter.py
Added fixtures for non-streaming runs and helper for plot specs. Dashboard tests verify missing-column requests return None with debug logging. PNG exporter test confirms missing metric columns are skipped without errors while other plots render successfully.

Estimated code review effort

🎯 3 (Moderate) | ⏱️ ~25 minutes

Poem

🐰 A rabbit hops through docs with care,
Graceful parsing floats on air,
Plots skip stones in data streams,
Release pipelines chase their dreams!
Soft degradation reigns supreme. 🚀

🚥 Pre-merge checks | ✅ 5
✅ Passed checks (5 passed)
Check name Status Explanation
Description Check ✅ Passed Check skipped - CodeRabbit’s high-level summary is enabled.
Title check ✅ Passed The title accurately describes the main objective: cherry-picking changes related to Fern release documentation build, which is confirmed by the commit messages and file changes focusing on release documentation workflow and related fixes.
Docstring Coverage ✅ Passed Docstring coverage is 87.50% which is sufficient. The required threshold is 80.00%.
Linked Issues check ✅ Passed Check skipped because no linked issues were found for this pull request.
Out of Scope Changes check ✅ Passed Check skipped because no linked issues were found for this pull request.

✏️ Tip: You can configure your own custom pre-merge checks in the settings.


Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share

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

@codecov

codecov Bot commented Jun 4, 2026

Copy link
Copy Markdown

Codecov Report

✅ All modified and coverable lines are covered by tests.

📢 Thoughts on this report? Let us know!

@saturley-hall saturley-hall merged commit bf70bd9 into release/0.10.0 Jun 4, 2026
21 of 27 checks passed
@saturley-hall saturley-hall deleted the 0.10.0/fern-cherry-pick branch June 4, 2026 02:35
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

2 participants