mirror of
https://github.com/snowy-yang/qqbotsdk.git
synced 2026-10-21 09:05:21 +00:00
deploy/secrets 探测同时证实两个 secrets 均未生效(MISSING),部署 工作流此前死于 wrangler 无凭据。checkout 在四轮检测里三度嫌疑:用 它的任务多次 8~26s 即死,而没有 checkout 步骤的 probe 每次都成功, github 探测时通时不通——典型间歇性故障。git clone 自家仓库彻底 绕开;CPython 下载仍走 npmmirror 镜像防 github 抖动。
34 lines
978 B
YAML
34 lines
978 B
YAML
name: 代码检测
|
||
|
||
on:
|
||
push:
|
||
branches: [main]
|
||
pull_request:
|
||
workflow_dispatch:
|
||
|
||
jobs:
|
||
lint:
|
||
name: ruff + pyright
|
||
runs-on: ubuntu-latest
|
||
steps:
|
||
# 不用 actions/checkout:runner 对 github 的连通性不稳定(probe.yml
|
||
# 实测多次工作流死于 checkout 阶段),改从 Gitea 本体克隆
|
||
- name: 检出代码
|
||
run: git clone --depth=1 "${GITHUB_SERVER_URL:-https://gitea.4i.hk}/${GITHUB_REPOSITORY}.git" .
|
||
|
||
- name: 安装 uv
|
||
run: pip install uv
|
||
|
||
- name: 同步依赖(含 dev 组)
|
||
run: uv sync
|
||
env:
|
||
# CPython 3.13 走 npmmirror 的 python-build-standalone 镜像,
|
||
# 避开 github releases 的间歇性不通
|
||
UV_PYTHON_INSTALL_MIRROR: https://registry.npmmirror.com/-/binary/python-build-standalone
|
||
|
||
- name: ruff 静态检查
|
||
run: uv run ruff check src tests examples
|
||
|
||
- name: pyright 类型检查
|
||
run: uv run pyright
|