VSCode 실행시 Jupyter을 열려고 시도 하는데 다음과 같은 오류가 발생했다.
Could not initialize webview: Error: Could not register service worker: InvalidStateError: Failed to register a ServiceWorker: The document is in an invalid state..}
이 때 해결 방법은 아래와 같다.
# Linux
rm -rf ~/.config/Code/Cache
# macOS
rm -rf ~/Library/Application Support/Code/Cache
# Windows PowerShell
Get-ChildItem "$env:APPDATA\code" -Directory -Filter Cache -Recurse | Remove-Item -Force -Recurse
# Windows Command Prompt (cmd.exe)
rd /s /q "%APPDATA%\Code\Cache"
여기 코드 중에서 각자 OS에 맞는 코드를 작성하면 된다.
감사합니다