Cannot import pandas, Anaconda3 python crashes without error message

1

I am trying to import pandas to do some statistical analyses, but am having issues importing the package. There aren't any error messages, so it's making it difficult to debug. I have tried uninstalling & reinstalling Anaconda3, rebooting multiple times, updating conda/anaconda/pandas via console, all to no effect. When I don't import pandas, everything runs fine.

This is my 'Tester.py', it's a super simplified version of what I'm trying to do, but it also fails in the exact same way:

import pandas

def main():
    print("It works.")

if __name__ == '__main__':
    main()

And the console output I get from PyCharm is as follows:

C:\Anaconda\python.exe C:/Users/IH/PycharmProjects/Test/tester.py

Process finished with exit code -1073741819 (0xC0000005)

When I run Tester.py through cmd prompt, a pop up informs me that python has crashed. So it doesn't seem to be limited to my IDE. It's not throwing any errors on the 'import pandas' line, so it can find the library. When I comment out 'import pandas', the "It works." line prints fine.

C:\Anaconda>conda info
Current conda install:

             platform : win-64
        conda version : 3.10.0
  conda-build version : 1.8.2
       python version : 3.4.1.final.0
     requests version : 2.6.0
     root environment : C:\Anaconda  (writable)
  default environment : C:\Anaconda
     envs directories : C:\Anaconda\envs
        package cache : C:\Anaconda\pkgs
         channel URLs : https://repo.continuum.io/pkgs/free/win-64/
                        https://repo.continuum.io/pkgs/free/noarch/
                        https://repo.continuum.io/pkgs/pro/win-64/
                        https://repo.continuum.io/pkgs/pro/noarch/
          config file : None
    is foreign system : False
python
python-3.x
pandas
python-import
asked on Stack Overflow Mar 30, 2015 by Guerre • edited Mar 30, 2015 by Guerre

1 Answer

0

I had the same issue with pyntcloud and matplotlib after several conda install and conda remove commands (for pcl and python-pcl). Reinstalling the offending package conda install matplotlib fixed it for me. Interestingly, it wasn't even installed anymore.

For you, that would likely mean that you should run

conda remove pandas
conda install -c anaconda pandas 
answered on Stack Overflow Nov 1, 2018 by lucidbrot

User contributions licensed under CC BY-SA 3.0