Skip to content

docs(site): publish v3.5 as default, archive v3.4 - #22062

Merged
AskAlexSharov merged 5 commits into
release/3.5from
docs/publish-v3.5-archive-v3.4
Jul 7, 2026
Merged

docs(site): publish v3.5 as default, archive v3.4#22062
AskAlexSharov merged 5 commits into
release/3.5from
docs/publish-v3.5-archive-v3.4

Conversation

@bloxster

Copy link
Copy Markdown
Collaborator

Publishes the public docs site (docs.erigon.tech) for v3.5 and archives v3.4 as a selectable version.

What this does

  • Default version → v3.5. versions.current.label bumped v3.4v3.5 (it had never been bumped).
  • New archived version v3.4. versioned_docs/version-v3.4/ (75 files) sourced from the real release/3.4 docs content, with an autogenerated versioned sidebar. versions.json["v3.4", "v3.3"] (2 archives + current, within the 3-version cap).
  • Version injection. Parametrized fetchLatestSeriesVersion() and added a v34Version resolver so {ERIGON_VERSION} in the v3.4 archive injects the latest v3.4.x (not 3.5.0); routed version-v3.4 paths in the version-replace remark plugin.
  • Link fixes. Prefixed the v3.4 archive's absolute links to prune-modes and configuring-erigon/nat with /v3.4 so they resolve within the archive (both were renamed/moved in v3.5).
  • Deploy. Adds docs-deploy.yml triggering on push to release/3.5. A companion PR retires the release/3.4 deploy so the two branches don't fight over the shared github-pages environment.

Validation

  • npm run build succeeds (strict onBrokenLinks: throw).
  • Built output: v3.5 at root with the new Architecture/Database/Snapshots/pruning-modes pages; /v3.4 archive with the real v3.4 pages; v3.3 intact; version dropdown shows v3.5 / v3.4 / v3.3.
  • generate-llms.py --check clean; tsc passes.

Merge order

