From 7763327a63ca8de91a2ca5e201c70101a52a4c5f Mon Sep 17 00:00:00 2001 From: Jarrod Johnson Date: Tue, 16 Mar 2021 16:23:27 -0400 Subject: [PATCH] Skip confluent import on exec In main context, we don't need sshutil, and python path is not cooperative, so just skip it. --- confluent_server/confluent/runansible.py | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/confluent_server/confluent/runansible.py b/confluent_server/confluent/runansible.py index 86e41555..e234d9ee 100644 --- a/confluent_server/confluent/runansible.py +++ b/confluent_server/confluent/runansible.py @@ -16,7 +16,10 @@ # See the License for the specific language governing permissions and # limitations under the License. -import confluent.sshutil as sshutil +try: + import confluent.sshutil as sshutil +except ImportError: + pass import eventlet.green.subprocess as subprocess import msgpack import os