Electron Version: 3.0.0-beta.1
Operating System (Platform and Version): macOS
Last known working Electron version: 2.0.3

When running test on macOS, a random crash may happen in the main process:

```
Thread 0 Crashed:: CrBrowserMain  Dispatch queue: com.apple.main-thread
  0   libcontent.dylib              	0x000000010f75c36b 0x10f463000 + 3117931
  1   libcontent.dylib              	0x000000010f75be82 0x10f463000 + 3116674
  2   libcontent.dylib              	0x000000011439caff 0x10f463000 + 83073791
  3   libcontent.dylib              	0x000000011439c559 0x10f463000 + 83072345
  4   com.apple.SkyLight            	0x00007fffc9c0d677 displayWillConfigNotifyProc + 440
  5   com.apple.SkyLight            	0x00007fffc9c0dc1d displayAcceleratorChangedProc + 422
  6   com.apple.SkyLight            	0x00007fffc9d1508d CGSPostLocalNotification + 612
  7   com.apple.SkyLight            	0x00007fffc9d14ae4 (anonymous namespace)::notify_datagram_handler(unsigned int, CGSDatagramType, void*, unsigned long, void*) + 82
  8   com.apple.SkyLight            	0x00007fffc9cc48c9 CGSDatagramReadStream::dispatch_next_main_queue_datagram() + 283
  9   com.apple.SkyLight            	0x00007fffc9cc4799 ___ZN21CGSDatagramReadStream35dispatch_main_queue_datagrams_asyncEP16dispatch_queue_sPS__block_invoke + 55
  10  libdispatch.dylib             	0x00007fffcd818524 _dispatch_call_block_and_release + 12
  11  libdispatch.dylib             	0x00007fffcd80f8fc _dispatch_client_callout + 8
  12  libdispatch.dylib             	0x00007fffcd81caac _dispatch_main_queue_callback_4CF + 925
```

It seems to be related to GPU rendering, and I believe it is responsible for our flaky macOS CI.
atom/browser/api/frame_subscriber.cc
#include "atom/browser/api/frame_subscriber.h"
#include "atom/common/native_mate_converters/gfx_converter.h"
#include "components/viz/common/frame_sinks/copy_output_request.h"
#include "components/viz/service/frame_sinks/frame_sink_manager_impl.h"
#include "components/viz/service/surfaces/surface_manager.h"
#include "content/browser/compositor/surface_utils.h"
#include "content/browser/renderer_host/render_widget_host_view_base.h"
#include "ui/gfx/geometry/rect_conversions.h"
#include "ui/gfx/skbitmap_operations.h"
#include "atom/common/node_includes.h"
namespace atom {
namespace api {
FrameSubscriber::FrameSubscriber(v8::Isolate* isolate,
                                 content::WebContents* web_contents,
                                 const FrameCaptureCallback& callback,
                                 bool only_dirty)
    : content::WebContentsObserver(web_contents),
      isolate_(isolate),
      callback_(callback),
      only_dirty_(only_dirty) {}
FrameSubscriber::~FrameSubscriber() = default;