I had been experiencing this issue myself on and off for a while until I toggled off the 'Run Debugger in Server Mode' option for the PyCharm debugger in settings.