pd.read_excel hangs when I run from executable program
I figured out the issue. The xlrd library need to be installed from command prompt for python interpreter. I am sure this will help others who may face similar issue!
I am loading an .xlsx file into a dataframe. When I run the program from Pycharm or Jupyter notebook, it runs without any problems.
df = pd.read_excel(file_name)
But, when I create an executable file through Pyinstaller, the program hangs soon after I run pd.read_excel(file) command. I tried to read the file as .csv (after converting the excel to csv) as well and faced the same problem.
Following is the pyinstaller command I am using:
pyinstaller --onefile --noconsole --icon=icon.ico main.py
Let me know if anyone could help!