Missed a sudo.
Install python-apt for apt_repository.