0
    elif "go online" in result["text"]:
        os.system("clear")
        stream.stop_stream()
        print("Sir: " + result["text"])
        speak("Switching to online mode")
        os.system("open /Users/************/PycharmProjects/K.I.T.T/K"
                  ".I.T.T._online.py")
        quit

Instead of opening a new tab inside Pycharm it just opens 3 windows outside with a different ide? what am i doing wrong?

TAC
  • 21
  • 3
  • it uses the default executable to open `.py` files, the easiest to change that would be to go to a python file, left click it, choose open with, tick that box, select PyCharm (if you're on windows), regardless of all that, what are you really even trying to do? – Matiiss Sep 22 '22 at 07:21
  • Thanks! With opening that second python file im switching to my online assistant or atleast thats the plan – TAC Sep 22 '22 at 07:40

1 Answers1

1

The .py being inside a PycharmProjects folder doesn't mean that it will open in PyCharm. You can either go into your default program settings and set .py files to always open in PyCharm, or you could open the file from terminal by setting the location of PyCharm as a path variable and calling:

pycharm.sh ~/MyProject
M B
  • 2,700
  • 2
  • 15
  • 20