Merge the companion release/3.4 deploy-retirement PR first, then this one — merging this PR is a docs/site/** push to release/3.5 and triggers the v3.5 deploy.

Known gap (intentional, tracked separately)

release/3.5 docs are published as-is. 17 doc-maintenance commits that currently live only on release/3.4 are not forward-ported here (disk-size refresh, self-hosted fonts, trace-fields reference, SEO/OG meta, etc.). To be reconciled in a follow-up.

🤖 Generated with Claude Code

- Snapshot v3.4 docs into versioned_docs/version-v3.4 (sourced from
  release/3.4 content) + autogenerated versioned sidebar
- versions.json: ["v3.4", "v3.3"]
- Bump current docs label v3.4 -> v3.5
- Add a v34Version resolver for {ERIGON_VERSION} injection in the v3.4
  archive (parametrized fetchLatestSeriesVersion) and route version-v3.4
  paths to it in the version-replace remark plugin
- Prefix the v3.4 archive's absolute links to prune-modes and
  configuring-erigon/nat with /v3.4 so they resolve within the archive
  (both pages were renamed/moved in v3.5)
- Add docs-deploy.yml triggering on push to release/3.5 (a companion PR
  retires the release/3.4 deploy so they don't fight over GitHub Pages)

Note: release/3.5 current docs are published as-is; 17 doc-maintenance
commits that live only on release/3.4 are not forward-ported here and are
tracked separately.

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

Publishes the docs site with v3.5 as the default/current docs and adds v3.4 as an archived selectable version, including version-specific {ERIGON_VERSION} injection and a dedicated deploy workflow for release/3.5.

Changes:

  • Added v3.4 to Docusaurus version archives (new versioned_docs/version-v3.4/** + autogenerated sidebar + versions.json update).
  • Parameterized version injection to support per-series latest patch resolution (v3.3 vs v3.4 vs current).
  • Added GitHub Pages deploy workflow for docs on pushes to release/3.5.

Reviewed changes

Copilot reviewed 80 out of 80 changed files in this pull request and generated 7 comments.

Show a summary per file
File Description
docs/site/versions.json Adds v3.4 to the archived versions list.
docs/site/versioned_sidebars/version-v3.4-sidebars.json Adds autogenerated sidebar for the v3.4 archive.
docs/site/versioned_docs/version-v3.4/staking/shutter-network.mdx Adds archived v3.4 staking doc page for Shutter Network.
docs/site/versioned_docs/version-v3.4/staking/index.mdx Adds archived v3.4 staking landing page.
docs/site/versioned_docs/version-v3.4/staking/external-consensus-client-as-validator.md Adds archived v3.4 guide for external CL validator setups.
docs/site/versioned_docs/version-v3.4/staking/caplin.md Adds archived v3.4 guide for Caplin validator setups.
docs/site/versioned_docs/version-v3.4/staking/category.json Adds v3.4 staking sidebar category metadata.
docs/site/versioned_docs/version-v3.4/interacting-with-erigon/web3.md Adds archived v3.4 web3_ namespace reference.
docs/site/versioned_docs/version-v3.4/interacting-with-erigon/txpool.md Adds archived v3.4 txpool_ namespace reference.
docs/site/versioned_docs/version-v3.4/interacting-with-erigon/parity.md Adds archived v3.4 parity_ compatibility reference.
docs/site/versioned_docs/version-v3.4/interacting-with-erigon/overlay.md Adds archived v3.4 overlay_ namespace reference.
docs/site/versioned_docs/version-v3.4/interacting-with-erigon/ots.md Adds archived v3.4 ots_ namespace reference.
docs/site/versioned_docs/version-v3.4/interacting-with-erigon/net.md Adds archived v3.4 net_ namespace reference.
docs/site/versioned_docs/version-v3.4/interacting-with-erigon/internal.md Adds archived v3.4 internal_ namespace reference.
docs/site/versioned_docs/version-v3.4/interacting-with-erigon/index.md Adds archived v3.4 RPC service overview and transport docs.
docs/site/versioned_docs/version-v3.4/interacting-with-erigon/grpc.md Adds archived v3.4 gRPC interface documentation.
docs/site/versioned_docs/version-v3.4/interacting-with-erigon/graphql.md Adds archived v3.4 GraphQL endpoint documentation.
docs/site/versioned_docs/version-v3.4/interacting-with-erigon/eth.md Adds archived v3.4 eth_ namespace reference (incl. Erigon extensions).
docs/site/versioned_docs/version-v3.4/interacting-with-erigon/erigon.md Adds archived v3.4 erigon_ namespace reference.
docs/site/versioned_docs/version-v3.4/interacting-with-erigon/engine.md Adds archived v3.4 Engine API overview.
docs/site/versioned_docs/version-v3.4/interacting-with-erigon/bor.md Adds archived v3.4 bor_ namespace reference.
docs/site/versioned_docs/version-v3.4/interacting-with-erigon/admin.md Adds archived v3.4 admin_ namespace reference.
docs/site/versioned_docs/version-v3.4/interacting-with-erigon/category.json Adds v3.4 “Interacting with Erigon” sidebar category metadata.
docs/site/versioned_docs/version-v3.4/index.mdx Adds archived v3.4 docs home/landing page.
docs/site/versioned_docs/version-v3.4/get-started/why-using-erigon.mdx Adds archived v3.4 “Why Erigon?” page.
docs/site/versioned_docs/version-v3.4/get-started/migrating-from-geth.mdx Adds archived v3.4 migration guide from Geth.
docs/site/versioned_docs/version-v3.4/get-started/installation/upgrading.md Adds archived v3.4 upgrade guidance.
docs/site/versioned_docs/version-v3.4/get-started/installation/category.json Adds v3.4 installation sidebar category metadata.
docs/site/versioned_docs/version-v3.4/get-started/index.mdx Adds archived v3.4 “Get Started” landing page.
docs/site/versioned_docs/version-v3.4/get-started/hardware-requirements.mdx Adds archived v3.4 hardware requirements page.
docs/site/versioned_docs/version-v3.4/get-started/easy-nodes/index.mdx Adds archived v3.4 “Easy Nodes” landing page.
docs/site/versioned_docs/version-v3.4/get-started/easy-nodes/how-to-run-an-ethereum-node/index.md Adds archived v3.4 Ethereum node guided setup.
docs/site/versioned_docs/version-v3.4/get-started/easy-nodes/how-to-run-an-ethereum-node/ethereum-with-an-external-cl.mdx Adds archived v3.4 Ethereum + external CL guide.
docs/site/versioned_docs/version-v3.4/get-started/easy-nodes/how-to-run-an-ethereum-node/category.json Adds v3.4 category metadata for Ethereum guided setup section.
docs/site/versioned_docs/version-v3.4/get-started/easy-nodes/how-to-run-a-polygon-node.md Adds archived v3.4 Polygon node guided setup.
docs/site/versioned_docs/version-v3.4/get-started/easy-nodes/how-to-run-a-gnosis-chain-node/index.md Adds archived v3.4 Gnosis Chain guided setup.
docs/site/versioned_docs/version-v3.4/get-started/easy-nodes/how-to-run-a-gnosis-chain-node/gnosis-with-an-external-cl.md Adds archived v3.4 Gnosis + external CL guide.
docs/site/versioned_docs/version-v3.4/get-started/easy-nodes/how-to-run-a-gnosis-chain-node/category.json Adds v3.4 category metadata for Gnosis guided setup section.
docs/site/versioned_docs/version-v3.4/get-started/easy-nodes/category.json Adds v3.4 “Easy Nodes” category metadata.
docs/site/versioned_docs/version-v3.4/get-started/category.json Adds v3.4 “Get Started” category metadata.
docs/site/versioned_docs/version-v3.4/fundamentals/web3-wallet.md Adds archived v3.4 web3 wallet connection instructions.
docs/site/versioned_docs/version-v3.4/fundamentals/tls-authentication.md Adds archived v3.4 TLS authentication instructions.
docs/site/versioned_docs/version-v3.4/fundamentals/supported-networks.md Adds archived v3.4 supported networks reference.
docs/site/versioned_docs/version-v3.4/fundamentals/security.md Adds archived v3.4 security/hardening guidance.
docs/site/versioned_docs/version-v3.4/fundamentals/prune-modes.md Adds archived v3.4 prune modes documentation.
docs/site/versioned_docs/version-v3.4/fundamentals/performance-tricks.md Adds archived v3.4 performance tuning guide.
docs/site/versioned_docs/version-v3.4/fundamentals/otterscan.md Adds archived v3.4 Otterscan integration doc.
docs/site/versioned_docs/version-v3.4/fundamentals/optimizing-storage.md Adds archived v3.4 storage optimization guide.
docs/site/versioned_docs/version-v3.4/fundamentals/multiple-instances.md Adds archived v3.4 multi-instance guidance.
docs/site/versioned_docs/version-v3.4/fundamentals/modules/txpool.md Adds archived v3.4 TxPool module doc.
docs/site/versioned_docs/version-v3.4/fundamentals/modules/sentry.mdx Adds archived v3.4 Sentry module doc.
docs/site/versioned_docs/version-v3.4/fundamentals/modules/rpc-daemon.md Adds archived v3.4 RPC Daemon module doc.
docs/site/versioned_docs/version-v3.4/fundamentals/modules/index.mdx Adds archived v3.4 Modules landing page.
docs/site/versioned_docs/version-v3.4/fundamentals/modules/downloader.mdx Adds archived v3.4 Downloader module doc.
docs/site/versioned_docs/version-v3.4/fundamentals/modules/category.json Adds v3.4 modules category metadata.
docs/site/versioned_docs/version-v3.4/fundamentals/logs.md Adds archived v3.4 logging documentation.
docs/site/versioned_docs/version-v3.4/fundamentals/layer-2-networks.md Adds archived v3.4 L2 networks doc.
docs/site/versioned_docs/version-v3.4/fundamentals/jwt.md Adds archived v3.4 JWT secret documentation.
docs/site/versioned_docs/version-v3.4/fundamentals/index.mdx Adds archived v3.4 Fundamentals landing page.
docs/site/versioned_docs/version-v3.4/fundamentals/docker-compose.md Adds archived v3.4 Docker compose documentation.
docs/site/versioned_docs/version-v3.4/fundamentals/default-ports.md Adds archived v3.4 default ports reference.
docs/site/versioned_docs/version-v3.4/fundamentals/creating-a-dashboard.md Adds archived v3.4 monitoring dashboard guide.
docs/site/versioned_docs/version-v3.4/fundamentals/configuring-erigon/nat.md Adds archived v3.4 NAT configuration reference.
docs/site/versioned_docs/version-v3.4/fundamentals/configuring-erigon/category.json Adds v3.4 CLI reference category metadata.
docs/site/versioned_docs/version-v3.4/fundamentals/caplin.md Adds archived v3.4 Caplin overview.
docs/site/versioned_docs/version-v3.4/fundamentals/basic-usage.mdx Adds archived v3.4 basic usage guide.
docs/site/versioned_docs/version-v3.4/fundamentals/category.json Adds v3.4 fundamentals category metadata.
docs/site/versioned_docs/version-v3.4/about/license.md Adds archived v3.4 license page.
docs/site/versioned_docs/version-v3.4/about/index.mdx Adds archived v3.4 About landing page.
docs/site/versioned_docs/version-v3.4/about/disclaimer.md Adds archived v3.4 disclaimer page.
docs/site/versioned_docs/version-v3.4/about/contributing.md Adds archived v3.4 contributing page.
docs/site/versioned_docs/version-v3.4/about/category.json Adds v3.4 about category metadata.
docs/site/src/remark/version-replace.js Extends {ERIGON_VERSION} replacement to support version-v3.4 paths.
docs/site/docusaurus.config.ts Switches current label to v3.5 and injects per-series version resolution for v3.3/v3.4.
.github/workflows/docs-deploy.yml Adds docs deploy workflow for pushes to release/3.5.

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

Comment thread docs/site/versioned_docs/version-v3.4/staking/shutter-network.mdx Outdated
Comment thread docs/site/versioned_docs/version-v3.4/staking/shutter-network.mdx
Comment thread docs/site/versioned_docs/version-v3.4/fundamentals/tls-authentication.md Outdated
Comment thread docs/site/versioned_docs/version-v3.4/fundamentals/multiple-instances.md Outdated
Comment thread docs/site/versioned_docs/version-v3.4/fundamentals/supported-networks.md Outdated
Comment thread docs/site/versioned_docs/version-v3.4/interacting-with-erigon/eth.md Outdated
Bloxster and others added 2 commits June 26, 2026 18:02
Applied to both the current v3.5 docs and the v3.4 archive (issues were
pre-existing content errors, several live in production):

- shutter-network: "reby following" -> "by following"; nest step-3 code
  fences and flag bullets under the numbered list item
- eth.md: fix malformed eth_getStorageValues curl JSON (stray quote made
  the storageKeys array invalid)
- supported-networks: intro said "Holesky" but the example uses
  --chain=hoodi -> "Hoodi"
- multiple-instances: drop the duplicate (mis-tagged ```markdown) command
  block
- how-to-run-an-ethereum-node category: "a Ethereum" -> "an Ethereum"
- tls-authentication (v3.4 archive only; current already correct):
  "RPC key.pem" -> "RPC-key.pem", "RPC.crtv" -> "RPC.crt"

Regenerated llms.txt / llms-full.txt for the current-docs edits.

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
Replaces the hardcoded per-series resolvers (v33Version/v34Version) with a
single loop over versions.json: the config fetches the latest patch release
for each archived version and passes a {id -> versionString} map to the
remark plugin, which routes by the `version-vX.Y` path segment.

Net effect: adding a new archived version (via `docusaurus docs:version`)
needs NO edits to docusaurus.config.ts or version-replace.js — versions.json
is the single source of truth. Verified: current docs inject 3.5.0, the v3.4
archive injects 3.4.4.

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
pull Bot pushed a commit to Dustin4444/erigon that referenced this pull request Jun 29, 2026
…igontech#22067)

Forward-ports the generic version-injection refactor (introduced on
`release/3.5` in erigontech#22062) to **`main`**, so every release branch cut from
main inherits it.

## Why on main
Release branches are cut from `main`. If this infra only lived on
`release/3.5`, `release/3.6` would revert to the old hardcoded
per-series resolver. Pairs with the Docs Version Bump workflow (erigontech#22066),
which also lives on main.

## What changes
- Replaces the hardcoded `fetchLatestV33Version` / `v33Version` with a
parametrized `fetchLatestSeriesVersion(prefix)` looped over
`versions.json`, building a `{id -> latest patch}` map.
- The remark plugin routes by the `version-vX.Y` path segment instead of
a hardcoded `version-v3.3` check.
- **Net effect:** adding an archived version (via `docusaurus
docs:version`) needs zero edits to `docusaurus.config.ts` or
`version-replace.js`.

## No behavior change here
`versions.json` is still `["v3.3"]` and the current label is still
`v3.4` — verified the build injects `3.3.1` into the v3.3 archive and
the latest release into current, exactly as before. This PR is purely
the mechanism.

🤖 Generated with [Claude Code](https://claude.com/claude-code)

Co-authored-by: Bloxster <gianni.morselli@erigon.tech>
Co-authored-by: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
bloxster and others added 2 commits July 1, 2026 08:08
The zizmor cache-poisoning audit flags actions/setup-node in any workflow
with a publishing/deploy trigger, regardless of the cache input. Deploy Docs
only runs on push to the release branch (not fork PRs), so the npm cache
cannot be poisoned by an untrusted actor. Suppress the finding inline and
keep dependency caching for faster builds.

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
@bloxster
bloxster marked this pull request as ready for review July 1, 2026 08:23
AskAlexSharov pushed a commit that referenced this pull request Jul 7, 2026
Companion to #22062.

The public docs site (docs.erigon.tech) now publishes from
**release/3.5**, which carries its own `docs-deploy.yml`. This PR
removes the `docs-deploy.yml` on `release/3.4` so a future
`docs/site/**` push to `release/3.4` no longer redeploys and clobbers
the v3.5 site (both used the shared `github-pages` environment).

## Merge order
Merge **this PR first**, then #22062 (whose merge triggers the v3.5
deploy).

## Note
This stops auto-deploys from `release/3.4`. Any further v3.4-only doc
fixes should be applied on the new docs source branch (`release/3.5`) so
they reach production.

🤖 Generated with [Claude Code](https://claude.com/claude-code)

Co-authored-by: Bloxster <gianni.morselli@erigon.tech>
Co-authored-by: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
@AskAlexSharov
AskAlexSharov merged commit d2ca65b into release/3.5 Jul 7, 2026
165 checks passed
@AskAlexSharov
AskAlexSharov deleted the docs/publish-v3.5-archive-v3.4 branch July 7, 2026 06:09
yperbasis added a commit that referenced this pull request Jul 10, 2026
Adds the **v3.5.1** release notes to `ChangeLog.md`, following the
v3.4.1–v3.4.4 point-release format (codename **Tidal Tails**, kept from
3.5.0; date left as `TBD` pending the release).

Scope: user-facing **Bugfixes** and **Improvements** merged to
`release/3.5` since the `v3.5.0` tag. Each entry cites the `[r3.5]` PR
that landed on the branch and credits the original fix author, matching
the existing point-release style.

The six issues closed in [milestone
3.5.1](https://github.com/erigontech/erigon/milestone/78) are all
covered: #21992 & #22101 (commitment consistency), #22013
(`stage_custom_trace` prune), #22275 (snapshot reset), #22337 (Bellatrix
reconstruction loop), #22351 (forkchoice `GetHead` stall).

Deliberately omitted as minor/internal/tooling/docs-only:
- `cmd/integration` / `seg` build tweaks (#22137, #22262), QA sync-wait
bump (#22280), docs & changelog commits (#22062, #22068, #22090),
downloader concurrency hardening (#22319).
- The **net-zero** rcache pair — #22047 (bump rcache domain to v3.1) and
its revert #22207 — cancels out, so it produces no 3.5.0→3.5.1 change.

Opened as a **draft**: fill in the release date on tag, and confirm
nothing else is expected to land in 3.5.1 before finalizing.

_No `make lint` run — the diff is markdown-only (`ChangeLog.md`), which
golangci-lint does not scan._
github-merge-queue Bot pushed a commit that referenced this pull request Jul 20, 2026
#22426)

## What

The frozen **v3.4 archive** used unversioned absolute links (e.g.
`/get-started/`) that were copied from the current docs. Inside an
archived version those resolve to the **current** version, so a reader
browsing the v3.4 docs is silently bounced into v3.5/v3.6. GitHub
Copilot flagged this on #22420; the root cause is tracked in #22416. The
v3.3 archive was already self-contained — v3.4 was the outlier (#22062
only fixed the links that broke the build).

**Fix (76 links / 13 files):** cross-page absolute links →
`/v3.4/`-prefixed (matching v3.3); same-page anchors → local `#frag`.
Left `/` (home), `/help-center/…` (separate unversioned instance),
`/img/…`, external, and already-`/vX.Y/` links untouched.

## Prevention (so future version cuts can't reintroduce this)

Three files under `docs/site/scripts/`:

- **`fix-archive-links.py`** — reusable fixer + `--check`. Per archived
version it prefixes any unversioned absolute intra-docs link and
localizes same-page anchors. Handles markdown inline/reference, JSX
`<Link>`, and HTML `<a href>` forms; skips fenced code; and flags links
into **renamed/removed** sections (the silent-leak case `onBrokenLinks`
can miss). Run it right after `docusaurus docs:version vX.Y`.
- **`test_archive_links.py`** — the guard: fails if any
`versioned_docs/version-*/` page has an unversioned absolute intra-docs
link. It **auto-runs in CI** via the existing `python3 -m unittest
discover docs/site/scripts` step in `docs-site-build.yml` (PR) and
`docs-deploy.yml` (push) — **no workflow change**, and it runs before
the npm build so neither path can bypass it.
- **`test_fix_archive_links.py`** — unit tests for each link syntax and
edge case.

## Verification

- `docs/site` build **green**
(`onBrokenLinks`/`onBrokenAnchors`/`onBrokenMarkdownLinks` all
`'throw'`).
- `generate-llms.py --check` unchanged (74 pages — generator ignores
`versioned_docs/`).
- **62 unittests pass**; the guard catches all **76** links on the
pre-fix archive (has teeth); fixer is idempotent and reproducible.
- v3.3 archive already passes the guard.

## Review

Adversarially reviewed by ChatGPT 5.5 + Fable (both
APPROVE-WITH-CHANGES). All findings folded in: broadened link-form
coverage, catch-all detection (fixes the renamed-section blind spot),
fenced-code skipping, `to=` word boundary (won't match
`photo=`/`auto=`), root-`index` `/#frag` localization, and `argparse`.

