I have written some code which uses pandas. It is working fine when i execute it from the command prompt. But when I make it as a .exe file and try to run it from command prompt, it getting this error as below:
Traceback (most recent call last):
File "Result_generator.py", line 2, in <module>
File "c:\users\akhil\appdata\local\temp\pip-build-rccgn1\pyinstaller\PyInstaller\loader\pyimod03_importers.py", line 396, in load_module
File "result_test.py", line 3, in <module>
File "c:\users\akhil\appdata\local\temp\pip-build-rccgn1\pyinstaller\PyInstaller\loader\pyimod03_importers.py", line 396, in load_module
File "site-packages\pandas\__init__.py", line 35, in <module>
ImportError: C extension: No module named tslib not built. If you want to import pandas from the source directory, you may need to run 'python setup.py build_ext --inplace --force' to build the C extensions first.
[12340] Failed to execute script Result_generator
I have installed tslib package also. But of no use. What is the wrong i am doing? Please help me with this. Thanks in Advance.
Doubt: In the error statement, it is saying to run "python setup.py..." command. But I didn't find any setup.py file in pandas directory. What is the solution for that?