ci: align pipeline with local quality gate and add migration checks - #170
Merged
Conversation
- Split the single CI job into parallel backend / migrations / frontend jobs - Backend job now runs scripts/check.sh (ruff check + format, mypy, uv lock --check, pytest, alembic heads) so CI matches the local quality gate - Add a Postgres-backed migrations job that runs `alembic upgrade head` then `alembic downgrade base` to validate the migration chain both ways - Add concurrency cancel-in-progress, per-job timeout-minutes, and a workflow_dispatch trigger - Add pytest-cov with an 80% coverage floor enforced via scripts/check.sh (kept out of default pytest addopts so ad-hoc local runs stay clean) Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
|
The latest updates on your projects. Learn more about Vercel for GitHub.
|
Run only once a PR is ready for review, so stacked PRs that wait on an unmerged parent do not consume CI minutes while parked as drafts. Adds ready_for_review to the trigger types, without which converting a draft would never start a run. Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>
Contributor
Author
|
新增一个 commit,
|
MeteorsLiu
approved these changes
Aug 10, 2026
19 tasks
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
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.
关联 Issue
Closes #169
改动
backend/migrations/frontendbackendjob 调用scripts/check.sh(ruff check+format、mypy、uv lock --check、pytest、alembic heads),CI 与本地门禁统一migrationsjob:alembic upgrade head→alembic downgrade baseworkflow_dispatchpytest-cov,80% 覆盖率下限(置于check.sh,不进默认addopts,保证本地单文件测试不误报)验证
scripts/check.sh全绿:ruff check+format、mypy(11 文件无问题)、pytest 6 passed / 覆盖率 97.44%、alembic headspytest tests/test_health.py干净退出(exit 0)本轮不含(见 Issue Out of Scope)
依赖漏洞扫描(pip-audit / npm audit)、Dependabot、actions SHA 固定、CI 路径过滤 —— 后续独立 Issue 跟进。