Boolean type cannot be checked with isinstance()
x = True
print(x)
print( isinstance(x, bool) ) => False
y = bool(1)
print(y)
print( isinstance(y, bool) ) => False
The returned value when escaping prompt() cannot be checked as a boolean
expression
(maybe a javascript "null"):
z = prompt("Press escape key", "or push cancel button")
if z:
print("You should not have validated the dialog box")
=> ExecutionError: ExecutionError: ExecutionError: invalid 'in' operand obj
replacing "if z: with "if z == None:" ("is" not being currently supported)
=> ExecutionError: z is null
Original issue reported on code.google.com by pedro.ro...@gmail.com on 31 Dec 2012 at 11:35
Original issue reported on code.google.com by
pedro.ro...@gmail.com
on 31 Dec 2012 at 11:35