kit icon indicating copy to clipboard operation
kit copied to clipboard

The debugger not working on client side file (Firefox)

Open Simple-MAX opened this issue 1 year ago • 1 comments

Describe the bug

This is only a bug on Firefox and not Chrome

When creating a launch.json file in vscode we can set configurations to attach vscode debugger to node and the browser. this can be achieved by this

{
    "configurations": [
        {
            "name": "Launch Server",
            "request": "launch",
            "type": "node",
            "runtimeArgs": ["run","dev"],
            "runtimeExecutable": "npm",
            "skipFiles": ["<node_internals>/**"],
            "console": "integratedTerminal"
        },
        {
            "type": "firefox",
            "request": "launch",
            "name": "Launch Firefox",
            "url": "http://localhost:3000",
            "webRoot": "${workspaceFolder}",
        }
    ],
    "compounds": [
        {
            "name": "Compound",
            "configurations": ["Launch Server","Launch Firefox"]
        }
    ]
}

now by running the Compound runner, we can see vscode and Firefox working together on the breakpoints, but unfortunately, the break points don't work on client-side code in files like +layout.ts

-- test 1
Browser => Firefox 122.0.1 (64-bit)
OS => Windows 11 build 22621 WSL2
-- test 2
Browser => Firefox 123.0b8 (64-bit)
OS => MacOS Sonoma 14.2.1

Reproduction

use this lunch config

{
    "configurations": [
        {
            "name": "Launch Server",
            "request": "launch",
            "type": "node",
            "runtimeArgs": ["run","dev"],
            "runtimeExecutable": "npm",
            "skipFiles": ["<node_internals>/**"],
            "console": "integratedTerminal"
        },
        {
            "type": "firefox",
            "request": "launch",
            "name": "Launch Firefox",
            "url": "http://localhost:3000",
            "webRoot": "${workspaceFolder}",
        }
    ],
    "compounds": [
        {
            "name": "Compound",
            "configurations": ["Launch Server","Launch Firefox"]
        }
    ]
}

Logs

No response

System Info

System:
    OS: Linux 5.15 Ubuntu 22.04.3 LTS 22.04.3 LTS (Jammy Jellyfish)
    CPU: (20) x64 12th Gen Intel(R) Core(TM) i7-12700KF
    Memory: 10.24 GB / 15.55 GB
    Container: Yes
    Shell: 5.8.1 - /usr/bin/zsh
  Binaries:
    Node: 20.10.0 - ~/.volta/tools/image/node/20.10.0/bin/node
    npm: 10.2.3 - ~/.volta/tools/image/node/20.10.0/bin/npm
    pnpm: 8.14.0 - ~/.volta/bin/pnpm
    bun: 1.0.14 - ~/.volta/bin/bun
  npmPackages:
    @sveltejs/adapter-auto: ^3.0.1 => 3.0.1 
    @sveltejs/adapter-node: ^2.0.2 => 2.0.2 
    @sveltejs/adapter-static: ^3.0.1 => 3.0.1 
    @sveltejs/kit: ^2.0.6 => 2.0.6 
    @sveltejs/vite-plugin-svelte: ^3.0.1 => 3.0.1 
    svelte: ^4.2.8 => 4.2.8 
    vite: ^5.0.12 => 5.0.12 
-------------------------------------------------------
System:
    OS: macOS 14.2.1
    CPU: (8) arm64 Apple M2
    Memory: 74.22 MB / 16.00 GB
    Shell: 5.9 - /bin/zsh
  Binaries:
    Node: 20.9.0 - ~/.nvm/versions/node/v20.9.0/bin/node
    npm: 10.1.0 - ~/.nvm/versions/node/v20.9.0/bin/npm
  Browsers:
    Chrome: 121.0.6167.160
    Safari: 17.2.1
  npmPackages:
    @sveltejs/adapter-auto: ^3.0.1 => 3.0.0 
    @sveltejs/adapter-node: ^2.0.2 => 2.0.0 
    @sveltejs/adapter-static: ^3.0.1 => 3.0.0 
    @sveltejs/kit: ^2.0.6 => 2.0.3 
    @sveltejs/vite-plugin-svelte: ^3.0.1 => 3.0.1 
    svelte: ^4.2.8 => 4.2.8 
    vite: ^5.0.12 => 5.0.10

Severity

serious, but I can work around it

Additional Information

No response

Simple-MAX avatar Feb 09 '24 09:02 Simple-MAX

+1

steckoverflow avatar Feb 12 '24 10:02 steckoverflow