This is an automated email from the ASF dual-hosted git repository.

dstandish pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/airflow.git


The following commit(s) were added to refs/heads/master by this push:
     new 15e044c  Undeprecate private_key option in SFTPHook (#15348)
15e044c is described below

commit 15e044c7e412a85946a8831dd7eb68424d96c164
Author: Philippe Gagnon <[email protected]>
AuthorDate: Thu Apr 15 00:02:50 2021 -0400

    Undeprecate private_key option in SFTPHook (#15348)
    
    Remove the deprecation warning for the private_key option in SFTPHook. 
There are valid use cases for storing a private key in the connection object 
(e.g. storing them in connections backed by an external secrets backend).
---
 airflow/providers/sftp/hooks/sftp.py | 7 -------
 1 file changed, 7 deletions(-)

diff --git a/airflow/providers/sftp/hooks/sftp.py 
b/airflow/providers/sftp/hooks/sftp.py
index 7727b9d..86c5164 100644
--- a/airflow/providers/sftp/hooks/sftp.py
+++ b/airflow/providers/sftp/hooks/sftp.py
@@ -102,13 +102,6 @@ class SFTPHook(SSHHook):
                     self.ciphers = extra_options['ciphers']
 
                 if 'private_key' in extra_options:
-                    warnings.warn(
-                        'Extra option `private_key` is deprecated.'
-                        'Please use `key_file` instead.'
-                        'This option will be removed in Airflow 2.1',
-                        DeprecationWarning,
-                        stacklevel=2,
-                    )
                     self.key_file = extra_options.get('private_key')
 
     @tenacity.retry(

Reply via email to