We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent ddcaad8 commit 22e24bbCopy full SHA for 22e24bb
pandas/io/excel/_xlrd.py
@@ -28,7 +28,6 @@ def __init__(self, filepath_or_buffer):
28
raise ImportError(err_msg +
29
". Current version " + xlrd.__VERSION__)
30
31
- self._engine = xlrd
32
super().__init__(filepath_or_buffer)
33
34
@property
@@ -37,12 +36,12 @@ def _workbook_class(self):
37
36
return Book
38
39
def load_workbook(self, filepath_or_buffer):
40
-
+ from xlrd import open_workbook
41
if isinstance(filepath_or_buffer, (BytesIO, BufferedReader)):
42
data = filepath_or_buffer.read()
43
- return self._engine.open_workbook(file_contents=data)
+ return open_workbook(file_contents=data)
44
else:
45
- return self._engine.open_workbook(filepath_or_buffer)
+ return open_workbook(filepath_or_buffer)
46
47
48
def sheet_names(self):
0 commit comments