How can I access global variable inside class in Python
By declaring it global inside the function that accesses it: The Python documentation says this, about the global statement: The global statement is a declaration which holds for the entire current code block.