Skip to content

ci: check ReScript formatting and committed output - #1448

Open
fhammerschmidt wants to merge 2 commits into
masterfrom
fix/1421-rescript-ci
Open

fhammerschmidt wants to merge 2 commits into
masterfrom
fix/1421-rescript-ci

Conversation

@fhammerschmidt

@fhammerschmidt fhammerschmidt commented Oct 11, 2026 •

Copy link
Copy Markdown
Member

Pull requests could pass CI with unformatted ReScript or stale committed compiler output. Check ReScript formatting across all four workspaces and compare tracked JavaScript output after a clean build.

Fixes #1416 together with the unused-value/export gate in #1443. Part of #1421.

  • Extend yarn ci:format to run both Oxfmt and rescript format --check. Run the format commands from the monorepo root and delegate the docs workspace aliases to them, so guide sources are included too.
  • Add yarn ci:generated to the existing Site_Checks job. It cleans compiler artifacts, removes tracked compiler output identified by the generated-file header in Git's index, runs the strict ReScript build, and fails with a Git diff if tracked .jsx or .mjs output changes. Removing the output first also catches deleted or excluded sources; handwritten JavaScript is preserved.
  • Regenerate the guide's routes.jsx, which already differed from fresh compiler output, and document how to run and fix the checks.

Branch: fix/1421-rescript-ci, based on website master (v12), pushed directly to rescript-lang/rescript-lang.org. No compiler repository changes. The reanalyze gate stays in #1443; this PR covers the remaining formatting and generated-output checks.

Validation: Oxfmt and ReScript checks pass. Temporary formatting errors in both .res and .resi files were rejected in all four workspaces, and restored sources pass. The generated-output diff rejected the existing stale guide output; after regeneration, a second clean build passes with no tracked JavaScript differences. Additional real-build probes reject orphaned output after deleting a source/interface pair and after excluding the guide workspace from the build. All temporary source/configuration changes were restored; the final clean build matches all tracked JavaScript, and strict compilation succeeds for all 585 modules. The latest CI run passes both the formatting job and the corrected generated-output step; the remaining jobs are still running.

Check ReScript formatting across all workspaces alongside Oxfmt. Clean and rebuild before comparing tracked JavaScript output, refresh guide routes output, and share the root format commands with the docs workspace.

Refs #1416 and #1421.
@chatgpt-codex-connector

chatgpt-codex-connector Bot commented Oct 11, 2026 •

Copy link
Copy Markdown

Codex Review Summary

This comment shows the latest Codex review activity on this pull request.

Review Status Commit Review trigger
📝 Code Review ✅ Completed 2026-10-11T22:45:36.023304Z aa47e87 PR opened
ℹ️ 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" or "@codex security review".

Codex reacts with 👀 while any review is running, comments if it has suggestions, and reacts with 👍 once all reviews finish with no findings.

@cloudflare-workers-and-pages

cloudflare-workers-and-pages Bot commented Oct 11, 2026 •

Copy link
Copy Markdown

Deploying with  Cloudflare Workers  Cloudflare Workers

The latest updates on your project. Learn more about integrating Git with Workers.

Status Name Latest Commit Preview URL Updated (UTC)
✅ Deployment successful!
View logs
guide 48b1988 Commit Preview URL

Branch Preview URL
Oct 11 2026, 10:52 PM

@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: aa47e87128

ℹ️ 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 package.json Outdated
@github-actions

github-actions Bot commented Oct 11, 2026 •

Copy link
Copy Markdown
Contributor

Lighthouse baseline

Compared with target branch master at commit a62233b. Scores are the median of 3 runs against the deployed Cloudflare preview.

Category Target Current Change
Performance 84 87 +3
Accessibility 80 80 0
Best practices 100 100 0
SEO 92 58 -34

Download the full Lighthouse reports and baseline

Commit 22aa61e · Cloudflare preview

Remove compiler-generated tracked files identified by their committed header before rebuilding. Preserve handwritten JavaScript and detect output whose source was deleted or whose workspace was excluded from the build.
@github-actions

Copy link
Copy Markdown
Contributor

Docs preview

This branch was successfully deployed

2 active deployments
preview — 48b19884 Deployed Oct 11, 2026 by github-actions[bot]
guide-preview — 48b19884 Deployed Oct 11, 2026 by github-actions[bot]
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.

No CI check for ReScript formatting, reanalyze, or committed generated files

1 participant