Skip to content

fix(ci): click visible packaged extension contribution#915

Closed
luoye520ww wants to merge 1 commit into
KunAgent:developfrom
luoye520ww:codex/fix-packaged-smoke-guest-target
Closed

fix(ci): click visible packaged extension contribution#915
luoye520ww wants to merge 1 commit into
KunAgent:developfrom
luoye520ww:codex/fix-packaged-smoke-guest-target

Conversation

@luoye520ww

Copy link
Copy Markdown
Collaborator

Problem

The packaged desktop Extension smoke intermittently waits forever for the `kun-extension` guest target even though the workbench is running. The same failure has appeared on Windows and macOS package jobs, with only the renderer page visible in CDP.

Root cause

The smoke searched for the first `[data-contribution-id]` element. The same attribute is present on non-interactive wrappers and webviews as well as the actual workbench button. A wrapper could be selected and clicked, so no extension guest was created.

Scope

This PR only hardens the packaged desktop smoke contribution click. It does not change renderer behavior, extension loading, or runtime protocols.

Changes

  • Restrict the smoke selector to contribution buttons.
  • Iterate all matching buttons and choose the first enabled, visible candidate.
  • Add a regression test preventing a return to the wrapper-wide selector.

Safety

  • The change is test-only/CI-only and does not alter application behavior.
  • Existing process-health, disabled-state, geometry, and timeout checks remain in place.
  • No secrets, paths, or user data are introduced.

Typecheck

```text
npm.cmd run typecheck
```

Passed.

Tests

```text
node --test scripts/smoke-packaged-extension-desktop.test.cjs
npm.cmd run lint
npm.cmd run build
git diff --check
```

Results: 17 desktop smoke tests passed; lint, build, and diff checks passed.

Actual validation

The local environment does not have a packaged cross-platform artifact, so native Windows/macOS package smoke was not claimed locally. The PR CI package jobs are the required artifact-level validation.

Review performed

  • Functional correctness
  • CDP target lifecycle
  • Hidden/duplicate contribution controls
  • Process and timeout cleanup
  • Cross-platform package smoke scope
  • PR size and test quality

Non-goals

The existing Runtime exit classification and Error Boundary PRs remain separate; this PR only fixes their shared desktop smoke harness failure.

Part of #885.

@luoye520ww

Copy link
Copy Markdown
Collaborator Author

This work is consolidated into #941, which contains the related CI diagnostics and packaged smoke fix as one tested PR. Closing this duplicate to avoid parallel review and PR noise.

@luoye520ww luoye520ww closed this Jul 14, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant