[Bug] Monaco Playground w/ Local Dev Environment Does Not Work

Open
#4,383 0 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

Assessment

Difficulty
4/5
Estimated time
3-5 days
Newbie friendliness
15/100
Issue type
Bug
Clarity
Needs clarification
Activity status
Stale
Tech stack
docker, javascript

Research direction

Start with the debugging and developing language support section of CONTRIBUTING.md and reproduce the build using the reported Windows, WSL, and Docker setups. Then inspect the failure path in monaco-editor-core/dev/vs/loader.js and the playground loading behavior. Done means the local project builds and the playground opens instead of loading indefinitely.

Written by the indexing model from the issue text.

Description

Reproducible in vscode.dev or in VS Code Desktop?
  • Not reproducible in vscode.dev or VS Code Desktop
Reproducible in the monaco editor playground?
Monaco Editor Playground Link

No response

Monaco Editor Playground Code

No response

Reproduction Steps
  1. Follow the instructions at https://github.com/microsoft/monaco-editor/blob/main/CONTRIBUTING.md#debugging--developing-language-support
  2. Start project
  3. Get build errors

I have tried every possible combination of environments:

  1. Using the workspace file on Windows and WSL
  2. NOT using the workspace file on Windows and WSL
  3. Using the Docker container

No matter what I do I can't get it to work.

Actual (Problematic) Behavior

I get the following build error:

Could not read source map for file://///home/runner/work/monaco-editor/monaco-editor/website/node_modules/%40react-aria/ssr/dist/module.js: UNC host 'home' access is not allowed
Could not read source map for file://///home/runner/work/monaco-editor/monaco-editor/website/node_modules/messagepack/dist/messagepack.es.js: UNC host 'home' access is not allowed
Could not read source map for file://///home/runner/work/monaco-editor/monaco-editor/website/node_modules/mobx-react/dist/mobxreact.esm.js: UNC host 'home' access is not allowed
Loading "monaco-editor-core" failed
loader.js:249
Error: [object Event]
    at Object.ensureError (C:\Users\Jackson\monaco-editor\node_modules\monaco-editor-core\dev\vs\loader.js:234:18)
    at ModuleManager._createLoadError (C:\Users\Jackson\monaco-editor\node_modules\monaco-editor-core\dev\vs\loader.js:1461:26)
    at ModuleManager._onLoadError (C:\Users\Jackson\monaco-editor\node_modules\monaco-editor-core\dev\vs\loader.js:1472:23)
    at loadNextPath (C:\Users\Jackson\monaco-editor\node_modules\monaco-editor-core\dev\vs\loader.js:1615:11)
    at Object.errorback (C:\Users\Jackson\monaco-editor\node_modules\monaco-editor-core\dev\vs\loader.js:1635:7)
    at OnlyOnceScriptLoader.triggerErrorback (C:\Users\Jackson\monaco-editor\node_modules\monaco-editor-core\dev\vs\loader.js:601:24)
    at C:\Users\Jackson\monaco-editor\node_modules\monaco-editor-core\dev\vs\loader.js:588:107
    at HTMLScriptElement.errorEventListener (https://microsoft.github.io/monaco-editor/node_modules/monaco-editor-core/dev/vs/loader.js:621:5) {phase: 'loading', moduleId: 'monaco-editor-core', neededBy: Array(1), stack: 'Error: [object Event]
    at Object.ensureErr…es/monaco-editor-core/dev/vs/loader.js:621:5)', message: '[object Event]'}

loader.js:250
Here are the modules that depend on it:
loader.js:251
(1) ['vs/language/json/monaco.contribution']

The playground does not work and loads forever:
image

Expected Behavior

The playground should open as expected.

Additional Context

This problem is nearly identical to https://github.com/microsoft/vscode/issues/175009

Dominant language
JavaScript
Stars
46.8k
Forks
4.1k
Avg merge
17h 58m
Merged PRs (30d)
1

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

More from microsoft/monaco-editor

All issues in microsoft/monaco-editor

Similar issues

More JavaScript issues

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.