Skip to content

refactor: remove dead re-exports from providers/index.js#2800

Merged
lpcox merged 1 commit intomainfrom
fix/dead-reexports-providers
May 9, 2026
Merged

refactor: remove dead re-exports from providers/index.js#2800
lpcox merged 1 commit intomainfrom
fix/dead-reexports-providers

Conversation

@lpcox
Copy link
Copy Markdown
Collaborator

@lpcox lpcox commented May 9, 2026

Summary

Removes 5 individual adapter factory re-exports from providers/index.js that are never imported from that path.

Problem

providers/index.js re-exported all 5 individual adapter factories (createOpenAIAdapter, createAnthropicAdapter, createCopilotAdapter, createGeminiAdapter, createOpenCodeAdapter), but:

  • server.js only imports createAllAdapters
  • All test files import individual adapters directly from their provider modules (e.g., ./providers/copilot)

Changes

  • Removed 5 dead re-exports from module.exports in providers/index.js
  • Added comment clarifying the public API boundary

Verification

  • All 627 api-proxy tests pass
  • npm run build succeeds
  • Grep confirms no file imports individual adapters via ./providers (index.js)

Closes #2775

Remove 5 individual adapter factory re-exports (createOpenAIAdapter,
createAnthropicAdapter, createCopilotAdapter, createGeminiAdapter,
createOpenCodeAdapter) from providers/index.js.

Only createAllAdapters is imported from this module (by server.js).
All test files import individual adapters directly from their provider
modules (e.g., ./providers/copilot, ./providers/openai).

Closes #2775

Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
Copilot AI review requested due to automatic review settings May 9, 2026 13:59
@lpcox lpcox requested a review from Mossaka as a code owner May 9, 2026 13:59
@github-actions
Copy link
Copy Markdown
Contributor

github-actions Bot commented May 9, 2026

✅ Coverage Check Passed

Overall Coverage

Metric Base PR Delta
Lines 87.48% 87.55% 📈 +0.07%
Statements 87.44% 87.51% 📈 +0.07%
Functions 82.66% 82.66% ➡️ +0.00%
Branches 79.65% 79.69% 📈 +0.04%
📁 Per-file Coverage Changes (1 files)
File Lines (Before → After) Statements (Before → After)
src/container-lifecycle.ts 87.1% → 88.2% (+1.14%) 87.5% → 88.6% (+1.11%)

Coverage comparison generated by scripts/ci/compare-coverage.ts

Copy link
Copy Markdown
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

This PR narrows the containers/api-proxy/providers module’s public surface by removing unused adapter-factory re-exports from providers/index.js, leaving createAllAdapters as the sole exported API used by server.js.

Changes:

  • Removed dead module.exports re-exports for five individual adapter factories from containers/api-proxy/providers/index.js.
  • Added an in-file comment clarifying that individual adapters should be imported from their specific provider modules, and that createAllAdapters is the intended public API.
Show a summary per file
File Description
containers/api-proxy/providers/index.js Removes unused re-exports and documents createAllAdapters as the only supported export from the providers index module.

Copilot's findings

Tip

Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

  • Files reviewed: 1/1 changed files
  • Comments generated: 0

@github-actions
Copy link
Copy Markdown
Contributor

github-actions Bot commented May 9, 2026

🤖 Copilot Smoke Test Results

Test Status
GitHub MCP connectivity
GitHub.com HTTP connectivity ⚠️ N/A (pre-step outputs not expanded)
File write/read ⚠️ N/A (pre-step outputs not expanded)

PR: refactor: remove dead re-exports from providers/index.js — by @lpcox, reviewer: @Mossaka

Overall: PARTIAL — MCP confirmed working; pre-step smoke data unavailable (template vars not expanded in this run context).

📰 BREAKING: Report filed by Smoke Copilot

@github-actions
Copy link
Copy Markdown
Contributor

github-actions Bot commented May 9, 2026

Smoke Test Results

✅ GitHub MCP Testing: Last 2 merged PRs

✅ Playwright Testing: github.com page title verified
✅ File Writing Testing: smoke-test-claude-25602929472.txt created
✅ Bash Tool Testing: File verified

