skip to Main Content

I’ve seen this error in several Stack Overflow posts, but none of them are quite like this, nor have they help. Every time I try to run my program I see this:

/Applications/Visual Studio Code.app/Contents/Resources/app/extensions/ms-vscode.js-debug/src/bootloader.js:8
`+r)),e.removeListener("error",er),e.destroy()}});var Rs=V((Vu,Cs)=>{"use strict";var xa=Object.create,pt=Object.defineProperty,ba=Object.getOwnPropertyDescriptor,Ss=Object.getOwnPropertyNames,va=Object.getPrototypeOf,Sa=Object.prototype.hasOwnProperty,Ea=(e,t)=>function(){return t||(0,e[Ss(e)[0]])((t={exports:{}}).exports,t),t.exports},Ta=(e,t)=>{for(var r in t)pt(e,r,{get:t[r],enumerable:!0})},Es=(e,t,r,n)=>{if(t&&typeof t=="object"||typeof t=="function")for(let s of Ss(t))!Sa.call(e,s)&&s!==r&&pt(e,s,{get:()=>t[s],enumerable:!(n=ba(t,s))||n.enumerable});return e},Ca=(e,t,r)=>(r=e!=null?xa(va(e)):{},Es(t||!e||!e.__esModule?pt(r,"default",{value:e,enumerable:!0}):r,e)),Ra=e=>Es(pt({},"__esModule",{value:!0}),e),Aa=Ea({"node_modules/request-light/lib/node/main.js"(e){(()=>{var t={46:(i,a)=>{"use strict";Object.defineProperty(a,"__esModule",{value:!0}),a.default=function(l,f,{signal:c}={}){return new

SyntaxError: Unexpected token '.'
    at Module._compile (internal/modules/cjs/loader.js:895:18)
    at Object.Module._extensions..js (internal/modules/cjs/loader.js:995:10)
    at Module.load (internal/modules/cjs/loader.js:815:32)
    at Function.Module._load (internal/modules/cjs/loader.js:727:14)
    at Module.require (internal/modules/cjs/loader.js:852:19)
    at Module._preloadModules (internal/modules/cjs/loader.js:1147:12)
    at loadPreloadModules (internal/bootstrap/pre_execution.js:443:5)
    at prepareMainThreadExecution (internal/bootstrap/pre_execution.js:62:3)
    at internal/main/run_main_module.js:7:1
Process exited with code 1

It looks like it’s in the extension that the problem is encountered.

/Applications/Visual Studio Code.app/Contents/Resources/app/extensions/ms-vscode.js-debug/src/bootloader.js:8

Tried several NodeJS versions. My current working version is 12.13.1.

2

Answers


  1. Cause

    This is probably a case of VS code crashes when debugging after update with Node <=12 #1624 (given that at least three (from my google search) similar issue tickets were raised in the VS Code GitHub repo recently, with two already closed as a duplicate of it: VS Code debugger crashing on version 1.77.0 (Universal)
    #178769
    , Javascript Debug Terminal does not work with node version earlier than 14.15.1
    #178759
    , Unable to run code after update to VSCODE v1.77.0
    #178998
    )

    Solutions

    This might be fixed now. Try updating to VS Code 1.77.1. See https://github.com/microsoft/vscode/issues/179288.

    You have options:


    For your reference, I found this info by googling "github vscode issues "Unexpected token '.'" "ms-vscode.js-debug/src/bootloader.js:8""

    Login or Signup to reply.
  2. Rollback VSCode to Feb 2023

    This bug was introduced some time in March this year

    1.75.1 seems to work for me

    Login or Signup to reply.
Please signup or login to give your own answer.
Back To Top
Search