microsoft / vscode

Visual Studio Code
https://code.visualstudio.com
MIT License
164.4k stars 29.33k forks source link

macOS High Sierra: parts of the UI not rendering #35527

Closed EagleEYErus closed 7 years ago

EagleEYErus commented 7 years ago

Steps to Reproduce:

Interface crashes when I open a file in the project folder tree.

Reproduces without extensions: Not Tested

isidorn commented 7 years ago

Can you reproduce this with vscode insiders? https://code.visualstudio.com/Insiders/

EagleEYErus commented 7 years ago

@isidorn I will try, but I have not yet understood the sequence of steps to cause the crash. This happens randomly.

isidorn commented 7 years ago

@EagleEYErus without the sequence of steps there is not much we can do

chasegiunta commented 7 years ago

I’ve also recently had this begin happening after update to High Sierra, though it’s not specific to opening a file in tree. Completely random. It also appears to happen on other electron apps (Slack) though I haven’t been able to track down an electron issue for it anywhere yet.

chasegiunta commented 7 years ago

@EagleEYErus are you using an external monitor by chance? Is it high dpi?

bpasero commented 7 years ago

@chasegiunta does it make a difference if you run "code --disable-gpu" from the command line?

elijnzaad commented 7 years ago

I've experienced similar problems since upgrading to High Sierra. After a while the screen goes to a screen like EagleEYErus's. The after a minute or so it gradually comes back to life. I am using a MacBook Pro with a 4K external monitor, but I've experienced the same problems while not using the monitor.

Running "open Visual\ Studio\ Code.app --args --disable-gpu" from the terminal seems to have fixed the problem. It is running trouble-free for about an hour now.

bpasero commented 7 years ago

@EagleEYErus @elijnzaad does it run any better with our insiders build (NOT using --disable-gpu): http://code.visualstudio.com/Download#insiders

elijnzaad commented 7 years ago

No, it doesn't. Although I'm not sure I actually got the insiders build. I did follow your link, but the 'about' still shows 1.16.1.

bpasero commented 7 years ago

@elijnzaad sorry, bad link: https://code.visualstudio.com/insiders/

elijnzaad commented 7 years ago

I'm sorry, but the insiders build does have the same problem as the production build. It didn't take me more than 2 minutes. The screenshot shows the first thing I did, which is adjusting the user settings. screen shot 2017-10-04 at 11 38 56

EagleEYErus commented 7 years ago

@chasegiunta I did not use external monitors at the time the error was received. The first time a bug appeared on the MacOS High Sierra on the MacBook Air 13' 2013. For one development session, UI crashed several times. Then I ran into this problem yesterday on my iMac 27' late 2013. Then I tried to cause the error intentionally, but I did not find the sequence of steps, although it arose again when I changed the application window, but when I tried to repeat these actions nothing happened. I do not remember exactly, but the discord also seemed to give out this crash.

EagleEYErus commented 7 years ago

@elijnzaad UI after the crash was restored only once otherwise I had to restart the application

EagleEYErus commented 7 years ago

@elijnzaad Don't you have extensions for the insider version?

bpasero commented 7 years ago

@EagleEYErus @elijnzaad does this only reproduce on external monitor or also on the macbook pro screen? for external monitor, are they 4k/5k monitors?

elijnzaad commented 7 years ago

@EagleEYErus I actually hadn't done anything in the insider build. I downloaded it, started it and selected Preferences -> User settings from the menu. That's all, no extensions.

EagleEYErus commented 7 years ago

@bpasero I did not use external monitors during the crash, and, as I wrote above, the maximum resolution of all the devices I use is 2560x1440

The first time a bug appeared on the MacOS High Sierra on the MacBook Air 13' 2013. For one development session, UI crashed several times. Then I ran into this problem yesterday on my iMac 27' late 2013.

elijnzaad commented 7 years ago

@bpasero I did use a Philips BDM4037U 4K external monitor. I'm currently running VSCode Insider without the external monitor on a MacBook Pro (Retina, Mid 2012), Graphics NVIDIA GeForce GT 650M 1 GB Intel HD Graphics 4000 1536 MB. So far no problems yet.

bpasero commented 7 years ago

@EagleEYErus on what device are you seeing this currently?

@elijnzaad and this is without using --disable-gpu right?

EagleEYErus commented 7 years ago

@bpasero This screenshot I made on iMac 27-inch (2560 x 1440) late 2013 NVIDIA GeForce GTX 775M 2 ГБ

elijnzaad commented 7 years ago

@bpasero Yes, I'm running VSCode Insider without --disable-gpu and without the external monitor. No problems yet.

EagleEYErus commented 7 years ago

@bpasero Again, this error occurred a few hours ago on iMac, UI crashed when I changed tab and recovered in a few seconds.

bpasero commented 7 years ago

@EagleEYErus so this issue goes away after some second back to a functional UI, is that true?

EagleEYErus commented 7 years ago

@bpasero Last time, yes, but not always.

bpasero commented 7 years ago

Can someone capture a video when this happens and attach it? I would just like to understand how this surfaces.

EagleEYErus commented 7 years ago

@bpasero I found an excerpt from my stream (music plays loudly) https://clips.twitch.tv/AbnegateEndearingAnisePRChase

chasegiunta commented 7 years ago

