Skip to content

refactor(cli-workflow): unexport internal-only interfaces#2436

Merged
lpcox merged 2 commits intomainfrom
copilot/remove-unused-exported-interfaces
May 3, 2026
Merged

refactor(cli-workflow): unexport internal-only interfaces#2436
lpcox merged 2 commits intomainfrom
copilot/remove-unused-exported-interfaces

Conversation

Copy link
Copy Markdown
Contributor

Copilot AI commented May 3, 2026

WorkflowCallbacks, WorkflowLogger, and WorkflowOptions were exported from src/cli-workflow.ts but never imported elsewhere — making them accidental public API surface.

Changes

  • src/cli-workflow.ts: Drop export from all three interfaces; they remain in scope for runMainWorkflow within the same module.
// before
export interface WorkflowCallbacks {  }
export interface WorkflowLogger {  }
export interface WorkflowOptions extends WorkflowCallbacks {  }

// after
interface WorkflowCallbacks {  }
interface WorkflowLogger {  }
interface WorkflowOptions extends WorkflowCallbacks {  }

WorkflowDependencies and runMainWorkflow retain their exports as they are part of the intended public surface.

Copilot AI changed the title [WIP] Remove unused exported interfaces in src/cli-workflow.ts refactor(cli-workflow): unexport internal-only interfaces May 3, 2026
Copilot finished work on behalf of lpcox May 3, 2026 14:00
Copilot AI requested a review from lpcox May 3, 2026 14:00
@lpcox lpcox marked this pull request as ready for review May 3, 2026 22:59
@lpcox lpcox requested a review from Mossaka as a code owner May 3, 2026 22:59
Copilot AI review requested due to automatic review settings May 3, 2026 22:59
@github-actions
Copy link
Copy Markdown
Contributor

github-actions Bot commented May 3, 2026

✅ Coverage Check Passed

Overall Coverage

Metric Base PR Delta
Lines 85.76% 85.84% 📈 +0.08%
Statements 85.64% 85.72% 📈 +0.08%
Functions 88.11% 88.11% ➡️ +0.00%
Branches 78.65% 78.69% 📈 +0.04%
📁 Per-file Coverage Changes (1 files)
File Lines (Before → After) Statements (Before → After)
src/docker-manager.ts 87.4% → 87.7% (+0.29%) 87.0% → 87.3% (+0.27%)

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

Reduces the accidental public TypeScript API surface of the CLI workflow module by making internal-only interfaces module-private, while keeping the intended public exports intact.

Changes:

  • Unexports WorkflowCallbacks, WorkflowLogger, and WorkflowOptions in src/cli-workflow.ts.
  • Keeps WorkflowDependencies and runMainWorkflow exported as the intended external surface.
Show a summary per file
File Description
src/cli-workflow.ts Makes three internal interfaces non-exported to avoid exposing them as public API/types.

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: 1

Comment thread src/cli-workflow.ts
Comment on lines +20 to 34
interface WorkflowCallbacks {
onHostIptablesSetup?: () => void;
onContainersStarted?: () => void;
}

export interface WorkflowLogger {
interface WorkflowLogger {
info: (message: string, ...args: unknown[]) => void;
success: (message: string, ...args: unknown[]) => void;
warn: (message: string, ...args: unknown[]) => void;
}

export interface WorkflowOptions extends WorkflowCallbacks {
interface WorkflowOptions extends WorkflowCallbacks {
logger: WorkflowLogger;
performCleanup: () => Promise<void>;
}
@github-actions
Copy link
Copy Markdown
Contributor

github-actions Bot commented May 3, 2026

🔥 Smoke Test Results

Test Status
GitHub MCP ✅ PR listed successfully
GitHub.com connectivity ✅ HTTP 200/301
File write/read ✅ File exists and readable

Overall: PASS

PR: refactor(cli-workflow): unexport internal-only interfaces — author @Copilot, assignees @lpcox @Copilot

📰 BREAKING: Report filed by Smoke Copilot

@github-actions
Copy link
Copy Markdown
Contributor

github-actions Bot commented May 3, 2026

Smoke Test: Copilot BYOK — PASS ✅

Test Result
GitHub MCP (list PRs) ✅ PR #2417 "feat: add 4 agentic code quality workflows" returned
GitHub.com connectivity ✅ (pre-step confirmed HTTP 200/301)
File write/read ⚠️ Pre-step template vars not interpolated; file not found at expected path
BYOK inference (this response)

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

PR author: @Copilot — Assignees: @lpcox, @Copilot

Overall: PASS (file test skipped due to missing pre-step data)

🔑 BYOK report filed by Smoke Copilot BYOK

@github-actions
Copy link
Copy Markdown
Contributor

github-actions Bot commented May 3, 2026

Smoke Test Results:

✅ GitHub MCP: Retrieved 2 merged PRs (#2417, #2409)
✅ Playwright: Verified GitHub page title contains "GitHub"
✅ File Writing: Created smoke-test-claude-25281159350.txt
✅ Bash: Verified file creation

Status: PASS

💥 [THE END] — Illustrated by Smoke Claude

@github-actions
Copy link
Copy Markdown
Contributor

github-actions Bot commented May 3, 2026

feat: add 4 agentic code quality workflows
refactor(api-proxy): extract ProviderAdapter abstraction, make core provider-agnostic
GitHub review ✅
Safeinputs GH CLI ❌
Playwright ✅
Tavily search ❌
File write/read ✅
Discussion comment ✅
Build AWF ✅
Overall: 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 3, 2026

Chroot Version Comparison Results

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

Overall: ❌ FAILED — Python and Node.js versions differ between host and chroot environment.

Tested by Smoke Chroot

@github-actions
Copy link
Copy Markdown
Contributor

github-actions Bot commented May 3, 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 passed ✅ PASS
Node.js execa passed ✅ PASS
Node.js p-limit 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 #2436 · ● 561.3K ·

@github-actions
Copy link
Copy Markdown
Contributor

github-actions Bot commented May 3, 2026

Smoke Test Results

  • ❌ Redis (host.docker.internal:6379): timeout/no response
  • ❌ PostgreSQL pg_isready (host.docker.internal:5432): no response
  • ❌ PostgreSQL SELECT 1: skipped (pg_isready failed)

Overall: FAIL — service containers unreachable from this environment.

🔌 Service connectivity validated by Smoke Services

@lpcox
Copy link
Copy Markdown
Collaborator

lpcox commented May 3, 2026

@copilot address the review feedback

Copy link
Copy Markdown
Contributor Author

Copilot AI commented May 3, 2026

@copilot address the review feedback

This is safe — @github/agentic-workflow-firewall is a CLI binary, not a library. package.json has no "types" or "exports" field, "main" points to the CLI entry point (dist/cli.js), and there is no src/index.ts barrel. The generated .d.ts files are a build artefact with no declared public surface, so removing these exports from the declaration output doesn't break any downstream consumer.

The reviewer's concern is valid in general, but doesn't apply here. No code change is needed.

Copilot finished work on behalf of lpcox May 3, 2026 23:14
@lpcox lpcox merged commit 0932ace into main May 3, 2026
65 of 74 checks passed
@lpcox lpcox deleted the copilot/remove-unused-exported-interfaces branch May 3, 2026 23:16
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

[Export Audit] Unused exported interfaces in src/cli-workflow.ts: WorkflowCallbacks, WorkflowLogger, WorkflowOptions

3 participants