'Why my terminal says indentation error when I do not have anything unindented?

im running my code on a virtual environment and i have installed all libraries.

Here is the error:

error

and this is my code:

import cv2
import dlib
import time
import threading
import math

carCascade = cv2.CascadeClassifier('myhaar.xml')
video = cv2.VideoCapture('cars.mp4')

while True:
        ret,image=video.read()
        cv2.imshow("frame",image)
        if((cv2.waitKey(1)) & 0xFF ==ord('q')):
                 break
video.release()
video.destroyAllWindows()            


Solution 1:[1]

There seems to be an extra space on the line with break (I count 9 spaces whereas the other indents are using 8 spaces)

Sources

This article follows the attribution requirements of Stack Overflow and is licensed under CC BY-SA 3.0.

Source: Stack Overflow

Solution Source
Solution 1 Danimal