Global variable not changing between files in python Global variable not changing between files in python tkinter tkinter

Global variable not changing between files in python


The syntax from globals.py import * makes copies of the variables within globals.py into your local file. To access the variables themselves without making copies, import globals and use the variable directly: globals.filename. You no longer need the global keyword if you access the variable this way.