feat(provider): consolidate provider and network safeguards#948
Closed
luoye520ww wants to merge 8 commits into
Closed
feat(provider): consolidate provider and network safeguards#948luoye520ww wants to merge 8 commits into
luoye520ww wants to merge 8 commits into
Conversation
This was referenced Jul 14, 2026
Collaborator
|
感谢 Provider/网络可靠性方向的工作。关闭当前聚合 PR 的原因是它把网络审批、自定义 CA、预算、队列、熔断和能力缓存六套合同放在一起,但绝大多数没有接入当前请求调用链;与 尤其网络主机匹配本身不足以独立构成 DNS/内网访问安全边界,因此不宜在没有真实调用方和完整威胁模型时固化这一整包 API。 如需要继续,请基于最新 |
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.
Problem
Provider and network safeguards were split across six contract PRs. The repository had definitions for network approval, provider circuit breaking, request queues, model budgets, custom CA bundles, and capability caching, but they were hard to review as one coherent policy surface.
Root cause
Each policy was introduced independently without a shared validation boundary or a single reviewable provider/network reliability change. The circuit-breaker policy also did not reserve the first half-open probe in its returned state, allowing concurrent callers to race.
Scope
This PR consolidates the provider/network contract layer and the Electron-free skill-service test fix. It defines bounded policies and pure decisions; it does not wire provider queues, budgets, CA loading, or network approval into every runtime call site.
Changes
Safety
Typecheck
Both passed.
Tests
Results: root 3 test files, 21 passed and 1 existing skipped; Kun 5 test files, 34/34 passed; lint, build, and diff check passed.
Actual validation
Review performed
PR size
Non-goals
Supersedes
Part of the broader provider/network reliability work; no issue is auto-closed by this PR.