-
Notifications
You must be signed in to change notification settings - Fork 1.1k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Unexpected empty space is added to credentials profile name #2650
Comments
PR: #2651 |
Hello @forkercat , Thank you very much for your submission and contribution. Best regards, Yasmine |
^Cut a ticket to AWS CLI to fix the read issue. |
Checked that the changes are released in |
Hello @forkercat , Thank you very much for your collaboration. This issue has indeed been fixed in v1.11.162 of the SDK. I am therefore closing this submission. Let me know if you have any further inquiries regarding the AWS CPP SDK. Best regards, Yasmine |
|
Describe the bug
An empty space is added to a credentials profile name when I used
AWSConfigFileProfileConfigLoader
to load and save all credentials profiles to~/.aws/credentials
. For example, the profile name line in the file should be[default]
, but it is[ default]
.This does not cause any issue in code when I used the loader to load the credentials file. However, the AWS CLI cannot recognize this format:
Expected Behavior
No empty space before the profile name after saving to
~/.aws/credentials
:Current Behavior
An empty space is added before the profile name after saving to
~/.aws/credentials
:Reproduction Steps
AWSConfigFileProfileConfigLoader
to load and save credentials configurations~/.aws/credentials
Possible Solution
Did some investigation. Looks like the issue is caused by this line in AWSConfigFileProfileConfigLoader.cpp#L567.
outputFile << LEFT_BRACKET << prefix << " " << profile.second.GetName() << RIGHT_BRACKET << std::endl;
It should be changed to:
m_useProfilePrefix
is on when we use the loader to load and save non-credentials profile (e.g.[profile default]
).Tested locally and it worked. Putting up a PR...
Additional Information/Context
No response
AWS CPP SDK version used
1.11.136
Compiler and Version used
Visual Studio 2022
Operating System and version
Windows 11
The text was updated successfully, but these errors were encountered: