Skip to content

test: cover native Wayland Hangul in isolated CI - #19174

Merged
nwparker merged 5 commits into
mainfrom
nwparker/test-native-wayland-hangul-ci
Sep 7, 2026
Merged

nwparker merged 5 commits into
mainfrom
nwparker/test-native-wayland-hangul-ci

Conversation

@nwparker

@nwparker nwparker commented Sep 7, 2026 •

Copy link
Copy Markdown
Contributor

Native Hangul terminating-digit coverage previously ran only under X11, which does not exercise the Wayland input path. Add an independent Linux Wayland job to the existing scheduled, manual, and reusable IME workflow. It runs the original scenario three times under nested GNOME, requires exact PTY bytes and native composition receipts for every execution, and rejects skips or retries.

Extend the existing isolated-session runner and its bounded process-group cleanup. GNOME owns IBus; the focus helper runs only in GitHub Actions against the private X server. The existing X11 path remains covered by the same validation workflow.

Validation: 72 focused unit/contract tests, the 107-gate manifest check, and lint passed. The diagnostic setup passed all three executions (nine exact Hangul-plus-digit lines) in https://github.com/stablyai/orca/actions/runs/34073076295. Initial permanent runner validation passed X11 but stopped before Wayland test launch on IBus selection. GNOME 42 spawns IBus with an environment allowlist that drops XDG_CONFIG_HOME, so the nested runner now uses the default config path for both daemon and CLI discovery. X11 retains its private configuration. The runner also waits for the compositor socket within the same startup deadline and reports IBus errors. The permanent runner then passed X11 and all three Wayland executions in https://github.com/stablyai/orca/actions/runs/34074017928; downloaded participation, native receipts, and compositor cleanup verified. Review follow-up asserts the Wayland launch and registers an experimental reliability gate. Final CI: https://github.com/stablyai/orca/actions/runs/34074484250. This adds coverage for Hangul terminating digits only, not all native Wayland IME interactions.

@coderabbitai

coderabbitai Bot commented Sep 7, 2026 •

Copy link
Copy Markdown
Contributor

Review Change Stack

No actionable comments were generated in the recent review. 🎉

ℹ️ Recent review info
⚙️ Run configuration

Configuration used: Repository UI

Review profile: CHILL

Plan: Team

Run ID: 62f85a28-dc38-4546-b6ce-c2b8cb7837af

📥 Commits

Reviewing files that changed from the base of the PR and between db365c5 and 3264e9d.

📒 Files selected for processing (3)
  • config/reliability-gates.jsonc
  • config/scripts/run-terminal-ibus-hangul-e2e.mjs
  • tests/e2e/terminal-hangul-terminating-digit-native.spec.ts

Included review availability: Your plan provides up to 10 included reviews per hour; 2 remain after this review.


📝 Walkthrough

Walkthrough

Adds a linux-wayland GitHub Actions job for native Hangul terminal testing under nested GNOME Wayland. Extends the E2E runner with Wayland-specific setup, Playwright execution, receipt verification, logs, and evidence output. Adds a compositor-window focus script and routes its changes to native IME tests. Adds workflow assertions, a Wayland reliability gate, and runtime assertions for the Wayland Electron session.

Merge Risk: ⚪ Minimal · up to 3264e

This adds an isolated Linux Wayland CI scenario for native Hangul terminating-digit input, with checks that the app uses Wayland and that all three executions produce the expected IME evidence. No merge-blocking current behavior risk is identified.

🚥 Pre-merge checks | ✅ 3 | ❌ 2

❌ Failed checks (2 warnings)

