I'm currently trying to automate gimme-aws-creds in a python script.
I admire the idea of the gimme_aws_creds.ui.UserInterface class that helps a lot in automating user input.
I found that some places in the code was directly calling getpass.getpass() and not using the provided UserInterface. Replacing those calls with the proper UserInterface.input(hidden=True).
Related Issue
Fixes #428
Motivation and Context
Allowing developers subclassing gimme_aws_creds.ui.UserInterface for automation to provide inputs for password themselves.
How Has This Been Tested?
Ran pytest -vv tests with no errors
Tested it with a script mocking the user input via a subclass of UserInterface.
Screenshots (if appropriate):
Types of changes
[x] Bug fix (non-breaking change which fixes an issue)
[ ] New feature (non-breaking change which adds functionality)
[ ] Breaking change (fix or feature that would cause existing functionality to change)
Checklist:
[x] My code follows the code style of this project.
[ ] My change requires a change to the documentation.
Description
I'm currently trying to automate gimme-aws-creds in a python script. I admire the idea of the
gimme_aws_creds.ui.UserInterface
class that helps a lot in automating user input. I found that some places in the code was directly callinggetpass.getpass()
and not using the providedUserInterface
. Replacing those calls with the properUserInterface.input(hidden=True)
.Related Issue
Fixes #428
Motivation and Context
Allowing developers subclassing
gimme_aws_creds.ui.UserInterface
for automation to provide inputs for password themselves.How Has This Been Tested?
pytest -vv tests
with no errorsUserInterface
.Screenshots (if appropriate):
Types of changes
Checklist: