> I would prefer to see
> 63 + credentials = load_jenkins_credentials(
> 64 + os.path.expanduser(self.credentialsfile),
> 65 + jenkins_name)
> 66 + if not credentials:
> 67 + logging.error(
> 68 + 'Credentials for "{}" not
> found.'.format(jenkins_name))
> 69 + return None
> kept inside of __call__ and store the parsed credentials as
> 'self.credentials'.
>
> This will cause a bad credentials file to fail the script before any stack
> processing is done. Should also make testing easier as you can use a pre-made
> credentials dictionary instead of patching load_jenkins_credentials.
I would need to modify load_jenkins_credentials to load _all_ jenkins credentials and not just the specified. The thing is that you also don't know the credentials name _before_ you process the stack.
> I would prefer to see credentials( expanduser( self.credential sfile), .format( jenkins_ name)) credentials.
> 63 + credentials = load_jenkins_
> 64 + os.path.
> 65 + jenkins_name)
> 66 + if not credentials:
> 67 + logging.error(
> 68 + 'Credentials for "{}" not
> found.'
> 69 + return None
> kept inside of __call__ and store the parsed credentials as
> 'self.credentials'.
>
> This will cause a bad credentials file to fail the script before any stack
> processing is done. Should also make testing easier as you can use a pre-made
> credentials dictionary instead of patching load_jenkins_
I would need to modify load_jenkins_ credentials to load _all_ jenkins credentials and not just the specified. The thing is that you also don't know the credentials name _before_ you process the stack.