Skip to content

Generate deterministic, readable OpenAPI JSON - #1687

Open
Cedric Vidal (cedricvidal) wants to merge 3 commits into
mainfrom
copilot/generate-deterministic-openapi-json
Open

Cedric Vidal (cedricvidal) wants to merge 3 commits into
mainfrom
copilot/generate-deterministic-openapi-json

Conversation

@cedricvidal

@cedricvidal Cedric Vidal (cedricvidal) commented Nov 19, 2026 •

Copy link
Copy Markdown
Collaborator

The minified website OpenAPI schema turns small API edits into whole-document diffs. This change introduces stable, line-oriented output so schema changes remain localized.

  • Serialization: Share one serializer between generation and snapshot comparison: recursively sorted object keys, preserved array order, two-space indentation, LF endings, and a trailing newline.
  • Regression coverage: Enforce exact formatting, deterministic output across insertion orders, content preservation, and localized schema diffs.
  • Migration: Regenerate the committed website schema without changing its parsed OpenAPI content; document the serialization contract.

Co-authored-by: copilot-swe-agent[bot] <198982749+Copilot@users.noreply.github.com>
@cedricvidal Cedric Vidal (cedricvidal) changed the title [WIP] Generate deterministically indented OpenAPI JSON to minimize diff churn Generate deterministic, readable OpenAPI JSON Nov 19, 2026
@cedricvidal
Cedric Vidal (cedricvidal) marked this pull request as ready for review November 19, 2026 17:16
…generate-deterministic-openapi-json

# Conflicts:
#	website/src/openapi/scope-openapi.json

Co-authored-by: copilot-swe-agent[bot] <198982749+Copilot@users.noreply.github.com>
@github-actions github-actions Bot added type: documentation Documentation additions, corrections, and improvements. language: javascript Work involving JavaScript code, tooling, or dependencies. topic: testing Test coverage, test infrastructure, and validation quality. topic: ui Portal, visual presentation, layout, and interface components. labels Nov 19, 2026
@github-actions

Copy link
Copy Markdown

Test Results (Node.js 22)

test: Run #606

Tests 📝 Passed ✅ Failed ❌ Skipped ⏭️ Pending ⏳ Other ❓ Flaky 🍂 Duration ⏱️
3343 3343 0 0 0 0 0 1m4s

🎉 All tests passed!

Github Test Reporter

This branch has not been deployed

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

Labels

language: javascript Work involving JavaScript code, tooling, or dependencies. topic: testing Test coverage, test infrastructure, and validation quality. topic: ui Portal, visual presentation, layout, and interface components. type: documentation Documentation additions, corrections, and improvements.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Generate deterministically indented OpenAPI JSON to minimize diff churn

2 participants