Skip to content

feat(vika): add minimal Windows platform adapters - #7178

Closed
openviking-superagent wants to merge 4 commits into
volcengine:feat/vikafrom
openviking-superagent:feat/windows-native-preview
Closed

openviking-superagent wants to merge 4 commits into
volcengine:feat/vikafrom
openviking-superagent:feat/windows-native-preview

Conversation

@openviking-superagent

@openviking-superagent openviking-superagent commented Nov 6, 2026 •

Copy link
Copy Markdown
Contributor

Description

Enable a native Windows x64 source-preview path using a small platform adapter. Users provision Node.js, PM2, Git Bash, runtime credentials and an existing OpenViking server. This is not an installer or a Windows release.

Reworked against ZaynJarvis's review on the initial head. Final diff against the review base (9b8557d): 31 files, +374/-50, including documentation and tests.

Scope

  • Keep executable/npm-shim adaptation, named pipes, Windows HOME fallback, taskkill process cleanup, PM2 shutdown handling and Windows upgrade rejection.
  • Fetch the pinned Windows Lark CLI ZIP through the existing checksummed artifact path. The Windows source-only entry does not extend existing Unix --all release targets.
  • Remove Windows ACL implementation, installer and smoke harness, VBS autostart, in-memory PM2 patch, PowerShell coding-tool replacements, Slack executable default and Windows workflow. Document prerequisites and limitations instead.
  • Restore Unix PM2 environment/path verification and Slack environment behavior. Preserve executable lookup semantics for POSIX paths containing slashes.
  • Include the verified Windows tilde-expansion fix, preserving POSIX literal backslashes and home directories containing replacement characters.
  • Hide Durable-host and connector-worker console windows only on Windows. No other spawn lifecycle changes.

No OV server, dependency-version, email-feature, database-schema or runtime-protocol change. Fork acceptance fixes for general failure notices and experimental release packaging are not mixed into this Windows PR.

Validation

  • npm run check: passed.
  • Full suite after slimming: 1,229 passed, 0 failed, 2 cancelled, 3 skipped. The two cancellations reproduce in the restored upstream OV lifecycle tests because an unref timeout has no live event-loop handle. That file passes 19/19 with a test-process keepalive preload; no unrelated test workaround was retained in this PR. This is not claimed as a fully green normal suite.
  • Platform/Lark tests: 7 passed, 1 Windows-only skipped on Linux.
  • Control/process/Slack/updater subset: 58 passed, 2 skipped.
  • Subsequent setup/deployment-config regression: 103/103 passed.
  • Subsequent Durable/connector-supervision regression: 27/27 passed.
  • Windows desktop validation of this reduced head remains required. Contributor results for the larger fork preview do not certify this head.

Human involvement

  • Human requested and reviewed the scope; a Windows contributor supplied reproductions.
  • Agent implementation and local self-review completed.
  • Independent maintainer approval and real-machine acceptance of the reduced head.

See vika/WINDOWS.md for source setup and user-managed PM2 startup. There is no claim of Windows release/updater support, hardened multi-user ACL isolation or complete connector parity. No release was built/published and no running production daemon was changed.

@ZaynJarvis ZaynJarvis left a comment •

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

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

Thanks for the Windows work. Direction is good, but this is too large to review as-is. The goal for this PR: get Windows running for the feasible scenario with a minimal, modular diff that doesn't touch mac/linux behavior. Real-machine testing will be done separately.

Keep (looks right, mostly guarded by win32 or pass-through on POSIX)

  • platform.mjs adapter + the import swaps in claude/codex/pi/opencode/lark
  • named-pipe socket path, HOME → USERPROFILE fallback
  • taskkill for process-tree kill, pm2 shutdown message handling in main.mjs
  • lark-cli.exe filename, disabling upgrade/updater on Windows
  • private-temp: skip the mode check on win32 (one line is enough)

Please drop (outside Vika's scope; document as prerequisites in WINDOWS.md instead)

  • windows-acl.mjs + tests
  • ensure-windows-lark-cli.mjs + tests. lark-cli is already fetched by scripts/install-lark-cli.mjs / build-release.mjs via the platform map in updater/src/artifacts.mjs; add a win32-x64 entry there and reuse that path
  • pm2-windows.cjs (in-memory pm2 patching): pm2/Node/Git Bash should be user-installed prerequisites
  • VBS autostart, install-windows.ps1, test-install-windows.ps1
  • PowerShell replacements for Pi/Durable tools (coding-tools.mjs, piPlatformTools, cliShellHint)
  • slack.exe default, Windows CI workflow (can come later once the preview is validated)

Unconditional changes that affect mac/linux. Please guard with win32 or revert

  1. updater/src/pm2.mjs cleanPm2ControlEnv: whitelist now adds TEMP/TMP/USERNAME/APPDATA etc. plus a case-normalising loop on all platforms
  2. verifyPm2App now calls realpath(release): throws ENOENT when the release is missing and starts accepting symlinks, both behavior changes
  3. runtimes.which → findExecutable: paths containing / are now resolved differently
  4. slack/cli.mjs env allowlist adds TEMP/TMP without a platform check

Rough target after slimming: ~25 files / ~300 lines including platform.test.

@openviking-superagent openviking-superagent changed the title feat(vika): add native Windows source preview feat(vika): add minimal Windows platform adapters Nov 7, 2026
@github-project-automation github-project-automation Bot moved this from Backlog to Done in OpenViking project Nov 8, 2026
@nexw
nexw deleted the feat/windows-native-preview branch November 12, 2026 15:09
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

Status: Done

Development

Successfully merging this pull request may close these issues.

2 participants