🧪Integrate jsonschema into pre-commit framework#2273
Conversation
There was a problem hiding this comment.
Pull Request Overview
This PR integrates jsonschema validation into the pre-commit framework to enforce best practices for GitHub Actions workflows, specifically ensuring all jobs define timeout limits.
- Adds
check-jsonschemapre-commit hooks for validating GitHub Actions and workflow files - Enforces timeout-minutes requirement on all workflow job definitions
- Adds timeout values to all workflow jobs (2-9 minutes depending on job complexity)
Reviewed Changes
Copilot reviewed 4 out of 4 changed files in this pull request and generated no comments.
| File | Description |
|---|---|
.pre-commit-config.yaml |
Adds check-jsonschema hooks for GitHub Actions/workflows validation and timeout enforcement; comments out check-readthedocs due to schema conflict |
.github/workflows/reusable-qa.yml |
Adds 2-minute timeout to the QA job with explanatory comment |
.github/workflows/ci.yml |
Adds timeouts to test (7 min), pypy (9 min), coverage-summary (1 min), and check (1 min) jobs |
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
sirosen
left a comment
There was a problem hiding this comment.
I've been uncertain about whether or not that require-timeouts schema really belongs in check-jsonschema -- I added it pretty early in the project and haven't felt sure about it. So I'm glad to see it here, it's signal that it's really useful, and not just to me!
I've started looking into the readthedocs schema issue a little, but I'll probably need to file an issue over there and ask some questions.
Anyway, none of that blocks this update!
|
Yep, I actually integrate it everywhere. |
This plugs built-in checks for GitHub Actions and Workflows, and also enforces timeouts on each job definition. The patch skips checking the RTD config as the schema demands the `build.tools` mapping to be non- empty which conflicts with what we've got as we provision Python via `uv` ourselves.
aaf24ee to
7f4ac74
Compare
…yntax-fix 📝 Fix MyST role syntax in PR #2273 change note
This plugs built-in checks for GitHub Actions and Workflows, and also enforces timeouts on each job definition. The patch skips checking the RTD config as the schema demands the
build.toolsmapping to be non- empty which conflicts with what we've got as we provision Python viauvourselves.Contributor checklist
changelog.d/(seechangelog.d/README.mdfor instructions) or the PR text says "no changelog needed".Maintainer checklist
bot:chronographer:skiplabel.