Check name Status Explanation Resolution
Docstring Coverage ⚠️ Warning Docstring coverage is 0.00% which is insufficient. The required threshold is 80.00%. Docstring coverage is scoped to functions touched by this diff. Analyzed 4 functions across 5 files. (1 skipped: 1 … Write docstrings for the functions missing them to satisfy the coverage threshold.
Description check ⚠️ Warning The description explains the change, motivation, implementation, and validation results. However, it omits most required template sections, including ELI5, Linked Issue, Visual Proof, Testing, Review,… Add the required template sections. Include a linked issue in the Fixes #... section, add before-and-after visual proof or write N/A with a reason, complete the Testing section and checklist, state AI disclosure details when applicable,…
✅ Passed checks (3 passed)
Check name Status Explanation
Linked Issues check ✅ Passed Check skipped because no linked issues were found for this pull request.
Out of Scope Changes check ✅ Passed Check skipped because no linked issues were found for this pull request.
Title check ✅ Passed The title clearly and concisely identifies the main change: isolated CI coverage for native Wayland Hangul input.
Full details: Docstring Coverage

Explanation

Docstring coverage is 0.00% which is insufficient. The required threshold is 80.00%. Docstring coverage is scoped to functions touched by this diff. Analyzed 4 functions across 5 files. (1 skipped: 1 unsupported.)

Full details: Description check

Explanation

The description explains the change, motivation, implementation, and validation results. However, it omits most required template sections, including ELI5, Linked Issue, Visual Proof, Testing, Review, Agent skill upstream boundary, Notes, and Checklist. The template also requires an issue link and visual proof or an explicit N/A statement.

Resolution

Add the required template sections. Include a linked issue in the Fixes #... section, add before-and-after visual proof or write N/A with a reason, complete the Testing section and checklist, state AI disclosure details when applicable, complete the Review and Agent skill upstream boundary sections, and document security, cross-platform, SSH, mobile, compatibility, and performance considerations in Notes.

  • Fix all pre-merge checks with AI
✨ Finishing Touches 💡 1
📝 Generate docstrings 💡
  • Create stacked PR
  • Commit on current branch

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.

❤️ Share

Comment @coderabbitai help to get the list of available commands.

@pullfrog pullfrog Bot left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

ℹ️ No critical issues — two minor suggestions inline, plus a few nits below.

Reviewed changes

  • New linux-wayland job — an independent Wayland job in the reusable IME workflow that installs nested-GNOME/IBus tooling, builds, runs the terminating-digit spec three times, and uploads evidence with if-no-files-found: error.
  • run-terminal-ibus-hangul-e2e.mjs nested branch — switches the isolated session to gnome-shell --nested --wayland, lets GNOME own IBus, runs the headful spec with --repeat-each=3 --retries=0, and verifies Playwright participation plus three exact native-engagement receipts.
  • focus-nested-wayland-terminal.sh — new focus helper that maps/focuses the single nested-compositor window and seat-clicks its center.
  • Routing + workflow contract test — registers the focus script in the native-IME harness route and pins the new job's install, run, and upload wiring.

ℹ️ Nitpicks

  • waitForHangulEngine's early-exit error says ibus-daemon exited early, but in the Wayland branch it is passed the window-manager process, so a gnome-shell crash would be misreported.
  • runOuter's platform guard still throws The native IBus Hangul E2E runner requires Linux/X11 even though it now also drives a Wayland session.
  • The ibusProcess?.pid ? processGroupMembers(ibusProcess.pid) : [] ternary in the finally block is dead-branch — it is already inside if (ibusProcess?.pid).

Note: 1 inline comment(s) dropped because they did not anchor to lines inside the PR diff:

  • config/scripts/run-terminal-ibus-hangul-e2e.mjs:342 (RIGHT) — line 342 (RIGHT) is not inside a diff hunk

Pullfrog  | Fix all ➔ | Fix 👍s ➔ | View workflow run | Using DeepSeek Pro (free via Pullfrog for OSS) | 𝕏

'config/scripts/focus-nested-wayland-terminal.sh'
),
ORCA_E2E_EXTRA_APP_ARGS:
'--ozone-platform=wayland --enable-wayland-ime --wayland-text-input-version=3 --password-store=basic --use-mock-keychain --disable-gpu-sandbox',

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

