Skip to content

fix: publish complete versioned docs across languages - #103

Merged
Germey merged 4 commits into
mainfrom
codex/docs-sync-integrity-20261004
Oct 4, 2026
Merged

Germey merged 4 commits into
mainfrom
codex/docs-sync-integrity-20261004

Conversation

@acedatacloud-dev

@acedatacloud-dev acedatacloud-dev commented Oct 4, 2026 •

Copy link
Copy Markdown
Member

Problem and resulting behavior

Docs could report successful synchronization while missing independent guides, preserving stale translations and skipping non-Chinese MCP. Duplicate events could race to push or replay old source, and generated links/MDX could be invalid.

Reuse the existing GET /api/v1/documents/?lang=...&limit=...&offset=... list and its additive content_source metadata from https://github.com/AceDataCloud/PlatformBackend/pull/2072. No new endpoint or export mode is required. The consumer supplies the normal primary-site Origin, follows pagination, checks source/content hashes and exact-language status, and rejects missing metadata or inconsistent pages. Independent Text guides and MCP are consumed directly instead of inferred from API siblings.

Reconcile all 18 existing locale directories, honor public visibility, and publish generated navigation/API indexes atomically. Pending translations stay explicitly incomplete, even when an existing page is retained. Resolve source-relative and platform-relative links, preserve code/math, and validate every page's MDX and local links before pushing. Editorial locale paths and outdated entry points are repaired; fixed credit-conversion claims are replaced with the package-derived rule.

The workflow has one serialized writer, verifies current-main source/event ancestry, reconciles hourly, and retains per-page completeness reports.

Validation

  • Python compilation and 48 Python tests passed, including existing-list pagination, primary-site headers, metadata requirements, privacy, source races, rollback and repeatable reconciliation.
  • 4 MDX/math/link tests passed.
  • Read-only production-data replay using the existing list response shape: 18 languages, 544 public documents per language, 35 public OpenAPI specs. All 4,030 preview pages passed MDX/local-link validation, and Mintlify reported no broken links.
  • Missing/stale translations and source versions not yet deployed were held explicitly (61/3,942 page versions in the captured snapshot), returning exit 2 rather than claiming complete synchronization.
  • The local private denylist was unavailable; the report marks that check unverified. Actual publication still requires the configured secret and sanitization safeguards.
  • Review focused on compatibility with the existing list, source versions, public visibility, current-main ordering and page/link integrity.

Deployment order

Deploy Backend PR #2072, then merge this consumer. Missing metadata aborts until the producer is updated. No production records were modified and no generated backfill was hand-edited; the normal publication workflow generates pages from the existing document list.

@Germey
Germey merged commit 07b18a9 into main Oct 4, 2026
1 check passed
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.

2 participants