Refactor: python: Use argparse in environment.py.
This is a big one, but it largely just moves code around.
Where possible, use argparse for as much as we can - help output,
enforcing types and choices, setting default values, etc. The basic
strategy is to call argparse to do all the processing, which sets a
value on its own namespace object. We then copy the most
straightforward values from the namespace object to the Environment
object, and then handle the trickier ones that set multiple values.