to fix this you need your pycharm to use python (version) 3.1 :

delete pycharm and python

on the pycharm IDE:

Press Ctrl+Alt+S to open the project Settings/Preferences and go to Project: <project name> | Python Interpreter. Click the Add Interpreter link next to the list of the available interpreters.

Select Add Local Interpreter from the list of the available interpreter types,

and choose 3.1