ashb commented on a change in pull request #18764:
URL: https://github.com/apache/airflow/pull/18764#discussion_r724025810



##########
File path: airflow/providers/amazon/aws/secrets/secrets_manager.py
##########
@@ -134,12 +138,17 @@ def client(self):
 
         return session.client(service_name="secretsmanager", **self.kwargs)
 
-    def _format_uri_with_extra(self, secret, conn_string):
+    @staticmethod
+    def _format_uri_with_extra(secret, conn_string):
         try:
             extra_dict = secret['extra']
         except KeyError:
             return conn_string
-        conn_string = f"{conn_string}?{urlencode(extra_dict)}"
+
+        extra = ast.literal_eval(
+            extra_dict  # this is needed because extra_dict is a string and we 
need a dict
+        )  # json.loads doesn't work because you can have unquoted booleans 
values

Review comment:
       No. Do not do this. Store it as JSON, unquoted booleans means it is not 
JSON. That is user error.




-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]


Reply via email to