The nested injector branch is gated on ORCA_E2E_IME_INJECTOR=nested, not on the app actually launching under Wayland, and the spec's launchDiagnostics.ozonePlatform is logged but never asserted. If --ozone-platform=wayland ever degraded to the X11 path the receipts would still verify (XIM ibus emits composition events too), silently losing the exact coverage this PR exists to add. Consider asserting launchDiagnostics.ozonePlatform === 'wayland' in the nested branch to pin the platform.

@pullfrog pullfrog Bot left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

ℹ️ No new issues in the latest commits — one prior finding that failed to anchor is re-raised inline.

Reviewed changes (since prior review)

  • IBus socket wait reordering — waitForHangulEngine now waits for the compositor socket before selecting the Hangul engine, and the timeout carries the last IBus stderr/status.
  • GNOME environment filtering — XDG_CONFIG_HOME/XDG_CACHE_HOME stay at their defaults in the nested Wayland session (GNOME 42 drops them when spawning IBus), while X11 keeps the private config dirs.

The two new changes are sound: the socket wait avoids a useless ibus engine hangul attempt before the compositor is up, and leaving XDG_CONFIG_HOME/XDG_CACHE_HOME unset for the Wayland session makes the CLI and the GNOME-spawned daemon agree on the dconf location (Node treats an undefined env value as unset, so this correctly omits the override rather than stringifying it).

Pullfrog  | Fix all ➔ | Fix 👍s ➔ | View workflow run | Using DeepSeek Pro (free via Pullfrog for OSS) | 𝕏

// Why unconditionally, and not only when Playwright failed: a skipped test reports as a pass,
// so exit code 0 is exactly the state this check exists to distrust.
const receiptText = existsSync(receiptPath) ? readFileSync(receiptPath, 'utf8') : ''
if (nestedWayland) {

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Re-raised from the prior review (where it failed to anchor): verifyPlaywrightParticipation runs before testExitCode is returned, so a genuine test failure (which sets stats.unexpected > 0) surfaces as a generic Native Wayland Hangul participation failed error rather than the actual assertion failure. The participation check only exists to distrust a green exit code — consider returning testExitCode first when it is non-zero, so the regression this test exists to catch is reported as itself rather than as a participation anomaly.

@pullfrog pullfrog Bot left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

ℹ️ No new issues in the latest commit — prior feedback is addressed. One minor observation from an earlier review remains open inline; nothing here repeats it.

Reviewed changes (since prior review)

  • Wayland launch assertion — the spec now asserts ozonePlatform === 'wayland' and a non-empty waylandDisplay in the nested branch, pinning the exact coverage this PR exists to add.
  • Reliability-gate registration — a new terminal-input.native-wayland-hangul-digit gate documents the invariant, oracle, evidence runs, flake history, and promotion criteria, and passes the manifest schema.
  • Diagnostics polish — waitForHangulEngine's parameter and error are now generic (sessionProcess / "IME session process"), runOuter no longer claims "X11" when it also drives Wayland, and the redundant finally ternary is gone.

The Wayland launch assertion resolves the earlier coverage-gap note cleanly, and the reliability-gate entry is complete and honestly marks the gate experimental with a soak requirement before promotion.

Pullfrog  | Fix it ➔ | View workflow run | Using DeepSeek Pro (free via Pullfrog for OSS) | 𝕏

@nwparker
nwparker merged commit 1e301ab into main Sep 7, 2026
34 checks passed
enrick-dev pushed a commit to enrick-dev/orca that referenced this pull request Oct 15, 2026
* test: exercise native Wayland Hangul in isolated CI session

* test: wait for nested compositor socket before selecting IBus

* test: align Wayland IBus discovery with GNOME environment filtering

* test: assert Wayland launch and register native Hangul evidence
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