"from PySide6.QtGui import QAction" fixed the issue. Its not "from PySide6.QtWidgets import QAction".