Skip to content

Commit 62cf3c4

Browse files
committed
fix(ci): 构建前强制重下 sherpa 库(规避 rust-cache 不完整恢复)
1 parent 12488c0 commit 62cf3c4

2 files changed

Lines changed: 10 additions & 1 deletion

File tree

‎.github/workflows/pr-check.yml‎

Lines changed: 6 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -114,12 +114,17 @@ jobs:
114114
# ai_client 默认 Provider 断言 / note_filter 两条黄金用例——待后续版本修复
115115
run: |
116116
cd app/src-tauri
117+
# rust-cache 恢复的 target/sherpa-onnx-prebuilt 可能不完整(历史 LNK1181),强制重新下载
118+
rm -rf target/sherpa-onnx-prebuilt
117119
cargo test -- --skip ai_client::tests::from_settings_resolves_default_provider_when_set --skip note_filter::golden_tests::session29_live_ui_excluded_from_points --skip note_filter::tests::ocr_points_exclude_watermark_junk_and_dupes
118120
- name: Lint (clippy)
119121
env:
120122
ORT_LIB_LOCATION: ${{ github.workspace }}/app/src-tauri/ort/ci
121123
ORT_PREFER_DYNAMIC_LINK: "1"
122-
run: cd app/src-tauri && cargo clippy -- -D warnings
124+
run: |
125+
cd app/src-tauri
126+
rm -rf target/sherpa-onnx-prebuilt
127+
cargo clippy -- -D warnings
123128
124129
# ===========================================================================
125130
# 官网 —— Next.js 静态站(构建验证,部署走 deploy-website.yml)

‎.github/workflows/release.yml‎

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -63,6 +63,8 @@ jobs:
6363
# ai_client 默认 Provider 断言 / note_filter 两条黄金用例——待后续版本修复
6464
run: |
6565
cd app/src-tauri
66+
# rust-cache 恢复的 target/sherpa-onnx-prebuilt 可能不完整(历史 LNK1181),强制重新下载
67+
rm -rf target/sherpa-onnx-prebuilt
6668
cargo test -- --skip ai_client::tests::from_settings_resolves_default_provider_when_set --skip note_filter::golden_tests::session29_live_ui_excluded_from_points --skip note_filter::tests::ocr_points_exclude_watermark_junk_and_dupes
6769
6870
build:
@@ -100,6 +102,8 @@ jobs:
100102
# CI 无法 unset env,直接移除 config 使注入消失,两库回退在线下载(CI 网络可达)
101103
run: |
102104
rm -f app/src-tauri/.cargo/config.toml
105+
# rust-cache 恢复的 target/sherpa-onnx-prebuilt 可能不完整(历史 LNK1181),强制重新下载
106+
rm -rf app/src-tauri/target/sherpa-onnx-prebuilt
103107
mkdir -p app/src-tauri/ort/ci
104108
curl -sL https://github.com/microsoft/onnxruntime/releases/download/v1.28.0/onnxruntime-win-x64-1.28.0.zip -o /tmp/ort.zip
105109
unzip -q /tmp/ort.zip -d /tmp/ortx

0 commit comments

Comments
 (0)