Skip to content

CDP Connection — TradingView Desktop

Current Status (2026-04-20)

TradingView Desktop v3.0.0.7652 (MSIX, Electron 38, Chrome/140) now works with CDP using the COM API launcher.

Primary Method: MSIX COM API Launcher

The MSIX sandbox blocks standard launch methods from passing --remote-debugging-port. The fix uses Microsoft's IApplicationActivationManager COM API, which properly activates MSIX packages with command-line arguments.

# Unified launcher — auto-detects standalone vs MSIX
scripts\launch_tv_debug.bat

# MSIX-only PowerShell script (called by the bat file for MSIX installs)
powershell -ExecutionPolicy Bypass -File scripts\launch_msix_debug.ps1

How It Works

  1. Get-AppxPackage detects the MSIX install and resolves the AUMID automatically
  2. COM ActivateApplication launches the app with --remote-debugging-port=9222
  3. Polls http://localhost:9222/json/version until CDP is ready (up to 30 retries)

Verified Working

  • TradingView Desktop v3.0.0.7652 (MSIX)
  • Chrome/140.0.7339.133 (Electron 38.2.2)
  • CDP on port 9222
  • All MCP tools functional

Fallback: Chrome Browser

If MSIX COM activation breaks (e.g. after a TradingView update), use Chrome directly:

scripts\launch_chrome_cdp.bat

Or manually:

"C:\Program Files\Google\Chrome\Application\chrome.exe" ^
  --remote-debugging-port=9222 ^
  --user-data-dir="%USERPROFILE%\ChromeCDP" ^
  https://www.tradingview.com/chart

Requirements for Chrome method: 1. Close ALL Chrome instances before launching with CDP flag 2. Use a separate --user-data-dir (Chrome rejects CDP on the default profile) 3. Log into TradingView in the new profile (first time only)

What Does NOT Work with MSIX

  • ELECTRON_EXTRA_LAUNCH_ARGS env var — blocked by MSIX sandbox
  • Start-Process / ShellExecute with --remote-debugging-port — flag silently ignored
  • Direct start command — "Access is denied" on WindowsApps executables
  • dir /s /b on WindowsApps — ACL-protected by TrustedInstaller

Launch Scripts

Script Install Type Method
launch_tv_debug.bat Both (auto-detect) COM API for MSIX, Start-Process for standalone
launch_msix_debug.ps1 MSIX only COM IApplicationActivationManager
launch_chrome_cdp.bat N/A (Chrome) Chrome with separate profile