I recently ran into an issue and wanted to reach out to see if I might be doing something wrong, or if this is, in fact, a bug. My default AWS profile has some S3 configuration options set, and that default profile is not being managed by Granted Registry, but the rest of my AWS config file is. When Granted Registry sync runs and replaces the managed section, it also reformats the default profile's S3 configuration and removes some whitespace, which makes the configuration invalid. I believe this is related to the S3 configuration syntax being non-standard.
Steps to reproduce - assuming you have a registry setup and it doesn't manage the default profile in ~/.aws/config.
aws configure set s3.max_concurrent_requests 100 --profile=default
aws configure set s3.max_queue_size 1000 --profile=default
granted registry sync
Afterwards, AWS CLI commands fail with an error message like this:
'str' object has no attribute 'get'
I believe this is because the AWS CLI is expecting the S3 configuration to deserialize into a Python dictionary, and without the indentation, it is deserializing into an empty string.
Context from slack message: