Skip to content

Docs: regenerate the Vortex and SQLite format pages and remove docs/_migration - #130608

Merged
3 commits merged into
ClickHouse:masterfrom
groeneai:docs/vortex-sqlite-format-pages
Nov 17, 2026
Merged

3 commits merged into
ClickHouse:masterfrom
groeneai:docs/vortex-sqlite-format-pages

Conversation

@groeneai

@groeneai groeneai commented Nov 10, 2026 •

Copy link
Copy Markdown
Collaborator

Related: #130423
Related: #130234

Changelog category (leave one):

  • Documentation (changelog entry is not required)

Changelog entry (a user-readable short description of the changes that goes into CHANGELOG.md):

The Vortex format page now documents that String columns are written as Utf8 and the output_format_vortex_string_as_string setting.

Description

The Vortex format page still says that String columns are written as Binary, although master writes Utf8 since #130234 (flagged in #130423 (comment)). The nightly docs generator never regenerated it: autogenerate_docs.py found its pages and their destinations through docs/_migration/slug-map.csv, and pages added later (Vortex, SQLite) were skipped without an error.

Change, as asked in review, so the generator no longer reads docs/_migration:

  • every generator names its Mintlify page and the page's former Docusaurus path, which relative links in the source registrations are written against;
  • the eight page families (table and database engines, data types, formats, table and window functions, dictionary sources and layouts) discover their pages by walking their reference/ directory;
  • the Markdown to MDX transforms the generator uses move next to it as mintlify_transform.py, unchanged except that they take the docs root from Lookups; the migration driver, its per-page overrides and the transforms no current registration triggers are dropped;
  • legacy links resolve through the docs tree and docs/_site/redirects.json;
  • docs/_migration is deleted, with its exclusions in navigation_check.py, lychee.toml and docs/README.md.

Validation: full --write runs of the old and the new generator, with the same master binary, write the same 1131 files with identical content, except one link in ODBCDriver2.mdx: /concepts/features/interfaces/odbc becomes /concepts/features/interfaces/odbc/index, because that page moved to odbc/index.mdx after its slug-map row was written. Vortex, SQLite and ODBCDriver2 are regenerated here. Internal links, redirects and navigation checks pass.

Four open PRs that add slug-map rows will conflict on the deleted file; dropping the row is enough, since their pages are found from the directory.

This PR changes generated regions, so the Docs check needs the pr-autogenerated-docs label.

🤖 Generated with Claude Code


Workflow [PR]
Sync PR [sync-upstream/pr/130608]

Version info

  • Merged into: 26.11.1.2511-master (included in 26.11 and later)

The format page generator (`format_generators` in
`ci/jobs/scripts/docs/autogenerate/autogenerate_docs.py`) discovers pages
only through the matched rows of `docs/_migration/slug-map.csv`. Neither
`reference/formats/Vortex.mdx` nor `reference/formats/SQLite.mdx` had a
row, so the nightly docs job never regenerated them and `Vortex.mdx` still
described the `String` mapping from before ClickHouse#130234 (written as `Binary`,
no `output_format_vortex_string_as_string` row).

Add the two rows in the shape of the Puffin rows and regenerate both pages
with the generator (`--write --only format:Vortex` / `format:SQLite`).
The SQLite page change is the generator's link rewrite of the database
engine link to its current path.

Co-Authored-By: Claude Opus 5.5 <[email protected]>
@groeneai

Copy link
Copy Markdown
Collaborator Author
Internal second-model review: adjudication log (click to expand)

Pre-publication review by an independent model (engine: codex; 0 findings), plus my own review (2 nits).

# Sev Finding Verdict Evidence / action
1 💡 format_generators still finds format pages only through docs/_migration/slug-map.csv, so a new format page without a row is skipped silently AGREE, not changed A slug-map row is how pages are registered today (Puffin rows, timeSeriesTimeRanges); after this PR no page with generated regions in the slug-map-driven families lacks a row
2 💡 The new rows follow the Puffin rows (empty hash and date columns) rather than the full shape of the older rows AGREE, not changed No effect on generation: after --write, --check exits 0 for both pages

Severity: ❌ blocker / ⚠️ major / 💡 nit.

Session id: cron:clickhouse-review-slot-9:20261110-200200

@groeneai

Copy link
Copy Markdown
Collaborator Author

cc @dhtclk, could you review this? Registers the Vortex and SQLite format pages in docs/_migration/slug-map.csv so the nightly docs job regenerates them, and includes the regenerated pages.

@mintlify

mintlify Bot commented Nov 10, 2026 •

Copy link
Copy Markdown
Contributor

Preview approval required

This pull request comes from a fork, so Mintlify won't build a preview until someone with write access approves commit 9769069.

Approve preview

@groeneai

Copy link
Copy Markdown
Collaborator Author
Pre-PR validation gate (click to expand)
# Question Answer
a Deterministic repro? Yes. On master, autogenerate_docs.py --check --docs-dir docs --only format:Vortex (and format:SQLite) exits 1 with "matched no generator"; the mapped format:Puffin is selected.
b Root cause explained? format_generators discovers format pages only through matched rows of docs/_migration/slug-map.csv. Both pages had no row, so the nightly job never regenerated them and Vortex.mdx kept the String mapping from before #130234.
c Fix matches root cause? Yes. The missing registration is the defect: two data rows, no generator change. The page content is the generator's output, not a hand edit.
d Test intent preserved / new tests added? No new test: docs data only. The generator's own --check covers both pages from now on.
e Both directions demonstrated? Yes. Before: no generator, and the format-family --check lists neither page. After the rows: exactly these two pages drift. After --write: --check exits 0.
f Fix is general across code paths? Yes. Among pages with generated regions in the slug-map-driven families, only these two lacked a row; database engine pages are discovered from their directory.
g Fix generalizes across inputs (params/datatypes/wrappers)? The format-family --check shows the other 100 format pages unchanged, so the new rows alter no other page's output.
h Backward compatible? (maintainer-approved exception only) Yes. Docs data only; no settings or format changes.
i Invariants and contracts preserved? The CSV parses (2049 rows) with the rows at their sorted positions; edits stay inside the generated regions; internal links and anchors, navigation, snippet imports and read-only copies checks pass.

Session id: cron:clickhouse-impl-slot-7:20261110-195000

@clickhouse-gh

clickhouse-gh Bot commented Nov 10, 2026 •

Copy link
Copy Markdown
Contributor

Workflow [PR], commit [9769069]

Summary: ❌

job_name test_name status info comment
Docs check (Mintlify) FAIL
No direct edits to generated or read-only docs FAIL cidb

AI Review

Summary

The PR restores regeneration of the Vortex and SQLite format pages, discovers reference pages from the current documentation tree, and replaces the migration-folder dependency with local MDX transforms and site redirects. No actionable regressions found in the current code or diff.

Missing context / blind spots
  • ⚠️ Full binary-driven regeneration was not repeated locally because this checkout has no ClickHouse binary. The author's reported comparison supplies that evidence; repeating both generators with the same master binary would independently verify it.
  • ⚠️ The statement self-test stops in an unchanged registration-matching helper; the base helper fails identically. Updating that helper would allow the remaining assertions to execute.
Final Verdict

Status: ✅ Approve. No new inline findings.

@clickhouse-gh clickhouse-gh Bot added the pr-documentation Documentation PRs for the specific code PR label Nov 10, 2026
@Blargian

Copy link
Copy Markdown
Member

@groeneai at this stage we can get rid of slugmap and the entire _migration folder. We're completely migrated across. If we're relying on this file for any CI checks, please correct this.

@Blargian Blargian added the can be tested Allows running workflows for external contributors label Nov 10, 2026
@clickhouse-gh clickhouse-gh Bot added the comp-documentation Documentation (docs, examples, READMEs). label Nov 10, 2026
@groeneai

Copy link
Copy Markdown
Collaborator Author

