refactor: route runtime ui resolver helper#240
refactor: route runtime ui resolver helper#240ndycode wants to merge 1 commit intorefactor/pr4-runtime-ui-resolver-helperfrom
Conversation
|
Important Review skippedAuto reviews are limited based on label configuration. 🚫 Review skipped — only excluded labels are configured. (1)
Please check the settings in the CodeRabbit UI or the ⚙️ Run configurationConfiguration used: Organization UI Review profile: ASSERTIVE Plan: Pro Run ID: You can disable this status message by setting the Use the checkbox below for a quick retry:
✨ Finishing Touches🧪 Generate unit tests (beta)
✨ Simplify code
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 |
|
Codex usage limits have been reached for code reviews. Please check with the admins of this repo to increase the limits by adding credits. |
Summary
index.tsWhat Changed
resolveUiRuntime()wrapperresolveRuntimeUiOptions(...)directly with the existing config/runtime dependenciesValidation
npm run lintnpm run typechecknpm run buildRisk and Rollback
eec7ec7to restore the inline runtime UI resolver wrapper inindex.tsAdditional Notes
note: greptile review for oc-chatgpt-multi-auth. cite files like
lib/foo.ts:123. confirm regression tests + windows concurrency/token redaction coverage.Greptile Summary
this pr finishes the ui runtime resolver extraction by removing the local
resolveUiRuntime()wrapper inindex.tsand callingresolveRuntimeUiOptions({ loadPluginConfig, applyUiRuntimeFromConfig })directly at each call site. the refactor is behavior-preserving — same deps, same side-effect path throughapplyUiRuntimeFromConfig— and fits cleanly into thelib/runtime/ui-runtime.tshelper established in the prior extraction.test/ui-runtime.test.tscovers the helper itself; none of the refactored call sites inindex.tshave direct coverage for the inline invocation pattern. project targets 80% threshold — worth noting for a future test pass.Confidence Score: 4/5
Important Files Changed
Sequence Diagram
sequenceDiagram participant P as OpenAIOAuthPlugin (index.ts) participant H as resolveRuntimeUiOptions (lib/runtime/ui-runtime.ts) participant C as loadPluginConfig participant A as applyUiRuntimeFromConfig note over P: plugin load (init) P->>H: resolveRuntimeUiOptions({ loadPluginConfig, applyUiRuntimeFromConfig }) H->>C: loadPluginConfig() C-->>H: TConfig H->>A: applyUiRuntimeFromConfig(config) A-->>H: UiRuntimeOptions (side-effect: sets UI runtime state) H-->>P: UiRuntimeOptions (discarded at init) note over P: tool execute() calls (codex-list, codex-status, etc.) P->>H: resolveRuntimeUiOptions({ loadPluginConfig, applyUiRuntimeFromConfig }) H->>C: loadPluginConfig() C-->>H: TConfig H->>A: applyUiRuntimeFromConfig(config) A-->>H: UiRuntimeOptions H-->>P: ui (used for v2Enabled / theme / glyphMode checks)Prompt To Fix All With AI
Last reviewed commit: "refactor: route runt..."