feat(desktop-wake): add WeCom UIA warm-tree and ship n2-wake in 1.2.3
All checks were successful
Publish Python Package to Gitea / publish (push) Successful in 29s

Expose ensure_ui_ready via DuiLib GetAccessible inject path; package x86 native helpers for host/skill consumers.

Co-authored-by: Cursor <cursoragent@cursor.com>
This commit is contained in:
2026-08-02 08:42:38 +08:00
parent 3dc46b0555
commit 71091e38a9
29 changed files with 3088 additions and 3 deletions

View File

@@ -0,0 +1,40 @@
# jiangchang_desktop_wake
桌面 UIA Provider **暖树**(与 `jiangchang_skill_core` / `jiangchang_desktop_sdk` 平级)。
企微主路径:注入 `wecom_wake.dll`,对主窗 `SetWindowLongPtr` 后走 DuiLib
`GetAccessible` / `OnGetObject`(已验收冷树 findall 2→300+)。
可整目录删除:`src/jiangchang_desktop_wake` + `tests/desktop_wake`。
## 依赖
- Windows + 32-bit 企微
- `pip install uiautomation`(probe 深遍历)
- `native/desktop-wake.exe` + `native/wecom_wake.dll`(`native_src/build.ps1`)
## 快速试
```powershell
$env:PYTHONPATH = ".\src"
powershell -File src\jiangchang_desktop_wake\native_src\build.ps1
pip install uiautomation
# 正式 API(技能 / 拾取应调这个)
python -m jiangchang_desktop_wake ensure --profile wecom
```
```python
from jiangchang_desktop_wake import ensure_ui_ready, probe
r = ensure_ui_ready("wecom") # 仍冷则抛 DesktopWakeError
print(r.warm, r.probe_after.findall_count)
```
| CLI | 退出码 |
|---|---|
| `ensure` | `0` 已暖;非 0 仍冷或异常 |
| `probe` | `0` 暖;`2` 冷 |
| `inject` / `c2` | 诊断用 |
完整验收见 [ACCEPTANCE.md](ACCEPTANCE.md)。