I'm writing a console application in python 3, and when I run my code in the Pycharm IDE, it runs just fine. If I run the code by opening it in python3, I get the exception "unexpected EOF while parsing (, line 1)" from the input statement.
I figure Pycharm is doing something for me to make this work, but I don't have any idea what it is. Here's the section of code where the error occurs. I'm calling this from a main method in another module that constructs some objects with commands in them to reference in the console. import appExceptions
def runConsole(commands, packages, commandLog):
while(True):
try:
print("DEBUG - getInput")
userInput = input("> ").split()
print("DEBUG - inputGotten")
commandLog.append(userInput)
if len(userInput) == 0:
continue
executeInput(commands, packages, userInput)
except appExceptions.UnknownCommandException as e:
print(e.msg)
except appExceptions.IncorrectArgumentsException as e:
print(e.msg)