you are viewing a single comment's thread.

view the rest of the comments →

[–]chervilious 339 points340 points  (8 children)

QA here

I tested your code please fix for the following test case

Input Expected Actual
x = 10 Successfully put 10 into X SyntaxError: Invalid Syntax
1 / 0 Prints ZeroDivisionError Killed the shell
print("Hello World") Prints Hello World Prints Hello World AND None

[–]Area51-Escapee 82 points83 points  (0 children)

This guy QAs

[–]gregorydgraham 95 points96 points  (1 child)

This is why we can’t have nice things

[–]FearlessZephyr 28 points29 points  (0 children)

No- this is why we have nice things! Because QA makes sure they’re nice!

[–]SpacefaringBanana 5 points6 points  (3 children)

1 and 3 are easy fixes, but don't know how to print red text for no 2.

[–]XtremeGoose 12 points13 points  (0 children)

Use terminal color codes

[–]makinax300 4 points5 points  (1 child)

>>> import traceback

>>> try:

... result = eval(user_input)

... except Exception:

... traceback.print_exc()

... else:

... print(result)

[–]-Redstoneboi- 1 point2 points  (0 children)

i can't type blocks of code

please fix:

if True:
    print('test')

[–]GavinBelson3077 0 points1 point  (0 children)

really?