def foo(): print("start") import foo foo.bar In: Out: foo