Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- # Other code goes here
- def run():
- pass
- # ...
- def main():
- global nailgun
- while True:
- try:
- nailgun = importlib.reload(nailgun)
- except ImportError as e:
- print("ImportError: {}".format(e))
- print("Hit enter to reload")
- input()
- continue
- try:
- nailgun.run()
- except Exception as e:
- print(repr(e))
- print("Caught exception in run: {}".format(e))
- print("Hit enter to reload/rerun")
- input()
- if __name__ == "__main__":
- main()
Add Comment
Please, Sign In to add comment