def show_news(): print("This is a just a test!"); def register(): _App.register_script(_App.filename, "Test script", "Help of this test goes here", "Christian and Emacs", "Christian", "2005", "*", "/_About Python"); try: run_mode = _App.run_mode; if run_mode == 0: register(); elif run_mode != 0: show_news(); except AttributeError: print("AttributeError"); show_news();