Skip to content

fix/links: Fix broken heading links (28 dead sections) - #1865

Draft
marcleblanc2 wants to merge 1 commit into
mainfrom
fix-dead-section-links
Draft

fix/links: Fix broken heading links (28 dead sections)#1865
marcleblanc2 wants to merge 1 commit into
mainfrom
fix-dead-section-links

Conversation

@marcleblanc2

@marcleblanc2 marcleblanc2 commented Sep 7, 2026

Copy link
Copy Markdown
Contributor

Linear FE-499: Fix doc site issues

Smaller, more easily reviewed subset of fixes from #1861

#anchor links whose target section no longer exists on the page. The page is still the right destination, so the link now points at the page top; where the linked words themselves described the removed section, the link is unlinked and the words kept:

  • docs/admin/code-hosts/github.mdx: "less than 1000 results" (the repositoryQuery returns first 1000 results only section is gone)
  • docs/admin/how-to/converting-version-contexts-to-search-contexts.mdx: "version contexts" ×2 (feature sunset, section gone)
  • docs/code-navigation/how-to/index-other-languages.mdx: "supply a GitHub token" (the ownership-proof section is gone)

Review: for each row, confirm the page has no heading close to the old anchor. Each was checked against the page's headings and against production; none has a near match.

Left alone on purpose: #view-and-edit-site-configuration and #editing-your-site-configuration-if-you-cannot-access-the-web-ui on /admin/config/site-config#1861 dropped them but both headings exist. Also left alone: anchors that name a JSON-schema key (/admin/config/site-config#<key>, /admin/code-hosts/<host>#<key>); the schema renderer emits no per-key ids, so those get a separate fix.

Checker findings (npm run check-links -- --check-anchors, from #1858, with its heading-slug fix): 278 on main → 250 on this branch.

Verification

The docs site serves its not-found page with HTTP 200 (fix in progress), so status codes prove nothing. Instead, every changed link was fetched on this PR's Vercel preview and the rendered HTML checked for two ids: the target page's own first heading (taken from its MDX source — the 404 page never has it) and the link's #fragment. Script: node dev/verify-links-live.mjs --site <preview-url>, coming in #1858.

Old links point at the current production site so you can see the breakage; new links point at the preview and land on the heading.

The 4 unlinked lines above carry no link to check and are not in the table.

Checked 24 changed links against https://sourcegraph-docs-git-fix-dead-secti-081906-sourcegraph-f8c71130.vercel.app: 24 resolve, 0 fail.
Page rendered = the target page's first heading id is present (the 404 page never has it); Anchor = the #fragment is an id on the page. Old links point at the current site.

All 24 links
File containing the link Old link (broken today) New link (preview) Page rendered Anchor found
docs/admin/audit-log.mdx /self-hosted/deploy/kubernetes/scale#core-components /self-hosted/deploy/kubernetes/scale
docs/admin/auth/index.mdx /admin/config/site-config#authentication-providers /admin/config/site-config
docs/admin/faq.mdx /admin/repo/auth#repositories-that-need-http-s-or-ssh-authentication /admin/repo/auth
docs/admin/how-to/site-admin-quickstart.mdx /self-hosted/updates/#migrating-to-a-new-deployment-type /self-hosted/updates
docs/batch-changes/delete-a-batch-change.mdx /batch-changes/create-a-batch-change#viewing-batch-changes /batch-changes/create-a-batch-change
docs/code-navigation/auto-indexing.mdx /code-navigation/features#dependency-navigation /code-navigation/features
docs/code-navigation/auto-indexing.mdx /code-navigation/features#dependency-navigation /code-navigation/features
docs/code-navigation/index.mdx /code-navigation/features#find-implementations /code-navigation/features
docs/code-search/index.mdx /code-search/features#statistics /code-search/features
docs/cody/clients/install-jetbrains.mdx /cody/enterprise/model-configuration#completions-configuration /cody/enterprise/model-configuration
docs/cody/clients/install-vscode.mdx /model-provider#configuring-custom-models /model-provider
docs/cody/core-concepts/index.mdx /admin/architecture#cody /admin/architecture
docs/cody/enterprise/model-configuration.mdx /cody/enterprise/model-configuration#self-hosted-models /cody/enterprise/model-configuration
docs/getting-started/github-vs-sourcegraph.mdx /code-navigation/features#beta-dependency-navigation /code-navigation/features
docs/integration/bitbucket-server.mdx /integration/browser-extension#configuring-the-sourcegraph-instance-to-use /integration/browser-extension
docs/integration/github.mdx /integration/browser-extension#configuring-the-sourcegraph-instance-to-use /integration/browser-extension
docs/integration/gitlab.mdx /integration/browser-extension#configuring-the-sourcegraph-instance-to-use /integration/browser-extension
docs/integration/phabricator.mdx /integration/browser-extension#configuring-the-sourcegraph-instance-to-use /integration/browser-extension
docs/self-hosted/deploy/kubernetes/configure.mdx /self-hosted/deploy/kubernetes/kustomize/#patches-directory /self-hosted/deploy/kubernetes/kustomize
docs/self-hosted/deploy/kubernetes/configure.mdx /self-hosted/deploy/kubernetes/kustomize/#patches-directory /self-hosted/deploy/kubernetes/kustomize
docs/self-hosted/deploy/kubernetes/configure.mdx /admin/code-hosts/#full-code-host-docs /admin/code-hosts
docs/self-hosted/deploy/kubernetes/configure.mdx /self-hosted/deploy/kubernetes/kustomize/#patches-directory /self-hosted/deploy/kubernetes/kustomize
docs/self-hosted/deploy/repositories.mdx /self-hosted/deploy/#installation /self-hosted/deploy
docs/self-hosted/workers.mdx /admin/migration#mout-of-band-migrations /admin/migration

Amp threads

@vercel

vercel Bot commented Sep 7, 2026

Copy link
Copy Markdown

The latest updates on your projects. Learn more about Vercel for GitHub.

Project Deployment Actions Updated
sourcegraph-docs Ready Ready Preview Sep 7, 2026 11:26pm UTC

Request Review

@marcleblanc2 marcleblanc2 changed the title Fix broken heading links (29 dead sections) Fix broken heading links (28 dead sections) Sep 7, 2026
@marcleblanc2 marcleblanc2 changed the title Fix broken heading links (28 dead sections) fix/links: Fix broken heading links (28 dead sections) Sep 9, 2026
@marcleblanc2
marcleblanc2 marked this pull request as draft September 10, 2026 01:14
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.

1 participant