Не удается установить отладчик для Chrome в код Visual Studio - PullRequest
0 голосов
/ 05 мая 2018

Как видно из темы, я не могу установить расширение отладчика для Chrome в коде Visual Studio (версия: 1.23.0). Как и предлагалось в других постах, я закрыл VS Code, вышел на User.vscode \ extensions, удалил любую ссылку на него и перезапустил VS Code. Я попытался с помощью командной строки и получил эту ошибку (команда: code --install-extension msjsdiag.debugger-for-chrome):

$ code --install-extension msjsdiag.debugger-for-chrome
Found 'msjsdiag.debugger-for-chrome' in the marketplace.
Installing...
WARNING: Promise with no error callback:256
{ exception: null,
  error:
   { Error: ENOENT: no such file or directory, open 'C:\Users\SOMEUSER\.vscode\extensions\.msjsdiag.debugger-for-chrome-4.4.0\node_modules\vscode-chrome-debug-core\out\src\(*&)))&^.js'
     errno: -4058,
     code: 'ENOENT',
     syscall: 'open',
     path: 'C:\\Users\\SOMEUSER\\.vscode\\extensions\\.msjsdiag.debugger-for-chrome-4.4.0\\node_modules\\vscode-chrome-debug-core\\out\\src\\(*&)))&^.js' },
  promise:
   { _oncancel: null,
     _nextState: null,
     _state:
      { name: 'error',
        enter: [Function: enter],
        cancel: [Function: s],
        done: null,
        then: null,
        _completed: [Function: s],
        _error: [Function: s],
        _notify: [Function: v],
        _progress: [Function: s],
        _setCompleteValue: [Function: s],
        _setErrorValue: [Function: s] },
     _listeners: null,
     _value:
      { Error: ENOENT: no such file or directory, open 'C:\Users\SOMEUSER\.vscode\extensions\.msjsdiag.debugger-for-chrome-4.4.0\node_modules\vscode-chrome-debug-core\out\src\(*&)))&^.js'
        errno: -4058,
        code: 'ENOENT',
        syscall: 'open',
        path: 'C:\\Users\\SOMEUSER\\.vscode\\extensions\\.msjsdiag.debugger-for-chrome-4.4.0\\node_modules\\vscode-chrome-debug-core\\out\\src\\(*&)))&^.js' },
     _isException: false,
     _errorId: 256,
     done: [Function: done],
     then: [Function: then] },
  handler: undefined,
  id: 256,
  parent: undefined }
C:\Program Files\Microsoft VS Code\resources\app\out\vs\code\node\cli.js:58
define(e[9],t([1,0,2]),function(e,t,n){"use strict";function r(e){i(e)||t.errorHandler.onUnexpectedError(e)}function i(e){return e instanceof Error&&e.name===u&&e.message===u}Object.defineProperty(t,"__esModule",{value:!0});var o={};n.TPromise.addEventListener("error",function(e){var t=e.detail,n=t.id;t.parent?t.handler&&o&&delete o[n]:(o[n]=t,1===Object.keys(o).length&&setTimeout(function(){var e=o;o={},Object.keys(e).forEach(function(t){var n=e[t];n.exception?r(n.exception):n.error&&r(n.error),console.log("WARNING: Promise with no error callback:"+n.id),console.log(n),n.exception&&console.log(n.exception.stack)})},0))});var s=function(){function e(){this.listeners=[],this.unexpectedErrorHandler=function(e){setTimeout(function(){if(e.stack)throw new Error(e.message+"\n\n"+e.stack);throw e},0)}}return e.prototype.addListener=function(e){var t=this;return this.listeners.push(e),function(){t._removeListener(e)}},e.prototype.emit=funct

Error: ENOENT: no such file or directory, open 'C:\Users\SOMEUSER\.vscode\extensions\.msjsdiag.debugger-for-chrome-4.4.0\node_modules\vscode-chrome-debug-core\out\src\(*&)))&^.js'

Error: ENOENT: no such file or directory, open 'C:\Users\SOMEUSER\.vscode\extensions\.msjsdiag.debugger-for-chrome-4.4.0\node_modules\vscode-chrome-debug-core\out\src\(*&)))&^.js'
    at Timeout._onTimeout (C:\Program Files\Microsoft VS Code\resources\app\out\vs\code\node\cli.js:58:758)
    at ontimeout (timers.js:386:14)
    at tryOnTimeout (timers.js:250:5)
    at Timer.listOnTimeout (timers.js:214:5)

1 Ответ

0 голосов
/ 06 мая 2018

Вот временное решение:

  • закрыть VS Code
  • в проводнике перейдите в% UserProfile% \. Vscode \ extensions удалить каталог .msjsdiag.debugger-for-chrome-4.4.1
  • Старт VS Code
  • отключить автоматическое обновление расширений из меню EXTENSIONS в VS Code
  • скачать предыдущую версию можно здесь: https://msjsdiag.gallery.vsassets.io/_apis/public/gallery/publisher/msjsdiag/extension/debugger-for-chrome/4.3.0/assetbyname/Microsoft.VisualStudio.Services.VSIXPackage
  • переименуйте файл, чтобы иметь расширение .vsix
  • выберите «установить из VSIX» в меню «Расширения» в VS Code и выберите файл, который вы только что переименовали
Добро пожаловать на сайт PullRequest, где вы можете задавать вопросы и получать ответы от других членов сообщества.
...