Try running the following code.
#!/usr/bin/env python
"""Simple script to run Idle from a venv in PyCharm."""
try:
# Import for Python pre 3.6
from idlelib.PyShell import main
except ModuleNotFoundError:
# Import for Python version 3.6 and later
from idlelib.pyshell import main
if __name__ == '__main__':
main()