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¶
Get-AppxPackagedetects the MSIX install and resolves the AUMID automatically- COM
ActivateApplicationlaunches the app with--remote-debugging-port=9222 - Polls
http://localhost:9222/json/versionuntil 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_ARGSenv var — blocked by MSIX sandboxStart-Process/ShellExecutewith--remote-debugging-port— flag silently ignored- Direct
startcommand — "Access is denied" on WindowsApps executables dir /s /bon 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 |