Add CI step for checking if translations are properly marked as outdated #6428
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
what
this check protects us from the situations when someone has edited an original article (
en.md
), but forgot to check its translations and mark them as outdated by addingoutdated: true
andoutdated_since: {commit hash}
markers to their front matters.for cases which can't be handled automatically (say, you're fixing a typo which is only present in English article), it can be silenced by adding
SKIP_OUTDATED_CHECK
to the pull request's message (it may appear everywhere).example: TicClick#2. see CI output on individual commits, as well as its status for the whole PR (forced to OK by the tag):
where
it's... uh, inlined in the
continuous-integration.yml
file. could be moved into a separate script if necessary. if deemed useful, could be sped up by throwing out unnecesary steps like linters. could be moved to a separate workflow and sped up by caching the repository checked out.when
The script is triggered on default
pull_request
-related events plus PR message edits to catch the (dis)appearance ofSKIP_OUTDATED_CHECK
.why
...the check?
part of #6233. prevents articles expiring silently because of random maintainers' occasional lazy eye syndrom (at least #6197, #6189, #6111, #4651 -- found by me only).
...is this a GitHub Action?
...do you think people will follow it?
it prints errors AND direct suggestions on how to fix them. besides, it's important to know which translations are really up to date.