在Ubuntu下使用Visual Studio Code显示错误 [英] Display error with Visual Studio Code under Ubuntu

查看:437
本文介绍了在Ubuntu下使用Visual Studio Code显示错误的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

几天来我在Visual Studio Code上遇到问题:无法启动它(实际上,窗口几乎是全黑的),这是从终端启动时的控制台输出:

I have a problem with Visual Studio Code for several days: it is impossible to launch it (in fact, the window is almost totally black), and here is the console output when I start it from a terminal:

bash: impossible de régler le groupe de processus du terminlal (-1): Ioctl() inapproprié pour un périphérique
bash: pas de contrôle de tâche dans ce shell
[3267:0609/135005:ERROR:buffer_manager.cc(361)] [.CommandBufferContext.Compositor-0xc0a90cb29a0]GL ERROR :GL_INVALID_ENUM : glBufferData: <- error from previous GL command
[3267:0609/135007:ERROR:texture_manager.cc(2278)] [.CommandBufferContext.RenderCompositor-0x29650b4d9c60]GL ERROR :GL_INVALID_ENUM : glTexImage2D: <- error from previous GL command
[3267:0609/135007:ERROR:gles2_cmd_decoder.cc(2109)] [.CommandBufferContext.RenderWorker-0x29650b4d96e0]GL ERROR :GL_INVALID_ENUM : GLES2DecoderImpl::DoBindTexImage2DCHROMIUM: <- error from previous GL command
[3267:0609/135007:ERROR:gles2_cmd_decoder.cc(2113)] [.CommandBufferContext.RenderWorker-0x29650b4d96e0]GL ERROR :GL_INVALID_OPERATION : ScopedTextureBinder::ctor: was unhandled
[3267:0609/135007:ERROR:gles2_cmd_decoder.cc(2109)] [.CommandBufferContext.RenderWorker-0x29650b4d96e0]GL ERROR :GL_INVALID_VALUE : ScopedTextureBinder::dtor: <- error from previous GL command
[3267:0609/135007:ERROR:gles2_cmd_decoder.cc(2109)] [.CommandBufferContext.RenderWorker-0x29650b4d96e0]GL ERROR :GL_INVALID_VALUE : ScopedTextureBinder::dtor: <- error from previous GL command
[3267:0609/135007:ERROR:gles2_cmd_decoder.cc(2109)] [.CommandBufferContext.RenderWorker-0x29650b4d96e0]GL ERROR :GL_INVALID_VALUE : ScopedTextureBinder::dtor: <- error from previous GL command
[3267:0609/135007:ERROR:gles2_cmd_decoder.cc(2109)] [.CommandBufferContext.RenderWorker-0x29650b4d96e0]GL ERROR :GL_INVALID_VALUE : ScopedTextureBinder::dtor: <- error from previous GL command

推荐答案

我遇到了同样的问题,安装virtualbox guest附加版本5.0.16确实解决了该问题.但是,如VS Code项目网站的常见问题解答部分所述,您也可以运行带--disable-gpu选项的VS Code,也可以解决该问题.从官方常见问题解答中:

I had the same problem and installing virtualbox guest additions version 5.0.16 really solved the problem. However, as noted in the FAQ section of VS Code project web site, you can also run the VS Code with --disable-gpu option, which also solves the problem. From the official FAQ :

VS Code主窗口为空?

VS Code main window is blank?

Visual Studio Code使用的Electron外壳在某些GPU(图形处理单元)硬件加速方面遇到问题.如果VS Code显示空白(空)主窗口,则可以在启动VS Code时尝试通过添加Electron --disable-gpu命令行开关来禁用GPU加速.

The Electron shell used by Visual Studio Code has trouble with some GPU (graphics processing unit) hardware acceleration. If VS Code is displaying a blank (empty) main window, you can try disabling GPU acceleration when launching VS Code by adding the Electron --disable-gpu command line switch.

这篇关于在Ubuntu下使用Visual Studio Code显示错误的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