fix(clients): include access.type in ZCode provider_config.json export - #5889
codingbooo wants to merge 1 commit into
Conversation
|
✅ Deterministic PR hygiene checks passed. |
⏳ DRAFT
What to do
Review readiness checklist
0/4 boxes ticked. This PR stays in draft until every box above is ticked. |
|
Navigate logical layers of code changes, visualize relationships, and explore their blast radius. No actionable comments were generated in the recent review. 🎉 ℹ️ Recent review info⚙️ Run configurationConfiguration used: Repository: lidge-jun/opencodex/.coderabbit.yaml Review profile: ASSERTIVE Plan: Advanced Run ID: 📒 Files selected for processing (2)
Included review availability: This review used your included allowance. Your plan provides up to 10 included reviews per hour; 9 remain after this review. 📝 WalkthroughWalkthroughThe ZCode provider rule now includes the ChangesZCode provider configuration
Priority: ➖ Normal Estimated code review effort: 1 (Trivial) | ~5 minutes Change: Bug fix · Severity of issue fixed: Medium Merge Risk: ⚪ Minimal · up to This change adds the access discriminator to the ZCode 3.14+ provider store, while older versions use a separate export format. No actionable merge risk remains. Security Architecture ReviewSecurity architecture risk: 🔵 Low · up to The change appears limited to making the exported provider rule valid for ZCode. It does not change the configured endpoint or credential, but compatibility with ZCode’s actual reader has not been independently verified. Retained concerns Security review detailsSecurity Blast Radius
Trust Boundaries and Controls
Resilience and Maintainability Implications
🚥 Pre-merge checks | ✅ 5✅ Passed checks (5 passed)
✨ Finishing Touches🧪 Generate unit tests (beta)
Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. Comment |
리뷰 · 우선순위 58 / 80이 풀리퀘스트의 바탕은 고침은 그 칸에 라인 - 라인 - 메인테이너의 판단이 필요한 지점
설명 위쪽 체크 세 칸은 켜져 있어요. 아래 자동 블록 네 칸은 비어 있어요. 이 글은 아직 초안이에요. 초안 게이트는 아래 블록을 봐요. 너의 추천
이 댓글은 grok-bot이 작성했습니다 |
lidge-jun#5889) Squashed carry of lidge-jun#5889. Closes lidge-jun#5861 Co-authored-by: codingbo <cnsdbo@163.com>
Summary
Closes #5861.
When exporting the managed OpenCodex block to ZCode 3.14+
provider_config.json,config.accesswas written as{ apiKey: "..." }without thetype: "api-key"discriminator. Because ZCode validatesaccessas a discriminated union ontype(api-key | zhipu-coding-plan-api-key | zhipu-account), the omitted discriminator caused aZodErroron launch, leading ZCode to discard the entire personal provider list.This fix:
type: "api-key"toZcodeStoreProviderRule['config']['access']andbuildZcodeStoreProviderRule.tests/clients/integrations-current-store.test.tsto verifyaccess.type === 'api-key'.Verification
bun run typecheckpassed cleanly.bun test tests/clients/integrations-current-store.test.tspassed (12/12 pass, 60 expect calls).Checklist
devReview readiness checklist
This PR stays in draft until every box below is ticked. Tick all four boxes once the requirements are met:
Required local validation passed; commands, results, and any full-suite exception are documented.
I pushed my PR to a recent dev commit (at most 10 behind; a maintainer may still ask for the exact tip before merge).
I resolved all correct Codex and CodeRabbit findings.
My PR is ready for review.
Summary by CodeRabbit