Measured on master, the only CI consumer of docs/_migration/ is the nightly docs generator (ci/jobs/scripts/docs/autogenerate/autogenerate_docs.py):

  • it imports _migration/migrate.py for the Docusaurus to Mintlify body transform it applies to the source registrations (they still contain ::: admonitions, @theme imports and a few relative .md links);
  • it builds its link lookups from slug-map.csv (e.g. /engines/database-engines/sqlite to /reference/engines/database-engines/sqlite), and finds the pages of 7 families (table engines, data types, formats, table and window functions, dictionary sources and layouts) only through its rows, which is why Vortex.mdx and SQLite.mdx were never regenerated.

The PR-time Docs check does not read it (navigation_check.py and lychee.toml only exclude the folder).

I'll rework this PR accordingly: drop the two new rows, discover those pages from the reference/ directories (as database engines already are), move the transform the generator still needs next to it, resolve legacy links from the pages themselves and docs/_site/redirects.json (1529 of the 1530 distinct absolute doc links in src/ already resolve the same way), and delete docs/_migration/. The acceptance check is that a full regeneration changes nothing beyond the Vortex and SQLite pages.

groeneai and others added 2 commits November 10, 2026 22:09
The reference docs generator found its destination pages and resolved
legacy links through `docs/_migration/slug-map.csv`, a snapshot of the
Docusaurus to Mintlify migration. Pages added or moved since then were
silently skipped (`Vortex`, `SQLite`) or linked through stale routes.

- Every generator names its Mintlify page (`dest`) and the page's former
  Docusaurus path (`source_docu`, which relative links in the source
  registrations are written against).
- The eight page families discover their pages by walking their
  `reference/` directory, as database engines already did.
- The Markdown to MDX transforms move next to the generator as
  `mintlify_transform.py`. Only the transforms that some registration can
  trigger are kept; the migration driver, its per-page overrides and the
  slug map reader are dropped.
- Legacy links resolve through the docs tree plus the site redirect table
  `docs/_site/redirects.json`.

A full regeneration with the old and the new generator writes the same
page set and the same content, except one link in `ODBCDriver2.mdx`: the
ODBC page moved to `concepts/features/interfaces/odbc/index.mdx`, which
the stale slug-map row hid. The regenerated page is included.

Co-Authored-By: Claude Opus 5.5 <[email protected]>
Nothing reads it any more: the reference docs generator discovers its
pages from the `reference/` directories and resolves legacy links through
`docs/_site/redirects.json`. Drop the folder (slug map, alias table,
one-shot migration scripts) and the exclusions that only existed for it
in `navigation_check.py`, `lychee.toml` and the docs README.

Co-Authored-By: Claude Opus 5.5 <[email protected]>
@groeneai groeneai changed the title Docs: regenerate the Vortex and SQLite format pages Docs: regenerate the Vortex and SQLite format pages and remove docs/_migration Nov 10, 2026
@groeneai

Copy link
Copy Markdown
Collaborator Author
Internal second-model review: adjudication log (click to expand)

Pre-publication review of the rework by an independent model (engine: codex; 2 findings), plus my own review (3 nits).

# Sev Finding Verdict Evidence / action
1 ⚠️ No CI-invoked test proves that directory discovery finds Vortex and SQLite DISAGREE Docs generator is CI tooling, which gets no tests of its own; a full --write run of the new generator without docs/_migration writes both pages
2 💡 test_statement_generators.py fails before reaching the changed call DISAGREE Pre-existing: it fails the same way before this PR; this PR only drops two arguments from the call
3 💡 The dropped transforms are ones no current registration triggers, not ones none can AGREE, fixed PR description wording
4 💡 A future registration using Docusaurus-only syntax (escaped heading anchors, <VerticalStepper>) would no longer be converted AGREE, not changed No registration uses them today; the transforms belonged to the one-shot migration
5 💡 mintlify_transform.py shows as a new file, so the kept code is hard to compare AGREE, fixed PR description now states the kept transforms are unchanged apart from the docs root parameter

Severity: ❌ blocker / ⚠️ major / 💡 nit.

Session id: cron:clickhouse-review-slot-9:20261110-222500

@clickhouse-gh clickhouse-gh Bot added the manual approve Manual approve required to run CI label Nov 10, 2026
@groeneai

