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
Migrate validation to Jekyll hooks #2859
Conversation
6a16fb6
to
75670ee
Compare
75670ee
to
fe012a1
Compare
8dd305c
to
dd4fb33
Compare
24259c4
to
4c72c5e
Compare
4c72c5e
to
b529526
Compare
5174840
to
b53bb75
Compare
Adding a workflow to validate URLs every week. Converting this PR to draft. |
4663cb7
to
61048c8
Compare
@captn3m0, I just added a new workflow to trigger the links verification. You can see the result on https://github.com/endoflife-date/endoflife.date/actions/runs/5098680434/jobs/9165967471. |
61048c8
to
d082c86
Compare
f587743
to
7841514
Compare
Oddly the deploy-preview does not fail when there are errors. Will have to reinstate the validate.yml workflow. |
3b6f0e0
to
488fc1f
Compare
I found why : the error I introduced in one of the
|
488fc1f
to
e092366
Compare
e092366
to
cc779db
Compare
Re-checked validation errors:
|
cc779db
to
b98e8b3
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Merging this as:
- the build pass and the replacement solution has been extensively tested,
- it solves validation issues on PRs (for instance on this one the validation check is not executed),
- it improves the validation process overall,
- I would like to verify the new
check-links
workflow works as expected, - it would be interesting to see which links are now invalid thanks to
check-links
(did not check all links for some time), - the endoflife.date team looks pretty busy these days and I do not hope a review in the coming days.
@captn3m0 FYI
b98e8b3
to
652708d
Compare
Compared to the use of the validate.py script / validate.yaml workflow, this has the advantage of ensuring the validation is always performed. It also gives access to enriched data, which is useful for validated generated content, such as links. In addition to checks already implemented in the previous 'validate.py' script, this script: - Check that release dates are not too far in the future to avoid mistakes such as #3281 (max 30 days allowed). - Check all links are valid (even those in the products description). This check takes time and is not performed by default, but it can be triggered by setting the MUST_CHECK_URLS environment variable to true. To ensure links are regularly verified a new GitHub workflow, check-links.yml, has also been added. It runs every sunday at midnight. Note that: - Some links had to be excluded from the link validation because, despite being valid, they are sometime or systematically returning an error. - A dependency to open-uri (https://github.com/ruby/open-uri) has been added to simplify the validation of HTTP links. - The priority of the ProductDataEnricher plugin had to be set to normal, to allow hooks to be run before and after enrichment. - The deploy.sh has been cleaned-up and enriched with the deploy URL replacement originaly done in netlify.toml. Some alternate URLs has been changed or removed due to an enforcement of the rules regarding permalinks and alternate_urls (no more dots). Closes #1206, #2709, #3409.
652708d
to
443a180
Compare
Following merge:
|
Link validation running on https://github.com/endoflife-date/endoflife.date/actions/runs/5911191568. |
Compared to the use of the
validate.py
script /validate.yaml
workflow, this has the advantage of ensuring the validation is always performed. It also gives access to enriched data, which is useful for validated generated content, such as links.In addition to checks already implemented in the previous
validate.py
script, this script:MUST_CHECK_URLS
environment variable to true. To ensure links are regularly verified a new GitHub workflow,check-links.yml
, has also been added. It runs every Sunday at midnight.Note that:
ProductDataEnricher
plugin had to be set to normal, to allow hooks to be run before and after enrichment.deploy.sh
has been cleaned-up and enriched with the deploy URL replacement previously done innetlify.toml
.Some alternate URLs has been changed or removed due to an enforcement of the rules regarding permalinks and
alternate_urls
(no more dots).Closes #1206, #2709, #3409.