demo_ref_globals2.py:
x = globals() print(x["__file__"])
➜ begtut>python demo_globals2.py
demo_ref_globals2.py