env: Change Environment to be a context manager.