There may be a conflict in the Python interpreter Path between the actual one and the one in the program. The problem could also be due to overlapping virtual environments.
You can search for the Python Path and replace it in PyCharm settings. If the issue persists, try deleting the virtual environment and reconfiguring it.