used-before-assignment / E0601#
Using variable %r before assignment
Emitted when a local variable is accessed before its assignment took place. Assignments in try blocks are assumed not to have occurred when evaluating associated except/finally blocks. Assignments in except blocks are assumed not to have occurred when evaluating statements outside the block, except when the associated try block contains a return statement.
print(hello) # [used-before-assignment] hello = "Hello World !"
hello = "Hello World !" print(hello)
Created by the variables checker.