I have a mymodyle.py module that contains a function called main:
def main(event):
    parser = Parse(event)
    parsed_event = parser.parse()
    return parsed_event
if __name__ == '__main__':
    event = "ABCD"
    main(event)
This function will be called from another module:
import mymodule
And the main function will be called via mymodule.main(event) - it will pass the event as an argument to main function of mymodule module.
If I run it from another module, do I need to add the dunder at the end because it won't be called anyway :
if __name__ == '__main__':
        event = "ABCD"
        main(event)
Another question: Do I need to add the else given that it will be called from another module?
if __name__ == '__main__':
            event = "ABCD"
            main(event)
else:
    //DO SOMETHING

if __name__part. That's the point of that construct: if the module is executed directly, do something. Otherwise… don't. Therefore you also don't need anelse, if you don't need it.