@@ -799,8 +799,8 @@ class ExcelFile:
799
799
800
800
Parameters
801
801
----------
802
- path_or_io : str, path object (pathlib.Path or py._path.local.LocalPath),
803
- a file-like object, xlrd workbook or openpypl workbook.
802
+ path_or_buffer : str, path object (pathlib.Path or py._path.local.LocalPath),
803
+ a file-like object, xlrd workbook or openpypl workbook.
804
804
If a string or path object, expected to be a path to a
805
805
.xls, .xlsx, .xlsb, .xlsm, .odf, .ods, or .odt file.
806
806
engine : str, default None
@@ -826,14 +826,14 @@ class ExcelFile:
826
826
"pyxlsb" : _PyxlsbReader ,
827
827
}
828
828
829
- def __init__ (self , path_or_io , engine = None ):
829
+ def __init__ (self , path_or_buffer , engine = None ):
830
830
if engine is None :
831
831
engine = "xlrd"
832
- if isinstance (path_or_io , IOBase ):
833
- if _is_ods_stream (path_or_io ):
832
+ if isinstance (path_or_buffer , IOBase ):
833
+ if _is_ods_stream (path_or_buffer ):
834
834
engine = "odf"
835
835
else :
836
- ext = os .path .splitext (str (path_or_io ))[- 1 ]
836
+ ext = os .path .splitext (str (path_or_buffer ))[- 1 ]
837
837
if ext == ".ods" :
838
838
engine = "odf"
839
839
if engine not in self ._engines :
@@ -842,9 +842,9 @@ def __init__(self, path_or_io, engine=None):
842
842
self .engine = engine
843
843
844
844
# Could be a str, ExcelFile, Book, etc.
845
- self .io = path_or_io
845
+ self .io = path_or_buffer
846
846
# Always a string
847
- self ._io = stringify_path (path_or_io )
847
+ self ._io = stringify_path (path_or_buffer )
848
848
849
849
self ._reader = self ._engines [engine ](self ._io )
850
850
0 commit comments