Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

🌱 Change link checker #517

Open
wants to merge 1 commit into
base: source
Choose a base branch
from

Conversation

peppi-lotta
Copy link
Member

@peppi-lotta peppi-lotta commented Nov 11, 2024

Current Broken-link-checker is not actually checking in the https://metal3.io/ webpage. It is causing a lot of flakes like this:
#448
#485

This PR would help fix these reoccurring issues by changing the link checker provider: https://github.com/lycheeverse/lychee-action

I've tested this code in my own fork. It creates quite nice reports peppi-lotta#4.

@metal3-io-bot
Copy link
Contributor

[APPROVALNOTIFIER] This PR is NOT APPROVED

This pull-request has been approved by:
Once this PR has been reviewed and has the lgtm label, please assign rozzii for approval. For more information see the Kubernetes Code Review Process.

The full list of commands accepted by this bot can be found here.

Needs approval from an approver in each of these files:

Approvers can indicate their approval by writing /approve in a comment
Approvers can cancel approval by writing /approve cancel in a comment

Copy link

netlify bot commented Nov 11, 2024

Deploy Preview for metal3io-website ready!

Name Link
🔨 Latest commit 3ece798
🔍 Latest deploy log https://app.netlify.com/sites/metal3io-website/deploys/67321d35dc8e0600086bad42
😎 Deploy Preview https://deploy-preview-517--metal3io-website.netlify.app
📱 Preview on mobile
Toggle QR Code...

QR Code

Use your smartphone camera to open QR code link.

To edit notification comments on pull requests, go to your Netlify site configuration.

@metal3-io-bot metal3-io-bot added the size/M Denotes a PR that changes 30-99 lines, ignoring generated files. label Nov 11, 2024
@peppi-lotta peppi-lotta force-pushed the peppi-lotta/change-link-checker branch from 4134bb4 to f7fc30f Compare November 11, 2024 15:04
Signed-off-by: Peppi-Lotta <peppi-lotta.saari@est.tech>
@peppi-lotta peppi-lotta force-pushed the peppi-lotta/change-link-checker branch from f7fc30f to 3ece798 Compare November 11, 2024 15:05
@tuminoid
Copy link
Member

Report is nice, but it is full of false positives. If you look at it, it fails to local files, template variables etc which are not right. It seems to be parsing source rather than the live website?

/hold

@metal3-io-bot metal3-io-bot added the do-not-merge/hold Indicates that a PR should not merge because someone has issued a /hold command. label Nov 11, 2024
permissions:
contents: read
issues: write

if: github.repository == 'metal3-io/metal3-io.github.io'
if: github.repository == 'peppi-lotta/metal3-io.github.io'
Copy link
Member

Choose a reason for hiding this comment

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

This is pointing wrong place

on:
repository_dispatch:
Copy link
Member

Choose a reason for hiding this comment

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

Is there reason to reove what we had before?

steps:
- name: Broken Link Check
uses: technote-space/broken-link-checker-action@b8332d945b97f8b52eb8d7d889a1e0e37106c1a9 # v2.3.2
- uses: actions/checkout@v4
Copy link
Member

Choose a reason for hiding this comment

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

This needs to be pinned down.


- name: Link Checker
id: lychee
uses: lycheeverse/lychee-action@v2
Copy link
Member

Choose a reason for hiding this comment

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

Same as this.

id: lychee
uses: lycheeverse/lychee-action@v2
with:
args: --user-agent "Mozilla/5.0 (Windows NT 6.1; Win64; x64; rv:59.0) Gecko/20100101 Firefox/59.0" --no-progress --accept 429 './**/*.md' './**/*.html' './**/*.rst'
Copy link
Member

Choose a reason for hiding this comment

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

This seems to be the issue. It is parsing markdown files and rst files as is, and not actually the website.


- name: Create Issue From File
if: steps.lychee.outputs.exit_code != 0
uses: peter-evans/create-issue-from-file@v5
Copy link
Member

Choose a reason for hiding this comment

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

pinning

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
do-not-merge/hold Indicates that a PR should not merge because someone has issued a /hold command. size/M Denotes a PR that changes 30-99 lines, ignoring generated files.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants