claude-code - 💡(How to fix) Fix [BUG] VS Code extension UI does not open on WSL2 — PendingMigrationError: navigator is now a global in nodejs (persists on v2.1.133 / VSCode 1.119.0)

Official PRs (…)
ON THIS PAGE

Recommended Tools

×6

Utilities matched from this issue’s tags and category — try them while you read without losing context.

GitHub issue graph ai analysis

Paste a GitHub issue URL. We fetch that issue, discover linked issues from bodies/comments/timeline, collect linked pull requests, and produce a structured English report.

The report is written in English Markdown for sharing and archival.

Helpful · Quick feedback

Loading…

Error Message

[info] ExtensionService#_doActivateExtension Anthropic.claude-code, activationEvent: 'onView:claudeVSCodeSidebarSecondary'

[error] PendingMigrationError: navigator is now a global in nodejs at Object.<anonymous> (.../extension.js:80:12008)

[error] PendingMigrationError: navigator is now a global in nodejs at .../extension.js:162:73719 at get value .../extension.js:162:72439 at new ZodObject .../extension.js:162:70507 at J1 .../extension.js:190:18333

[error] PendingMigrationError: navigator is now a global in nodejs at .../extension.js:275:12209 at new ZodObject .../extension.js:275:8999 at P1 .../extension.js:303:18345

Logs location: ~/.vscode-server/data/logs/<date>/exthost*/remoteexthost.log

Root Cause

The root cause visible in the logs is PendingMigrationError: navigator is now a global in nodejs, thrown 3 times during extension activation inside Zod schema initialization, before any user interaction or command execution.

Code Example

[info]  ExtensionService#_doActivateExtension Anthropic.claude-code,
          activationEvent: 'onView:claudeVSCodeSidebarSecondary'

  [error] PendingMigrationError: navigator is now a global in nodejs
          at Object.<anonymous> (.../extension.js:80:12008)

  [error] PendingMigrationError: navigator is now a global in nodejs
          at .../extension.js:162:73719
          at get value .../extension.js:162:72439
          at new ZodObject .../extension.js:162:70507
          at J1 .../extension.js:190:18333

  [error] PendingMigrationError: navigator is now a global in nodejs
          at .../extension.js:275:12209
          at new ZodObject .../extension.js:275:8999
          at P1 .../extension.js:303:18345

  Logs location: ~/.vscode-server/data/logs/<date>/exthost*/remoteexthost.log
RAW_BUFFERClick to expand / collapse

Preflight Checklist

  • I have searched existing issues and this hasn't been reported yet
  • This is a single bug report (please file separate reports for different bugs)
  • I am using the latest version of Claude Code

What's Wrong?

The Claude Code VS Code extension activates but the chat UI never opens on WSL2. Clicking any action to open the chat (sidebar, command palette, keybinding) does nothing — no panel opens, no error is shown to the user.

The root cause visible in the logs is PendingMigrationError: navigator is now a global in nodejs, thrown 3 times during extension activation inside Zod schema initialization, before any user interaction or command execution.

Setting claudeCode.useTerminal: true does not help — the error occurs before any setting is read.

This was previously reported in #37741 and #21877, both closed by the stale bot. The issue persists on fully updated systems as of May 2026.

What Should Happen?

The Claude Code chat UI should open when triggered via sidebar, command palette, or keybinding.

Error Messages/Logs

[info]  ExtensionService#_doActivateExtension Anthropic.claude-code,
          activationEvent: 'onView:claudeVSCodeSidebarSecondary'

  [error] PendingMigrationError: navigator is now a global in nodejs
          at Object.<anonymous> (.../extension.js:80:12008)

  [error] PendingMigrationError: navigator is now a global in nodejs
          at .../extension.js:162:73719
          at get value .../extension.js:162:72439
          at new ZodObject .../extension.js:162:70507
          at J1 .../extension.js:190:18333

  [error] PendingMigrationError: navigator is now a global in nodejs
          at .../extension.js:275:12209
          at new ZodObject .../extension.js:275:8999
          at P1 .../extension.js:303:18345

  Logs location: ~/.vscode-server/data/logs/<date>/exthost*/remoteexthost.log

Steps to Reproduce

Steps to Reproduce

  1. Open a WSL2 project in VS Code via code . from the WSL terminal
  2. Confirm the Claude Code extension is active in the Extensions panel
  3. Try to open the Claude Code chat via sidebar, command palette (Claude Code: Open), or keybinding
  4. Nothing happens — no chat UI opens
  5. Check logs at ~/.vscode-server/data/logs/<date>/exthost*/remoteexthost.log and observe 3x PendingMigrationError during activation

Claude Model

Not sure / Multiple models

Is this a regression?

Yes, this worked in a previous version

Last Working Version

Unknown — issue also reported on v2.1.81 (#37741)

Claude Code Version

2.1.133 (Claude Code)

Platform

Anthropic API

Operating System

Ubuntu/Debian Linux

Terminal/Shell

WSL (Windows Subsystem for Linux)

Additional Information

Additional Information

  • VSCode: 1.119.0 stable (released 2026-05-05)
  • Claude Code extension: 2.1.132 and 2.1.133 (both installed, both fail identically)
  • VSCode Server Node.js: v22.22.1
  • WSL2 distro: Ubuntu 20.04.6 LTS (Focal Fossa), kernel 5.15.133.1-microsoft-standard-WSL2

Root cause analysis: Node.js v22 introduced navigator as a global. The extension's bundled code accesses navigator at module load time (inside Zod schema initialization) to detect browser vs Node.js environment. VSCode's extension host intercepts this and throws PendingMigrationError, breaking the extension before it can register any UI commands.

Note: Claude Code CLI 2.1.133 works perfectly in the same environment — the issue is specific to the VS Code extension.

Related closed issues: #37741, #21877, #39682, #41213, #42547

Vote matrix · Quick signals

Works
Did the solution work? Tap to confirm.
Easy Fix
Was it a quick fix?
Time Saver
Did it save you time?
Blocking
Was it severely blocking?
Common Issue
Are others likely hitting this too?
Flaky / Intermittent
Is it intermittent?
Verified / Reproducible
Can you reproduce it reliably?
Loading…

Still need to ship something?

×6

Another batch ranked right after the header list — different links, same matching logic.

Back to top recommendations

TRENDING