builtins.AttributeError: module 'cv2' has no attribute 'legacy'

pip list or pip3 list please

also: how many pythons do you have? are there any virtual environments? what editor/IDE do you use?