title: cv2.imshow cause my jupyter notebook crash on MacOS
body: <p>when i use the <code>cv2.imshow()</code> in jupyter notebook , I can't close the pic window ,and if i force quit it ,that'll make the kernel crash.</p>
  
  <p>My configurations here:</p>
  
  <pre><code>MacOS : MoJava 10.14.3
  python 3.6.8
  openCV 3.4.2
  </code></pre>
  
  <p>Here s the code I use:</p>
  
  <pre><code>img=cv2.imread('24.jpg')
     cv2.imshow('imgae',img)
     cv2.waitKey(0)
     cv2.destroyAllWindows()
  </code></pre>
  
  <p>and then I've found a solution on overstackflow , that is:</p>
  
  <pre><code>import cv2
  
  
  img=cv2.imread('24.jpg')
  cv2.imshow('imgae',img)
  cv2.waitKey(0)
  cv2.destroyAllWindows()
  cv2.waitKey(1)
  </code></pre>
  
  <p>It will close the pic window immediately when u press any key, but still keep a process on my taskbar named <code>python</code>.
  And also, I can't close it unless I force quit it.</p>