← Back to Pull requests

ci: separate docs build from site publishing #7386

Open
unknown opened this pull request with 284 lines diff across 3 files
View on GitHub
unknown unknown commented on Nov 01, 2026 17:27 UTC
Author

Which issue does this PR close?

Closes #7320.

Rationale for this change

The docs build installs and runs dependencies in the same job that can push to the repository. A separate writer keeps the repository write token out of the dependency build. This does not make the generated site trustworthy: a compromised builder can still change the output that is published.

What changes are included in this PR?

  • Narrow the build job to contents: read and disable checkout credential persistence. Keep the existing source and rendered Mermaid checks before publishing.

  • Upload the built site and its .asf.yaml and .nojekyll as an artifact. A fresh job with contents: write checks out asf-site, downloads the artifact, and runs only the existing static copy and publication path. The caller's write permission and its main-branch guard remain unchanged.

  • Preserve .git during the rsync --delete, explicitly copy .asf.yaml after rsync, and touch .nojekyll, as the old publication step did. Explicitly copying the metadata matters even when old and new files have the same size and mtime.

  • Add CI configuration checks for the permission split and a disposable site-copy regression test to preflight. The slim preflight image installs rsync for that test.
  • How are these changes tested?

  • python3 dev/ci/check-ci-config.py passed. A separate local mutation check rejected changes to the build permission, persisted credentials, build dependency, hidden-file setting, and deploy download action.

  • python3 dev/ci/test-docs-site-copy.py passed against synthetic files: .git was retained, stale output removed, and .asf.yaml, .nojekyll, and the new page were present. Before restoring the explicit metadata copy, the same-size/same-mtime fixture showed that rsync could retain the old .asf.yaml.

  • actionlint -shellcheck=off and git diff --check passed.

  • No workflow was dispatched and no site or production service was modified. The actual GitHub artifact transfer and deploy have not been run end to end.

  • The contributor guide's make format and make passed on this head in an isolated Linux/JDK 17 environment. The first format attempt failed while downloading an Iceberg dependency (truncated response); one retry succeeded.
  • Diff: 284 lines (+213 / -71) across 3 files Reviewer: comphead Review duration: 4698m
    All Vouch review confidence checks passed
    Residual risk 0.21 = Change Risk (0.40) × (1 − Review Confidence (0.47)). Review depth and reviewer attention state are adequate.
    Model 1 · Change Risk (XGBoost)
    Score: 0.40 · 284 lines diff across 3 files
    0.40
    Model 2 · Review Depth (DistilBERT)
    Depth Score: 0.02 · 1 substantive comment(s)
    0.02
    Model 3 · Review Timing & Attention
    Session adequacy: 100% · Reviewer familiarity: 35%
    46%
    Bedrock Claude 3 · Risk Narration
    (disconnected)
    Groq
    Groq Risk Narration
    AWS Bedrock is currently disconnected. Generate high-confidence PR triage narration on-demand using Groq.
    Model 1 · Change Risk Attribution
    SHAP Weights
    Shallow Review Depth shallow_review_depth
    0.344
    Diff Size diff_size
    0.338
    Real PR Conversation Timeline
    1 comments
    "Review active on #7386"
    general weight: 0.35
    Reviewers
    Assignees
    Unassigned
    Labels
    risk: low confidence: 46.7% reviewed
    Vouch Risk Breakdown
    AI-powered review risk analysis
    Change Risk
    Change Risk · Model 1 (XGBoost)
    Predicted defect probability (0.00–1.00) based on diff churn, modified sensitive files, and author risk history.
    Score: 39.7% (MEDIUM) · Higher = larger blast radius
    39.7%
    Review Confidence
    Review Confidence · Models 2 & 3
    Scrutiny score (0.00–1.00) combining DistilBERT semantic review depth with reviewer familiarity and session dwell time.
    Score: 46.7% · Lower = rushed or shallow review
    46.7%
    Residual Risk
    Residual Risk · Core Equation
    Residual = Change × (1 − Confidence)
    Unmitigated risk surviving review. ≥ 0.65 triggers an automated re-queue to protect production.
    Score: 21.2% · Safe to merge
    21.2%