[Bug] Error: [createInstance] CodeLensContribution depends on UNKNOWN service ICodeLensCache.
I maintainer di solito rispondono entro 1 giorno
@hediet ci sta già lavorando.
Dal 29/9/2026.
Valutazione
Questa issue non è ancora stata valutata.
Descrizione
Reproducible in vscode.dev or in VS Code Desktop?
- Not reproducible in vscode.dev or VS Code Desktop
Reproducible in the monaco editor playground?
- Not reproducible in the monaco editor playground
Monaco Editor Playground Link
I'm using 0.57.0 along with monaco-editor-webpack-plugin.
My monaco-editor-webpack-plugin config looks like this:
new MonacoWebpackPlugin({
languages: ['json', 'html', 'javascript'],
filename: getFileName('js', 'worker'),
features: [
'!caretOperations',
'!codeAction',
'!codelens', // BUG RELATED
'!colorPicker',
'!dnd',
'!gotoSymbol',
'!linkedEditing',
'!multicursor',
'!referenceSearch',
'!smartSelect',
'!snippet',
'!stickyScroll',
'!toggleHighContrast',
'!inlineCompletions',
'!inlineProgress',
]
})
I create Monaco editors with this config:
export const defaultEditorOptions = {
minimap: { enabled: false },
scrollBeyondLastLine: false,
lineNumbers: 'off',
renderLineHighlight: 'none',
selectOnLineNumbers: true,
automaticLayout: true,
theme: 'defaultTheme',
scrollbar: { alwaysConsumeMouseWheel: false },
renderValidationDecorations: 'on',
codeLens: false, // BUG RELATED
};
When I instantiate an editor, it does render on my page but sometimes without styling the text. Furthermore, there are console errors like this. I was previously on 0.52.0 and didn't have this problem. I ran into it while testing the upgrade to 0.57.0.
errors.js:15 Uncaught Error: [createInstance] CodeLensContribution depends on UNKNOWN service ICodeLensCache.
Error: [createInstance] CodeLensContribution depends on UNKNOWN service ICodeLensCache.
at InstantiationService._throwIfStrict (instantiationService.js:333:1)
at InstantiationService._createInstance (instantiationService.js:114:1)
at InstantiationService.createInstance (instantiationService.js:102:1)
at CodeEditorContributions._instantiateById (codeEditorContributions.js:120:1)
at CodeEditorContributions._instantiateSome (codeEditorContributions.js:98:1)
at eval (codeEditorContributions.js:46:1)
at InstantiationService._throwIfStrict (instantiationService.js:333:1)
at InstantiationService._createInstance (instantiationService.js:114:1)
at InstantiationService.createInstance (instantiationService.js:102:1)
at CodeEditorContributions._instantiateById (codeEditorContributions.js:120:1)
at CodeEditorContributions._instantiateSome (codeEditorContributions.js:98:1)
at eval (codeEditorContributions.js:46:1)
at eval (errors.js:15:1)
I would expect since I have codeLens disabled in webpack and codeLens disabled on the editor options, that nothing would try to instantiate codeLens! Debugging in my browser, I see "css.editor.codeLens" is the ID trying to create it, which also makes no sense since I never tell Monaco to use CSS:
Monaco Editor Playground Code
Reproduction Steps
No response
Actual (Problematic) Behavior
No response
Expected Behavior
No response
Additional Context
No response
- Lingua principale
- JavaScript
- Stelle
- 47k
- Fork
- 4.2k
- Merge medio
- 3g 13h
- PR unite (30g)
- 13
Preparare l'ambiente
Avvia il container di sviluppo del progetto nel browser, con il tuo account GitHub.
- Nessun Dockerfile né file Docker Compose
- Nessun modello di pull request
- Leggi la guida per i contributori
Come iniziare
- Leggi tutta la issue e poi la guida ai contributi del progetto.
- Commenta sulla issue per dire che te ne occupi tu — evita che due persone facciano lo stesso lavoro.
- Fai un fork del repository e lavora su un branch.
- Apri una pull request che faccia riferimento al numero della issue.
Altre issue di microsoft/monaco-editor
-
Difficoltà 1/5 1-3 ore Idoneità per principianti 65/100
microsoft/monaco-editor#5626 ·
I maintainer di solito rispondono entro 1 giorno
-
[Bug] package.json `"typings"` points to a file which does not exist in the npm packageForse già presa @whoalin1 l’ha presa 2 giorni fa. Aperta
Difficoltà 2/5 1-3 ore Idoneità per principianti 78/100
microsoft/monaco-editor#5615 ·
I maintainer di solito rispondono entro 1 giorno
-
[Bug] C# scientific-notation literals without a decimal point are split into identifiersForse già presa @Janani-bn l’ha presa 15 giorni fa. Aperta
Difficoltà 2/5 1-3 ore Idoneità per principianti 84/100
microsoft/monaco-editor#5583 ·
I maintainer di solito rispondono entro 1 giorno
-
[Bug] Rust scientific-notation literals without an exponent sign are split into identifiersForse già presa @Janani-bn l’ha presa 14 giorni fa. Aperta
Difficoltà 2/5 1-3 ore Idoneità per principianti 82/100
microsoft/monaco-editor#5582 ·
I maintainer di solito rispondono entro 1 giorno
-
[Bug] Go numeric literals with underscore separators are split into identifiersForse di nuovo libera @aaronanish-t l’ha presa 25 giorni fa e non c’è nessuna pull request aperta. Aperta
Difficoltà 2/5 1-3 ore Idoneità per principianti 83/100
microsoft/monaco-editor#5577 · 1 commento ·
I maintainer di solito rispondono entro 1 giorno
Tutte le issue di microsoft/monaco-editor
Issue simili
-
Difficoltà 2/5 1-3 ore Idoneità per principianti 72/100
-
[Docs] CONTRIBUTING.md links to retired GitHub Learning Lab and Try Git sitesForse già presa @adityamukesh l’ha presa oggi. Aperta
Difficoltà 1/5 Meno di un'ora Idoneità per principianti 85/100
-
enhancement good first issue
Difficoltà 2/5 1-3 ore Idoneità per principianti 88/100
reillywalter/win-dev-doctor#92 ·
I maintainer di solito rispondono entro 1 giorno
-
[Feature] 新增「查看完整听歌设备记录」接口Aperta
Difficoltà 2/5 1-3 ore Idoneità per principianti 76/100
-
Difficoltà 2/5 1-3 ore Idoneità per principianti 78/100