If it's relevant for graphic driver issues, using MBPro Retina (Late 2013) NVIDIA GeForce GT 750M 2 GB / Intel Iris Pro 1536 MB. High Sierra - using a High DPI external display, but happens on both screens.

Does go away after some 2-30 seconds. Typically hovering the mouse over the UI helps after some time. Hiding / Minimizing the window and bringing back has no effect in resolving.

Just started today but will report back if I continue to see the issue when running with --disable-gpu.

bpasero commented 7 years ago

@EagleEYErus thanks. It looks awfully like https://github.com/Microsoft/vscode/issues/25934 which was fixed by a Chrome fix we took in where the GPU buffer was running out of memory.

Does it help to set "editor.disableTranslate3d": true ?

bpasero commented 7 years ago

@EagleEYErus @chasegiunta @elijnzaad here are a couple of things to try out to see if it improves the situation:

elijnzaad commented 7 years ago

@bpasero VSCode 1.16.1 with "editor.disableTranslate3d": true is running fine for an hour now (on the 40-inch Philips monitor).

elijnzaad commented 7 years ago

@bpasero Would you like us to try out the flags one-by-one to see which one does the trick?

bpasero commented 7 years ago

@elijnzaad yeah that would be nice. Thanks for doing this.

EagleEYErus commented 7 years ago

@bpasero Is it normal that the VSCode says that the property editor.disableTranslate3d was not found: "Unknown configuration setting"

bpasero commented 7 years ago

@EagleEYErus sorry for that, I forgot that we took out the setting disableTranslate3d some releases ago. Still, the test with the other command line flags would be interesting to do.

EagleEYErus commented 7 years ago

@bpasero Well, I'll try now with the flag code --disable-gpu-rasterization. After restarting the VSCode, does the app start without flags in normal mode?

bpasero commented 7 years ago

@EagleEYErus no unfortunately not, these flags need to be provided on startup. I fear there would not even be a simple way for us to make this configurable via settings...

elijnzaad commented 7 years ago

@bpasero code 1.16.1 --disable-gpu-rasterization runs fine so far. Will now try --disable-mac-overlays

EagleEYErus commented 7 years ago

@bpasero worked with the flag --disable-gpu-rasterization for about an hour and a half, everything worked well too. Will try code --force_integrated_gpu

elijnzaad commented 7 years ago

@bpasero code 1.16.1 -disable-mac-overlays does run without the major blackouts, but it is more sluggish and sometimes it makes the windows flicker. This is not my favourite option so far. Will now try --force_integrated_gpu (I presume you do mean underscore characters there)

EagleEYErus commented 7 years ago

@bpasero code --force_integrated_gpu start and immediately crash

elijnzaad commented 7 years ago

@bpasero Confirmed. --force_integrated_gpu causes problems on my system as well.

bpasero commented 7 years ago

@EagleEYErus @elijnzaad and whats the exact hardware this is on (e.g. which hardware model and year?). Maybe this issue only shows up for very specific GPUs.

I am now also on high sierra and so far have not seen any issues.

elijnzaad commented 7 years ago

@bpasero
Laptop: MacBook Pro (Retina, Mid 2012), Processor 2,6 GHz Intel Core i7, Memory 16Gb RAM 1600 Mhz DDR3, Graphics NVIDIA GeForcte GT 650M 1 GB, Intel HD Graphics 4000 1536Mb

Monitor: 2017 Philips BDM4037U 40-inch 4K, running at 30Ghz connected via HDMI

EagleEYErus commented 7 years ago

@bpasero iMac: iMac (27-inch, Late 2013), Processor 3,4 GHz Intel Core i5, Memory 16Gb 1600 MHz DDR3, Graphics NVIDIA GeForce GTX 775M 2Gb

MacBook: MacBook Air (13-inch, Mid 2013), Processor 1,3 GHz Intel Core i5, Memory 4Gb 1600 MHz DDR3, Graphics Intel HD Graphics 5000 1536Mb

On both computers, I encountered a crash

chasegiunta commented 7 years ago

Macbook Pro (Retina, Late 2013) Processor 2.3 GHz Intel Core i7 Memory 16 GB 1600 MHz DDR3 Graphics NVIDIA GeForce GT 750M 2 GB, Intel Iris Pro 1536 MB

Late to the replies here, but as the others have echoed, it doesn't occur with --disable-gpu . Will attempt the other flags today.

elijnzaad commented 7 years ago

@bpasero VSCode 1.16.1 seems to be running fine without any flags on my iMac 5K 27inch late 2014, 4Ghz Intel Core i7, 32Gb 1600MHz DDR3, AMD Radeon R9 M290X 2GB. So perhaps you are right in thinking that it is hardware related.

bpasero commented 7 years ago

At first I was thinking it could be the integrated GPU on the Macs, but given https://github.com/Microsoft/vscode/issues/35527#issuecomment-334469117 on an iMac where afaik there is only a single GPU, this theory seems wrong.

GPUs:

So far the only pattern I can see that it happens with Macs before 2014'ish.

EagleEYErus commented 7 years ago

@bpasero I don't know if this information will be useful, but I just got exactly the same problem in the discord

chasegiunta commented 7 years ago

I also experience it in Slack (another Electron app).

EagleEYErus commented 7 years ago

@chasegiunta can there be an error in the electron?