Companion: #22420 carries the same corrected v3.4 archive + these
scripts to `main`. Refs #22416, #22420.

🤖 Generated with [Claude Code](https://claude.com/claude-code)

---------

Co-authored-by: Bloxster <gianni.morselli@erigon.tech>
Co-authored-by: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
ADD12 pushed a commit to ADD12/erigon that referenced this pull request Jul 21, 2026
Adds `.github/workflows/docs-version-bump.yml` — `workflow_dispatch`
tooling to automate docs versioning when a new major/minor releases.

**On `main`** (replaces erigontech#22065, which targeted `release/3.5`): since
release branches are cut from `main`, putting it here means every future
release branch inherits it automatically.

## What it does
Given `archive_version` (e.g. `v3.5`) and `new_label` (e.g. `v3.6`):
snapshots the current docs as the archived version (`docusaurus
docs:version`), bumps the current label, enforces the 3-archived-version
cap, regenerates `llms.txt`, verifies `npm run build`, and opens a PR.

## How to use
Run it on the new release branch right after it's cut (where
`docs/site/docs` still holds the about-to-be-archived content).

## Notes
- Best paired with the `versions.json`-driven version injection (erigontech#22062)
so no `docusaurus.config.ts` edits are needed per release. That infra
currently lives on `release/3.5`; forward-porting it to `main` is
recommended so release branches inherit it.
- Does **not** move the Pages deploy trigger (still per-release-branch
via `docs-deploy.yml`).
- Requires the repo setting *"Allow GitHub Actions to create and approve
pull requests."*

🤖 Generated with [Claude Code](https://claude.com/claude-code)

---------

Co-authored-by: Bloxster <gianni.morselli@erigon.tech>
Co-authored-by: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
rayjun pushed a commit to rayjun/erigon that referenced this pull request Jul 24, 2026
… cut (erigontech#22691)

## What

Adds an `archive-previous-docs-version` job to
`create-release-branch.yml` that runs right after a `release/N.N` branch
is cut and opens a **`docs`-labelled PR** archiving the previous stable
docs version onto the freshly-cut branch (Docusaurus native versioning).
A human reviews and merges that PR.

This automates **Q1** of the docs version transition (archive the
outgoing version). **Q2** — flipping the live deploy on docs.erigon.tech
to the new series — is intentionally left as the existing manual
retire+publish pair (erigontech#22062 / erigontech#22063).

## Why

Versioning is not automatic today: cutting `release/3.6` leaves
`versions.json` without a `v3.5` snapshot, so the previous stable
version would silently drop out of the version dropdown. Doing it by
hand is easy to forget or get wrong.

## How it works

- **Sources the snapshot from the OUTGOING release branch**
(`release/N.<M-1>`), not the just-cut branch — which was cut from `main`
and already holds the *next* version's docs. (This is the correctness
bug the manual `docs-version-bump.yml` path is prone to.)
- **Ports the outgoing branch's full versioned state** (`versions.json`
+ all `versioned_docs/` + `versioned_sidebars/`) plus the fresh
snapshot, then enforces the 3-archived-version cap — so no older version
drops off at the *next* cut.
- **Fail-closed series selection**: enumerates `release/N.N` branches
via the GitHub API, exact regex (excludes patch-style names like
`release/3.0.10`), numeric per-component sort (so `3.10 > 3.9`); aborts
on API error rather than guessing.
- **Build-verified before opening** (`onBrokenLinks: throw`), llms.txt
regenerated.
- **`dry_run`** validates the full port + build without opening a PR.
- Opens the PR with the default `GITHUB_TOKEN` (scoped `contents:write`
+ `pull-requests:write`) for manual review/merge. Note: a
`GITHUB_TOKEN`-opened PR does not itself trigger `pull_request` CI
(Actions recursion guard); the archive is already build-verified in-job,
and a reviewer merges after inspecting the diff.

## Notes for reviewers

- The version chain stays intact only if each cycle's archive PR is
merged into its release branch before the next cut (inherent to the
human-merge model; no worse than today's fully-manual state).
- Passed `actionlint` (with shellcheck) and `zizmor` locally.

🤖 Generated with [Claude Code](https://claude.com/claude-code)

---------

Co-authored-by: Bloxster <gianni.morselli@erigon.tech>
Co-authored-by: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
bloxster added a commit that referenced this pull request Aug 3, 2026
… cut (#22691)

## What

Adds an `archive-previous-docs-version` job to
`create-release-branch.yml` that runs right after a `release/N.N` branch
is cut and opens a **`docs`-labelled PR** archiving the previous stable
docs version onto the freshly-cut branch (Docusaurus native versioning).
A human reviews and merges that PR.

This automates **Q1** of the docs version transition (archive the
outgoing version). **Q2** — flipping the live deploy on docs.erigon.tech
to the new series — is intentionally left as the existing manual
retire+publish pair (#22062 / #22063).

## Why

Versioning is not automatic today: cutting `release/3.6` leaves
`versions.json` without a `v3.5` snapshot, so the previous stable
version would silently drop out of the version dropdown. Doing it by
hand is easy to forget or get wrong.

## How it works

- **Sources the snapshot from the OUTGOING release branch**
(`release/N.<M-1>`), not the just-cut branch — which was cut from `main`
and already holds the *next* version's docs. (This is the correctness
bug the manual `docs-version-bump.yml` path is prone to.)
- **Ports the outgoing branch's full versioned state** (`versions.json`
+ all `versioned_docs/` + `versioned_sidebars/`) plus the fresh
snapshot, then enforces the 3-archived-version cap — so no older version
drops off at the *next* cut.
- **Fail-closed series selection**: enumerates `release/N.N` branches
via the GitHub API, exact regex (excludes patch-style names like
`release/3.0.10`), numeric per-component sort (so `3.10 > 3.9`); aborts
on API error rather than guessing.
- **Build-verified before opening** (`onBrokenLinks: throw`), llms.txt
regenerated.
- **`dry_run`** validates the full port + build without opening a PR.
- Opens the PR with the default `GITHUB_TOKEN` (scoped `contents:write`
+ `pull-requests:write`) for manual review/merge. Note: a
`GITHUB_TOKEN`-opened PR does not itself trigger `pull_request` CI
(Actions recursion guard); the archive is already build-verified in-job,
and a reviewer merges after inspecting the diff.

## Notes for reviewers

- The version chain stays intact only if each cycle's archive PR is
merged into its release branch before the next cut (inherent to the
human-merge model; no worse than today's fully-manual state).
- Passed `actionlint` (with shellcheck) and `zizmor` locally.

🤖 Generated with [Claude Code](https://claude.com/claude-code)

---------

Co-authored-by: Bloxster <gianni.morselli@erigon.tech>
Co-authored-by: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
(cherry picked from commit a18ea1c)
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.

3 participants