Status: PASS

💥 [THE END] — Illustrated by Smoke Claude

@github-actions
Copy link
Copy Markdown
Contributor

github-actions Bot commented May 9, 2026

Smoke Test: Copilot BYOK (Offline) Mode

Test Result
GitHub MCP connectivity
GitHub.com HTTP connectivity ⚠️ template var not resolved
File write/read ⚠️ template var not resolved
BYOK inference (this response)

Running in BYOK offline mode (COPILOT_OFFLINE=true) via api-proxy → api.githubcopilot.com

PR by @lpcox · reviewers: @Mossaka, @Copilot

Overall: PARTIAL — BYOK inference confirmed ✅; pre-computed step outputs (smoke-data) were not resolved at runtime so HTTP/file tests could not be verified.

🔑 BYOK report filed by Smoke Copilot BYOK

@github-actions github-actions Bot mentioned this pull request May 9, 2026
@github-actions
Copy link
Copy Markdown
Contributor

github-actions Bot commented May 9, 2026

Codex Smoke Test

  • docs: document effective token budget enforcement behavior
  • docs: sync schemas and specs with source changes
  • GitHub PR review: ✅; safeinputs-gh: ❌; Playwright: ✅; Tavily: ❌
  • File/bash: ✅; discussion comment: ✅; build: ✅
  • Overall status: FAIL

Warning

Firewall blocked 1 domain

The following domain was blocked by the firewall during workflow execution:

  • registry.npmjs.org

To allow these domains, add them to the network.allowed list in your workflow frontmatter:

network:
  allowed:
    - defaults
    - "registry.npmjs.org"

See Network Configuration for more information.

🔮 The oracle has spoken through Smoke Codex

@github-actions
Copy link
Copy Markdown
Contributor

github-actions Bot commented May 9, 2026

Chroot Smoke Test Results

Runtime Host Version Chroot Version Match?
Python Python 3.12.13 Python 3.12.3
Node.js v24.14.1 v20.20.2
Go go1.22.12 go1.22.12

Overall: ❌ Not all versions matched.

Go matches, but Python and Node.js differ between host and chroot environments.

Tested by Smoke Chroot

@github-actions
Copy link
Copy Markdown
Contributor

github-actions Bot commented May 9, 2026

🏗️ Build Test Suite Results

Ecosystem Project Build/Install Tests Status
Bun elysia 1/1 passed ✅ PASS
Bun hono 1/1 passed ✅ PASS
C++ fmt N/A ✅ PASS
C++ json N/A ✅ PASS
Deno oak N/A 1/1 passed ✅ PASS
Deno std N/A 1/1 passed ✅ PASS
.NET hello-world N/A ✅ PASS
.NET json-parse N/A ✅ PASS
Go color 1/1 passed ✅ PASS
Go env 1/1 passed ✅ PASS
Go uuid 1/1 passed ✅ PASS
Java gson 1/1 passed ✅ PASS
Java caffeine 1/1 passed ✅ PASS
Node.js clsx all passed ✅ PASS
Node.js execa all passed ✅ PASS
Node.js p-limit all passed ✅ PASS
Rust fd 1/1 passed ✅ PASS
Rust zoxide 1/1 passed ✅ PASS

Overall: 8/8 ecosystems passed — ✅ PASS

Generated by Build Test Suite for issue #2800 · ● 583.3K ·

@github-actions
Copy link
Copy Markdown
Contributor

github-actions Bot commented May 9, 2026

Smoke Test Results

  • Redis PING: ❌ (connection refused / timeout)
  • PostgreSQL pg_isready: ❌ (no response)
  • PostgreSQL SELECT 1: ❌ (unreachable)

host.docker.internal resolves to 172.17.0.1 but TCP connections to ports 6379 and 5432 both fail — service containers are not reachable from this runner.

Overall: FAIL

🔌 Service connectivity validated by Smoke Services

@lpcox lpcox merged commit 22a7a6b into main May 9, 2026
68 of 72 checks passed
@lpcox lpcox deleted the fix/dead-reexports-providers branch May 9, 2026 23:15
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

2 participants