Copy link
Copy Markdown
Collaborator Author
Pre-PR validation gate (click to expand)
# Question Answer
a Deterministic repro? Yes. With docs/_migration removed, the previous generator fails at import migrate (ModuleNotFoundError); the new one runs without the folder and fails only on a missing binary.
b Root cause explained? autogenerate_docs.py took every destination and the page list of seven page families from docs/_migration/slug-map.csv, a snapshot of the migration, so pages added later (Vortex, SQLite) were skipped and moved pages kept stale routes.
c Fix matches root cause? Yes. Generators name their Mintlify page, the page families walk their reference/ directory, legacy links resolve through the docs tree and docs/_site/redirects.json; no lookup table is left.
d Test intent preserved / new tests added? Docs tooling change, so no new self-test; the four existing self-tests are adapted to the new API and give the same results as before.
e Both directions demonstrated? Yes. Full --write runs of the old and the new generator on two copies of the tree (same master binary) write the same 1131 files with identical content, except one link in ODBCDriver2.mdx (its target page moved; the stale slug-map row hid it).
f Fix is general across code paths? Yes. All settings, function, aggregate and page-family generators; every former slug-map reader (generator, self-tests, two exclusion lists, README) is updated.
g Fix generalizes across inputs (params/datatypes/wrappers)? The full run over every page family is the input set; the generated route contracts are also identical.
h Backward compatible? (maintainer-approved exception only) Docs tooling only; the removed --slug-map flag has no caller. Folder removal was requested by the docs owner.
i Invariants and contracts preserved? Same generated page set and content; pages without a matching registration stay skipped; the generator fails closed if redirects.json is missing; edits stay inside generated regions.

Session id: cron:clickhouse-impl-slot-5:20261110-220000

@groeneai

Copy link
Copy Markdown
Collaborator Author

I reworked this PR as discussed: the docs generator now finds its pages in the reference/ directories and resolves legacy links through docs/_site/redirects.json, and docs/_migration is deleted (20b2ba8, 9769069). A full regeneration with the old and the new generator gives identical output except one link in ODBCDriver2.mdx, which now points to /concepts/features/interfaces/odbc/index because that page moved after its slug-map row was written.

@groeneai

Copy link
Copy Markdown
Collaborator Author

CI finish ledger - 9769069

Every failure below has an owner: a fixing PR (mine or external), or a full-effort fix task
whose fixing-PR link will be posted here when it opens. Only CH Inc sync is exempt.

