# Cv2 imshow() and destroyAllWindows()

**URL:** <https://forum.opencv.org/t/cv2-imshow-and-destroyallwindows/14881>\
**Category:** Python\
**Tags:** python, programming\
**Created:** [October 16, 2023, 10:19am UTC](https://forum.opencv.org/t/cv2-imshow-and-destroyallwindows/14881 "2023-10-16T10:19:33Z")\
**Posts on this page:** 4\
**Page:** 1

<div class="post-metadata">

**Author:** ![suraj](https://avatars.discourse-cdn.com/v4/letter/s/ecccb3/32.png) [@suraj](https://forum.opencv.org/u/suraj)\
**Post date:** [October 16, 2023, 10:19am UTC](https://forum.opencv.org/t/cv2-imshow-and-destroyallwindows/14881/1 "2023-10-16T10:19:33Z")

</div>

I am getting these errors and i am trying but cant find the exact solution any help will be greatful.  
(cv2.imshow(‘Original’, color\_image)

AttributeError: module ‘cv2’ has no attribute ‘imshow’

During handling of the above exception, another exception occurred:

Traceback (most recent call last):

File “C:\Users\st190125.spyder-py3\temp.py”, line 29, in   
cv2.destroyAllWindows()

AttributeError: module ‘cv2’ has no attribute ‘destroyAllWindows’)

---

<div class="post-metadata">

**Author:** ![berak](https://avatars.discourse-cdn.com/v4/letter/b/85f322/32.png) [@berak](https://forum.opencv.org/u/berak)\
**Post date:** [October 16, 2023, 10:30am UTC](https://forum.opencv.org/t/cv2-imshow-and-destroyallwindows/14881/2 "2023-10-16T10:30:05Z")

</div>

> [@suraj](#):
>
> spyder

helo, i took the liberty to remove your entirely useless screenshot.

please post TEXT, not images of it, thank you…

---

<div class="post-metadata">

**Author:** ![suraj](https://avatars.discourse-cdn.com/v4/letter/s/ecccb3/32.png) [@suraj](https://forum.opencv.org/u/suraj)\
**Post date:** [October 16, 2023, 10:33am UTC](https://forum.opencv.org/t/cv2-imshow-and-destroyallwindows/14881/3 "2023-10-16T10:33:32Z")

</div>

Ok I will consider it from onwards. Thank you.

---

<div class="post-metadata">

**Author:** ![berak](https://avatars.discourse-cdn.com/v4/letter/b/85f322/32.png) [@berak](https://forum.opencv.org/u/berak)\
**Post date:** [October 16, 2023, 10:40am UTC](https://forum.opencv.org/t/cv2-imshow-and-destroyallwindows/14881/4 "2023-10-16T10:40:07Z")

</div>

try to put spyder away for a moment & run your script from a plain cmdline, like: `python my.py`

(again, most likely spyder is the problem, not really opencv)

please also check, if you can find anything else called cv2, which might get in the way
