I am trying to call a function 'myfunction()' defined in another py file 'file2.py' in same directory using below code
from file2 import *
myfunction()
Unfortunately, its executing my function twice. The import statement is also executing the function. Any insights on how to avoid this?
file2callmyfunctionanywhere?from file2 import myfunction as myfunc