This is a proof of concept of my idea briefly outlined here #18380 (comment). The code is partially based on the merge script.
The new linter uses the pull request number available in the Travis env and the Github API to retrieve the PR description and checks it for common errors, currently @-prefixed GH usernames and fractional left-overs of the pull request template (identified by HTML comments). Currently, users mostly have to be reminded here manually to fix these things or they are caught in the merge process. Obviously this linter can be expanded to check for more similar issues, those are just the ones I am familiar with. For example, usernames in ACK messages could be added as well, as mentioned here: https://github.com/bitcoin-core/bitcoin-maintainer-tools/pull/51
If #18380 gets merged, the HTML comments part is useless but we could put a unique string in the bottom of the pull request template and then match against that. Alternatively, this PR could be a replacement for #18358
Open question: I was not sure if the script should be more forgiving. It expects to be run in Travis and otherwise fails. I think this makes sense because the user would have to provide the PR number manually if they want to run it locally. It also fails if there is an issue with the Github API which seems to have problems quite frequently. On the other hand, if Github is down, the CI checks should probably not be running anyway.