Check / test Reason Owner / fixing PR
Docs check (Mintlify) / No direct edits to generated or read-only docs expected for this PR: it intentionally regenerates the AUTOGENERATED regions of ODBCDriver2.mdx, SQLite.mdx and Vortex.mdx, and the guard accepts that only with the pr-autogenerated-docs label, which I cannot add PR-caused by design and owned by this PR (#130608): the resolution is the pr-autogenerated-docs label
Mergeable Check, PR praktika rollups of the row above PR-caused by design and owned by this PR (#130608): the resolution is the pr-autogenerated-docs label

CIDB has no other FAIL or ERROR row on this head.

Session id: cron:our-pr-ci-monitor:20261110-230008

@Blargian Blargian self-assigned this Nov 11, 2026
@Blargian Blargian added the pr-autogenerated-docs PR that regenerates docs artifacts from source; exempt from the autogenerated-region edit guard label Nov 11, 2026
@Blargian

Copy link
Copy Markdown
Member

@groeneai you mention that "... applies to the source registrations (they still contain ::: admonitions, @theme imports and a few relative .md links);". Please confirm that these have been fixed in the source code docs already (removing the need for the transformation)

@groeneai

Copy link
Copy Markdown
Collaborator Author

Not yet. On today's master build (48f9d3b98), running the generator with each transform step instrumented, the transform still changes 85 of the 516 generated bodies:

  • @theme/... imports in 21 pages: 18 engine pages from 15 registration files (e.g. src/Storages/MergeTree/registerStorageMergeTree.cpp, src/Storages/Kafka/StorageKafkaUtils.cpp), and the 3 settings pages, whose imports come from the generator's own session-settings.sql, format-settings.sql and global-server-settings.sql;
  • ::: admonitions in 13 pages from 12 files (e.g. src/Core/Settings.cpp, src/Core/ServerSettings.cpp, src/Dictionaries/XGBoostDictionary.cpp, the timeSeries*ToGrid aggregates);
  • links: 235 pre-Mintlify routes such as /operations/access-rights#row-policy-management, 3 absolute and 7 relative .md links (src/Core/Settings.cpp, src/DataTypes/DataTypeQBit.cpp);
  • <details> in 7 pages, HTML comments in 7, highlight comments in 2, <Tabs> and <iframe> in 1 each;
  • a leading # Title that duplicates the page title in 45 whole-page engine docs.

Converting these in the sources would make the transform removable. That edits registrations across many src/ components, so I would do it in a separate PR that also deletes mintlify_transform.py once the generator output no longer changes. Do you want me to open it?

@Blargian

Copy link
Copy Markdown
Member

Not yet. On today's master build (48f9d3b98), running the generator with each transform step instrumented, the transform still changes 85 of the 516 generated bodies:

  • @theme/... imports in 21 pages: 18 engine pages from 15 registration files (e.g. src/Storages/MergeTree/registerStorageMergeTree.cpp, src/Storages/Kafka/StorageKafkaUtils.cpp), and the 3 settings pages, whose imports come from the generator's own session-settings.sql, format-settings.sql and global-server-settings.sql;
  • ::: admonitions in 13 pages from 12 files (e.g. src/Core/Settings.cpp, src/Core/ServerSettings.cpp, src/Dictionaries/XGBoostDictionary.cpp, the timeSeries*ToGrid aggregates);
  • links: 235 pre-Mintlify routes such as /operations/access-rights#row-policy-management, 3 absolute and 7 relative .md links (src/Core/Settings.cpp, src/DataTypes/DataTypeQBit.cpp);
  • <details> in 7 pages, HTML comments in 7, highlight comments in 2, <Tabs> and <iframe> in 1 each;
  • a leading # Title that duplicates the page title in 45 whole-page engine docs.

Converting these in the sources would make the transform removable. That edits registrations across many src/ components, so I would do it in a separate PR that also deletes mintlify_transform.py once the generator output no longer changes. Do you want me to open it?

@groeneai please convert these in the sources. In a separate PR is fine.

@groeneai

Copy link
Copy Markdown
Collaborator Author

Acknowledged. I'm converting the remaining Docusaurus syntax in the source registrations (and the generator's settings SQL) to Mintlify, in a separate PR that also removes mintlify_transform.py once the generated output stops changing; I'll follow up here with the PR link (or my findings) shortly.

@groeneai

Copy link
Copy Markdown
Collaborator Author

Opened #130905. It converts the sources and deletes mintlify_transform.py; it is based on this PR, so it should merge after it. The generator keeps two page-assembly steps: it drops the leading # Title of full-page descriptions, because system.documentation uses that H1 to recognize a full page, and it collapses the blank lines of its own SQL output.

groeneai added a commit to groeneai/ClickHouse that referenced this pull request Nov 14, 2026
Conflicts:
- docs/_migration/migrate.py, docs/_migration/slug-map.csv: master
  modified them; this branch deletes docs/_migration (moved to the
  generator in ClickHouse#130608, removed here), so they stay deleted.
- ci/jobs/scripts/docs/autogenerate/test_session_settings_split.py:
  master added a `migrate.rewrite_links` fenced-link check next to the
  `migrate.transform_imports` checks this branch already removed with
  the transform; kept this branch's side.

Co-Authored-By: Claude Opus 5.5 <[email protected]>
@github-merge-queue github-merge-queue Bot closed this pull request by merging all changes into ClickHouse:master in 5327cf5 Nov 17, 2026
@robot-clickhouse-ci-1 robot-clickhouse-ci-1 added the pr-synced-to-cloud The PR is synced to the cloud repo label Nov 17, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

can be tested Allows running workflows for external contributors comp-documentation Documentation (docs, examples, READMEs). manual approve Manual approve required to run CI pr-autogenerated-docs PR that regenerates docs artifacts from source; exempt from the autogenerated-region edit guard pr-documentation Documentation PRs for the specific code PR pr-synced-to-cloud The PR is synced to the cloud repo

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants