test: PR checks on a broken PR, left broken (do not merge) - #1920
test: PR checks on a broken PR, left broken (do not merge)#1920marcleblanc2 wants to merge 12 commits into
Conversation
dev/check-redirects.mjs checks every entry in src/data/redirects.ts: source shadows a page, source has a #fragment, duplicate source, /docs prefix, chained redirect, missing destination page or heading. The workflow compares against the merge base, so only redirects a PR breaks are reported, grouped by problem with the fix explained under each heading, and posts one suggested change per fixable entry the PR added (deleted again once the finding is gone). Not part of `npm run check`: main has hundreds of pre-existing findings. Squash of the check-redirects branch rebased onto main; the check-links commits it carried are already on main. Amp-Thread-ID: https://ampcode.com/threads/T-01a08fee-74b4-76dc-aaf9-d1245d68fdc9 Co-authored-by: Amp <amp@ampcode.com>
…ady names Amp-Thread-ID: https://ampcode.com/threads/T-01a08fee-74b4-76dc-aaf9-d1245d68fdc9 Co-authored-by: Amp <amp@ampcode.com>
…h (from the check-links PR) Amp-Thread-ID: https://ampcode.com/threads/T-01a08fee-74b4-76dc-aaf9-d1245d68fdc9 Co-authored-by: Amp <amp@ampcode.com>
… fact per line - Review comments: one suggested change per finding with a fix, no review body. Each starts with a marker so the workflow can delete suggestions for findings that are fixed and skip ones already posted. - Summary comment and review comments list line, link, problem, and fix on their own lines. - Absolute links to this site get their own section instead of Outbound. - Case-mismatch findings now carry a fix. - Wording: 'links on this site', 'these other pages', drop docs.sourcegraph.com; reproduce command matches package.json. Amp-Thread-ID: https://ampcode.com/threads/T-01a08fee-74b4-76dc-aaf9-d1245d68fdc9 Co-authored-by: Amp <amp@ampcode.com>
Amp-Thread-ID: https://ampcode.com/threads/T-01a08fee-74b4-76dc-aaf9-d1245d68fdc9 Co-authored-by: Amp <amp@ampcode.com>
…roblem Amp-Thread-ID: https://ampcode.com/threads/T-01a08fee-74b4-76dc-aaf9-d1245d68fdc9 Co-authored-by: Amp <amp@ampcode.com>
Amp-Thread-ID: https://ampcode.com/threads/T-01a08fee-74b4-76dc-aaf9-d1245d68fdc9 Co-authored-by: Amp <amp@ampcode.com>
… update comments whose text changed Amp-Thread-ID: https://ampcode.com/threads/T-01a08fee-74b4-76dc-aaf9-d1245d68fdc9 Co-authored-by: Amp <amp@ampcode.com>
|
The latest updates on your projects. Learn more about Vercel for GitHub.
|
❌ This PR breaks 8 redirect(s)Redirects are used so inbound traffic from external sources (links inside old versions of our product, bookmarks, search results, etc.) to old doc pages still reaches a relevant page. A correct entry maps the old page path, exactly as the browser requests it, straight to a page that exists today, with an optional #heading that exists on the destination page: {
source: '/old/section/page',
destination: '/new/section/page#heading-slug'
},Each section below explains how to fix the entries listed under it. Do not use redirects for broken internal links, internal links must be fixed properly to tame the tech debt snowball no one wants to deal with; the "Check links" PR check comment lists the links this PR broke, if any. Source overshadows a docs page that existsRedirects take precedence over pages, so visitors to that page's URL are redirected away from it. Update or remove the redirect or the page to remove the conflict.
Source has a #fragment, so this redirect can never matchUse the page path alone as the source. #fragments are processed in the browser, so browsers never send them to web servers. If the redirect destination has a #fragment, it takes precedence, otherwise if the customer clicked a link which has a #fragment, it'll be kept and tried on the destination page.
Source or destination starts with /docsWrite paths without the /docs prefix. The site removes /docs from the requested URL before matching sources, and adds it back in front of the destination, so a /docs/... source never matches and a /docs/... destination lands on /docs/docs/....
Source already has an earlier entry, so this one is never usedOnly the first entry for a source matches. Update that entry instead of adding another.
Destination is another redirectChained redirects cost the customer's browser a round trip, slow down their page load time, and frustrate them. They also make the redirects file impossible to maintain, and make it too easy to create redirect loops. Change the rule's destination to the final destination.
Destination page does not existSet the redirect destination to the page that replaced it, or remove the rule if there is no replacement page; visitors then get our fancy 404 page, with links they can click to find where they're trying to go, and the search bar.
Destination heading does not existUse the heading's correct anchor, or drop the #fragment to land the customer at the top of the page.
Reproduce locally with |
| { | ||
| source: "/docs/old-prefixed", | ||
| destination: "/code-ownership" | ||
| }, |
There was a problem hiding this comment.
Problem: Source or destination starts with /docs
Fix: change the source to /old-prefixed
| { | |
| source: "/docs/old-prefixed", | |
| destination: "/code-ownership" | |
| }, | |
| { | |
| source: '/old-prefixed', | |
| destination: '/code-ownership' | |
| }, |
| { | ||
| source: "/old-chain", | ||
| destination: "/admin/http_https_configuration" | ||
| }, |
There was a problem hiding this comment.
Problem: Destination is another redirect
Fix: change the destination to /self-hosted/http-https-configuration
| { | |
| source: "/old-chain", | |
| destination: "/admin/http_https_configuration" | |
| }, | |
| { | |
| source: '/old-chain', | |
| destination: '/self-hosted/http-https-configuration' | |
| }, |
| { | ||
| source: "/old-ownership#anchor", | ||
| destination: "/code-ownership" | ||
| }, |
There was a problem hiding this comment.
Problem: Source has a #fragment, so this redirect can never match
Fix: remove this entry
| { | |
| source: "/old-ownership#anchor", | |
| destination: "/code-ownership" | |
| }, |
| { | ||
| source: "/admin/http_https_configuration", | ||
| destination: "/self-hosted/http-https-configuration" | ||
| } |
There was a problem hiding this comment.
Problem: Source already has an earlier entry, so this one is never used
Fix: remove this entry
| { | |
| source: "/admin/http_https_configuration", | |
| destination: "/self-hosted/http-https-configuration" | |
| } |
❌ This PR introduces 8 broken link(s)OutboundYour PR includes links to pages or anchors that do not exist.
Absolute linksWrite links on this site as relative paths (
InboundA change your PR made broke inbound links from these other files. Please fix the inbound links in these other files.
Reproduce locally with Adding a redirect in |
| - When viewing a file or directory, press the `y` key to expand the URL to its canonical form (with the full 40-character Git commit SHA). | ||
| - To share a link to multi-line range in a file, click on the starting line number and shift-click on the ending line number (in the left-hand gutter). | ||
|
|
||
| Test links for the check-links workflow (will be reverted): [site config](https://sourcegraph.com/docs/admin/config/site-config), [search](//www.sourcegraph.com/docs/code-search/), [moved page](http://docs.sourcegraph.com/admin/http_https_configuration#sourcegraph-via-docker-compose-caddy-2), [dead external](https://github.com/sourcegraph/docs/blob/main/this-file-does-not-exist.md), [live external](https://github.com/sourcegraph/docs). |
There was a problem hiding this comment.
Link: https://sourcegraph.com/docs/admin/config/site-config
Problem: Absolute link to this site
Fix: /admin/config/site-config
| Test links for the check-links workflow (will be reverted): [site config](https://sourcegraph.com/docs/admin/config/site-config), [search](//www.sourcegraph.com/docs/code-search/), [moved page](http://docs.sourcegraph.com/admin/http_https_configuration#sourcegraph-via-docker-compose-caddy-2), [dead external](https://github.com/sourcegraph/docs/blob/main/this-file-does-not-exist.md), [live external](https://github.com/sourcegraph/docs). | |
| Test links for the check-links workflow (will be reverted): [site config](/admin/config/site-config), [search](//www.sourcegraph.com/docs/code-search/), [moved page](http://docs.sourcegraph.com/admin/http_https_configuration#sourcegraph-via-docker-compose-caddy-2), [dead external](https://github.com/sourcegraph/docs/blob/main/this-file-does-not-exist.md), [live external](https://github.com/sourcegraph/docs). |
| - When viewing a file or directory, press the `y` key to expand the URL to its canonical form (with the full 40-character Git commit SHA). | ||
| - To share a link to multi-line range in a file, click on the starting line number and shift-click on the ending line number (in the left-hand gutter). | ||
|
|
||
| Test links for the check-links workflow (will be reverted): [site config](https://sourcegraph.com/docs/admin/config/site-config), [search](//www.sourcegraph.com/docs/code-search/), [moved page](http://docs.sourcegraph.com/admin/http_https_configuration#sourcegraph-via-docker-compose-caddy-2), [dead external](https://github.com/sourcegraph/docs/blob/main/this-file-does-not-exist.md), [live external](https://github.com/sourcegraph/docs). |
There was a problem hiding this comment.
Link: //www.sourcegraph.com/docs/code-search/
Problem: Absolute link to this site
Fix: /code-search
| Test links for the check-links workflow (will be reverted): [site config](https://sourcegraph.com/docs/admin/config/site-config), [search](//www.sourcegraph.com/docs/code-search/), [moved page](http://docs.sourcegraph.com/admin/http_https_configuration#sourcegraph-via-docker-compose-caddy-2), [dead external](https://github.com/sourcegraph/docs/blob/main/this-file-does-not-exist.md), [live external](https://github.com/sourcegraph/docs). | |
| Test links for the check-links workflow (will be reverted): [site config](https://sourcegraph.com/docs/admin/config/site-config), [search](/code-search), [moved page](http://docs.sourcegraph.com/admin/http_https_configuration#sourcegraph-via-docker-compose-caddy-2), [dead external](https://github.com/sourcegraph/docs/blob/main/this-file-does-not-exist.md), [live external](https://github.com/sourcegraph/docs). |
| - When viewing a file or directory, press the `y` key to expand the URL to its canonical form (with the full 40-character Git commit SHA). | ||
| - To share a link to multi-line range in a file, click on the starting line number and shift-click on the ending line number (in the left-hand gutter). | ||
|
|
||
| Test links for the check-links workflow (will be reverted): [site config](https://sourcegraph.com/docs/admin/config/site-config), [search](//www.sourcegraph.com/docs/code-search/), [moved page](http://docs.sourcegraph.com/admin/http_https_configuration#sourcegraph-via-docker-compose-caddy-2), [dead external](https://github.com/sourcegraph/docs/blob/main/this-file-does-not-exist.md), [live external](https://github.com/sourcegraph/docs). |
There was a problem hiding this comment.
Link: http://docs.sourcegraph.com/admin/http_https_configuration#sourcegraph-via-docker-compose-caddy-2
Problem: Absolute link to a moved page
Fix: /self-hosted/http-https-configuration#sourcegraph-via-docker-compose-caddy-2
| Test links for the check-links workflow (will be reverted): [site config](https://sourcegraph.com/docs/admin/config/site-config), [search](//www.sourcegraph.com/docs/code-search/), [moved page](http://docs.sourcegraph.com/admin/http_https_configuration#sourcegraph-via-docker-compose-caddy-2), [dead external](https://github.com/sourcegraph/docs/blob/main/this-file-does-not-exist.md), [live external](https://github.com/sourcegraph/docs). | |
| Test links for the check-links workflow (will be reverted): [site config](https://sourcegraph.com/docs/admin/config/site-config), [search](//www.sourcegraph.com/docs/code-search/), [moved page](/self-hosted/http-https-configuration#sourcegraph-via-docker-compose-caddy-2), [dead external](https://github.com/sourcegraph/docs/blob/main/this-file-does-not-exist.md), [live external](https://github.com/sourcegraph/docs). |
|
|
||
| Test links for the check-links workflow (will be reverted): [site config](https://sourcegraph.com/docs/admin/config/site-config), [search](//www.sourcegraph.com/docs/code-search/), [moved page](http://docs.sourcegraph.com/admin/http_https_configuration#sourcegraph-via-docker-compose-caddy-2), [dead external](https://github.com/sourcegraph/docs/blob/main/this-file-does-not-exist.md), [live external](https://github.com/sourcegraph/docs). | ||
|
|
||
| More test links, none of which the check can fix for you: [missing page](/code-search/no-such-page), [missing heading](/code-search/features#no-such-heading), [wrong case](/Code-Search/queries). |
There was a problem hiding this comment.
Link: /Code-Search/queries
Problem: Path case mismatch: works on macOS, 404s on the Linux build
Fix: /code-search/queries
| More test links, none of which the check can fix for you: [missing page](/code-search/no-such-page), [missing heading](/code-search/features#no-such-heading), [wrong case](/Code-Search/queries). | |
| More test links, none of which the check can fix for you: [missing page](/code-search/no-such-page), [missing heading](/code-search/features#no-such-heading), [wrong case](/code-search/queries). |
|
|
|
||
| More test links, none of which the check can fix for you: [missing page](/code-search/no-such-page), [missing heading](/code-search/features#no-such-heading), [wrong case](/Code-Search/queries). | ||
|
|
||
| Test paragraph for the spell check workflow (will be reverted): Sourcegraph indexs every repositry acros your organization, so seach results are alwasy fresh. It keeps compatability with the databse layer, and the exector runs each batch spec in its own contiainer. |
There was a problem hiding this comment.
indexs is not in the dictionary.
Did you mean indexes?
| Test paragraph for the spell check workflow (will be reverted): Sourcegraph indexs every repositry acros your organization, so seach results are alwasy fresh. It keeps compatability with the databse layer, and the exector runs each batch spec in its own contiainer. | |
| Test paragraph for the spell check workflow (will be reverted): Sourcegraph indexes every repositry acros your organization, so seach results are alwasy fresh. It keeps compatability with the databse layer, and the exector runs each batch spec in its own contiainer. |
Please correct the spelling, or add the word to cspell-allow-list.txt if it is correct.
|
|
||
| More test links, none of which the check can fix for you: [missing page](/code-search/no-such-page), [missing heading](/code-search/features#no-such-heading), [wrong case](/Code-Search/queries). | ||
|
|
||
| Test paragraph for the spell check workflow (will be reverted): Sourcegraph indexs every repositry acros your organization, so seach results are alwasy fresh. It keeps compatability with the databse layer, and the exector runs each batch spec in its own contiainer. |
There was a problem hiding this comment.
repositry is not in the dictionary.
Did you mean repository?
| Test paragraph for the spell check workflow (will be reverted): Sourcegraph indexs every repositry acros your organization, so seach results are alwasy fresh. It keeps compatability with the databse layer, and the exector runs each batch spec in its own contiainer. | |
| Test paragraph for the spell check workflow (will be reverted): Sourcegraph indexs every repository acros your organization, so seach results are alwasy fresh. It keeps compatability with the databse layer, and the exector runs each batch spec in its own contiainer. |
Please correct the spelling, or add the word to cspell-allow-list.txt if it is correct.
|
|
||
| More test links, none of which the check can fix for you: [missing page](/code-search/no-such-page), [missing heading](/code-search/features#no-such-heading), [wrong case](/Code-Search/queries). | ||
|
|
||
| Test paragraph for the spell check workflow (will be reverted): Sourcegraph indexs every repositry acros your organization, so seach results are alwasy fresh. It keeps compatability with the databse layer, and the exector runs each batch spec in its own contiainer. |
There was a problem hiding this comment.
acros is not in the dictionary.
Did you mean arcos?
| Test paragraph for the spell check workflow (will be reverted): Sourcegraph indexs every repositry acros your organization, so seach results are alwasy fresh. It keeps compatability with the databse layer, and the exector runs each batch spec in its own contiainer. | |
| Test paragraph for the spell check workflow (will be reverted): Sourcegraph indexs every repositry arcos your organization, so seach results are alwasy fresh. It keeps compatability with the databse layer, and the exector runs each batch spec in its own contiainer. |
Please correct the spelling, or add the word to cspell-allow-list.txt if it is correct.
|
|
||
| More test links, none of which the check can fix for you: [missing page](/code-search/no-such-page), [missing heading](/code-search/features#no-such-heading), [wrong case](/Code-Search/queries). | ||
|
|
||
| Test paragraph for the spell check workflow (will be reverted): Sourcegraph indexs every repositry acros your organization, so seach results are alwasy fresh. It keeps compatability with the databse layer, and the exector runs each batch spec in its own contiainer. |
There was a problem hiding this comment.
seach is not in the dictionary.
Did you mean search?
| Test paragraph for the spell check workflow (will be reverted): Sourcegraph indexs every repositry acros your organization, so seach results are alwasy fresh. It keeps compatability with the databse layer, and the exector runs each batch spec in its own contiainer. | |
| Test paragraph for the spell check workflow (will be reverted): Sourcegraph indexs every repositry acros your organization, so search results are alwasy fresh. It keeps compatability with the databse layer, and the exector runs each batch spec in its own contiainer. |
Please correct the spelling, or add the word to cspell-allow-list.txt if it is correct.
|
|
||
| More test links, none of which the check can fix for you: [missing page](/code-search/no-such-page), [missing heading](/code-search/features#no-such-heading), [wrong case](/Code-Search/queries). | ||
|
|
||
| Test paragraph for the spell check workflow (will be reverted): Sourcegraph indexs every repositry acros your organization, so seach results are alwasy fresh. It keeps compatability with the databse layer, and the exector runs each batch spec in its own contiainer. |
There was a problem hiding this comment.
alwasy is not in the dictionary.
Did you mean always?
| Test paragraph for the spell check workflow (will be reverted): Sourcegraph indexs every repositry acros your organization, so seach results are alwasy fresh. It keeps compatability with the databse layer, and the exector runs each batch spec in its own contiainer. | |
| Test paragraph for the spell check workflow (will be reverted): Sourcegraph indexs every repositry acros your organization, so seach results are always fresh. It keeps compatability with the databse layer, and the exector runs each batch spec in its own contiainer. |
Please correct the spelling, or add the word to cspell-allow-list.txt if it is correct.
|
|
||
| More test links, none of which the check can fix for you: [missing page](/code-search/no-such-page), [missing heading](/code-search/features#no-such-heading), [wrong case](/Code-Search/queries). | ||
|
|
||
| Test paragraph for the spell check workflow (will be reverted): Sourcegraph indexs every repositry acros your organization, so seach results are alwasy fresh. It keeps compatability with the databse layer, and the exector runs each batch spec in its own contiainer. |
There was a problem hiding this comment.
databse is not in the dictionary.
Did you mean database?
| Test paragraph for the spell check workflow (will be reverted): Sourcegraph indexs every repositry acros your organization, so seach results are alwasy fresh. It keeps compatability with the databse layer, and the exector runs each batch spec in its own contiainer. | |
| Test paragraph for the spell check workflow (will be reverted): Sourcegraph indexs every repositry acros your organization, so seach results are alwasy fresh. It keeps compatability with the database layer, and the exector runs each batch spec in its own contiainer. |
Please correct the spelling, or add the word to cspell-allow-list.txt if it is correct.
|
|
||
| More test links, none of which the check can fix for you: [missing page](/code-search/no-such-page), [missing heading](/code-search/features#no-such-heading), [wrong case](/Code-Search/queries). | ||
|
|
||
| Test paragraph for the spell check workflow (will be reverted): Sourcegraph indexs every repositry acros your organization, so seach results are alwasy fresh. It keeps compatability with the databse layer, and the exector runs each batch spec in its own contiainer. |
There was a problem hiding this comment.
exector is not in the dictionary.
Did you mean executor?
| Test paragraph for the spell check workflow (will be reverted): Sourcegraph indexs every repositry acros your organization, so seach results are alwasy fresh. It keeps compatability with the databse layer, and the exector runs each batch spec in its own contiainer. | |
| Test paragraph for the spell check workflow (will be reverted): Sourcegraph indexs every repositry acros your organization, so seach results are alwasy fresh. It keeps compatability with the databse layer, and the executor runs each batch spec in its own contiainer. |
Please correct the spelling, or add the word to cspell-allow-list.txt if it is correct.
|
|
||
| More test links, none of which the check can fix for you: [missing page](/code-search/no-such-page), [missing heading](/code-search/features#no-such-heading), [wrong case](/Code-Search/queries). | ||
|
|
||
| Test paragraph for the spell check workflow (will be reverted): Sourcegraph indexs every repositry acros your organization, so seach results are alwasy fresh. It keeps compatability with the databse layer, and the exector runs each batch spec in its own contiainer. |
There was a problem hiding this comment.
contiainer is not in the dictionary.
Did you mean container?
| Test paragraph for the spell check workflow (will be reverted): Sourcegraph indexs every repositry acros your organization, so seach results are alwasy fresh. It keeps compatability with the databse layer, and the exector runs each batch spec in its own contiainer. | |
| Test paragraph for the spell check workflow (will be reverted): Sourcegraph indexs every repositry acros your organization, so seach results are alwasy fresh. It keeps compatability with the databse layer, and the exector runs each batch spec in its own container. |
Please correct the spelling, or add the word to cspell-allow-list.txt if it is correct.
| }, | ||
| { | ||
| source: "/old-ownership", | ||
| destination: "/code-ownershp" |
There was a problem hiding this comment.
ownershp is not in the dictionary.
Did you mean ownership?
| destination: "/code-ownershp" | |
| destination: "/code-ownership" |
Please correct the spelling, or add the word to cspell-allow-list.txt if it is correct.
| Zaporizhzhia | ||
| Zoekt | ||
| zoomable | ||
| aardvark # test entry for the sorted-list check (will be reverted) |
There was a problem hiding this comment.
aardvark is out of alphabetical order: move it above acmeco on line 26.
Co-authored-by: Amp <amp@ampcode.com> Amp-Thread-ID: https://ampcode.com/threads/T-01a08fee-74b4-76dc-aaf9-d1245d68fdc9
…ving the old wording Amp-Thread-ID: https://ampcode.com/threads/T-01a08fee-74b4-76dc-aaf9-d1245d68fdc9 Co-authored-by: Amp <amp@ampcode.com>
595eda4 to
d5c0ea6
Compare
Vercel shows build logs only to members of its team, so contributors saw a red X and a login wall. On vercel.deployment.error this posts the tail of the build log on the PR; on the next successful build the same comment is updated to say the failure is fixed. Fork PRs are skipped so the project-scoped Vercel token is never used on their behalf.
… (do not merge) Check links: three absolute self-links (one to a moved page) and a dead external link on one line; a missing page, missing heading, and wrong-case path on the next; and the "Symbol search" heading renamed to break the inbound anchor link from search-based-code-navigation.mdx. Spell check: nine misspellings on one line, five of them block-list words. Check redirects: one broken entry per category (shadowed page, #fragment source, /docs prefix, duplicate source, chain, missing page, missing heading). Co-authored-by: Amp <amp@ampcode.com> Amp-Thread-ID: https://ampcode.com/threads/T-01a08fee-74b4-76dc-aaf9-d1245d68fdc9
d5c0ea6 to
7333b3f
Compare
❌ The Vercel build failed for this PRVercel only shows build logs to members of its team, so here is the end of the log. Build log |
|
Moved to #1948 (branch renamed to |
Test PR to exercise the spell check, check-links, and check-redirects PR checks on one commit that breaks all three. This PR stays broken; #1921 applies the checks' suggested fixes and then fixes the rest by hand, for a side-by-side comparison.
Built on
mainplus the check PRs not merged yet, so their latest code runs here: #1880 (check-redirects), #1916 (check-links report format), #1919 (spell check inline-comment updates).Replaces #1913. Do not merge.
Merge order for the PR-check stack
Trial-merged onto
mainin this order with no conflicts:dev/sync-review-comments.sh, which ci/redirects: Add Redirect check for PRs #1880 callsdev/check-links.mjs; rebase after check-links: one suggestion per fix, synced with findings; one fact per line in reports #1916 mergesSquash-merge each, then rebase the next onto
main.#1920 (broken) and #1921 (fixed) are the example PRs that exercise every check; never merge, close them once the stack has landed.