natanweinberger commented on a change in pull request #15425:
URL: https://github.com/apache/airflow/pull/15425#discussion_r641562826



##########
File path: airflow/cli/commands/connection_command.py
##########
@@ -238,39 +238,24 @@ def connections_delete(args):
 
 @cli_utils.action_logging
 def connections_import(args):
-    """Imports connections from a given file"""
+    """Imports connections from a file"""
     if os.path.exists(args.file):
         _import_helper(args.file)
     else:
         raise SystemExit("Missing connections file.")
 
 
 def _import_helper(file_path):
-    """Helps import connections from a file"""
-    connections_dict = load_connections_dict(file_path)
+    """Load connections from a file and save them to the DB. On collision, 
skip."""
+    connections_dict = _parse_secret_file(file_path)

Review comment:
       Nope, I introduced a bug at the last minute. The values of the dict were 
indeed Connection objects, but I was treating them as dictionaries (and my test 
didn't catch it). I can change this back to `load_connections_dict`, but I 
thought this was more straightforward.




-- 
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.

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


Reply via email to