Skip to content

ENH: Add GitHub Action based Link checker#217

Merged
mmcky merged 5 commits intomainfrom
link-checker
Sep 7, 2022
Merged

ENH: Add GitHub Action based Link checker#217
mmcky merged 5 commits intomainfrom
link-checker

Conversation

@mmcky
Copy link
Copy Markdown
Contributor

@mmcky mmcky commented Sep 6, 2022

This PR enables a link check run for the website based on GitHub Actions workflow

It will also run when a PR is opened.

@github-actions github-actions bot temporarily deployed to commit September 6, 2022 04:45 Inactive
@github-actions github-actions bot temporarily deployed to commit September 6, 2022 04:45 Inactive
@mmcky
Copy link
Copy Markdown
Contributor Author

mmcky commented Sep 6, 2022

@HumphreyYang I am adding a link checker to this repository and will roll it out to the other lecture sites one we fine tune the workflows. There are a couple of broken links


parallelization.md:345: [broken] https://python-intro.quantecon.org/finite_markov.html#Ergodicity: Anchor 'Ergodicity' not found
about_py.md:477: [broken] https://www.dask.org/: 525 Server Error:  for url: https://www.dask.org/
python_essentials.md:626: [redirected with Found] https://www.python.org/dev/peps/pep-0008/ to https://peps.python.org/pep-0008/

would you mind to look at those and fix them on this branch. Then I will reopen this PR and trigger another run of the link checker to see if it fails on permanent redirects also.

@github-actions github-actions bot temporarily deployed to commit September 6, 2022 04:54 Inactive
@github-actions github-actions bot temporarily deployed to commit September 6, 2022 09:56 Inactive
@HumphreyYang HumphreyYang reopened this Sep 6, 2022
@mmcky
Copy link
Copy Markdown
Contributor Author

mmcky commented Sep 6, 2022

Thanks @HumphreyYang this looks great. Link Checker is passing now. Thanks.

@mmcky
Copy link
Copy Markdown
Contributor Author

mmcky commented Sep 6, 2022

Looking at the diff did you update the redirects as well?

@HumphreyYang
Copy link
Copy Markdown
Member

@HumphreyYang I am adding a link checker to this repository and will roll it out to the other lecture sites one we fine tune the workflows. There are a couple of broken links


parallelization.md:345: [broken] https://python-intro.quantecon.org/finite_markov.html#Ergodicity: Anchor 'Ergodicity' not found
about_py.md:477: [broken] https://www.dask.org/: 525 Server Error:  for url: https://www.dask.org/
python_essentials.md:626: [redirected with Found] https://www.python.org/dev/peps/pep-0008/ to https://peps.python.org/pep-0008/

would you mind to look at those and fix them on this branch. Then I will reopen this PR and trigger another run of the link checker to see if it fails on permanent redirects also.

Hi @mmcky,

I have tried the test again, it does not fail on permanent redirects. Sorry that I made a lot of unnecessary changes. I thought we need to change all redirected links based on your examples until I found some of the redirected links do not need to be changed.

@HumphreyYang
Copy link
Copy Markdown
Member

Looking at the diff did you update the redirects as well?

I changed some of them, but not all as you can see from the test result.

@github-actions github-actions bot temporarily deployed to commit September 6, 2022 11:00 Inactive
@HumphreyYang HumphreyYang reopened this Sep 6, 2022
@HumphreyYang
Copy link
Copy Markdown
Member

Looking at the diff did you update the redirects as well?

Hi @mmcky, I have reverted changes that are not necessary. I think the link checker is not failing redirected links.

Sorry for the misunderstanding before.

@mmcky
Copy link
Copy Markdown
Contributor Author

mmcky commented Sep 7, 2022

thanks @HumphreyYang -- sorry I wasn't clear. We will want to update the redirects as well to reduce possible future failures. But I was interested to know if redirects cause CI to fail :-)

It's good to know that it will only fail on broken links.

@mmcky mmcky merged commit f5e1d20 into main Sep 7, 2022
@mmcky mmcky deleted the link-checker branch September 7, 2022 00:42
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.

2 participants