Python script to replace use of curl (#124)

This PR addresses issue #124
Is that left-over debug code? You want to pass in e.returncode into `sys.exit()`