Skip to content

Commit 4f47391

Browse files
wbarnhabradenneal1
authored andcommitted
Update conn.py to catch OSError in case of failed import (dpkp#2407)
Closes dpkp#2399.
1 parent 18a373a commit 4f47391

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

kafka/conn.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -78,7 +78,7 @@ class SSLWantWriteError(Exception):
7878
try:
7979
import gssapi
8080
from gssapi.raw.misc import GSSError
81-
except ImportError:
81+
except (ImportError, OSError):
8282
#no gssapi available, will disable gssapi mechanism
8383
gssapi = None
8484
GSSError = None

0 commit comments

Comments
 (0)