0

My Conda version is 4.11, and according to conda list my pandas version is 1.3.5. However, when I type python3 in the command line to bring up the shell and enter

import pandas as pd
pd.__version__

the version is 1.1.3.

The output of which -a python3 is

/home/a6623/anaconda3/bin/python3
/usr/bin/python3

as expected. Similarly, in the shell the output of sys.executable is

/home/a6623/anaconda3/bin/python3

as expected. If in the python shell I write pd.__file__ the output is

'/home/a6623/anaconda3/lib/python3.8/site-packages/pandas/__init__.py'

What is causing the version discrepancy?

Edit: upon further investigation, this discrepancy is also happening to other packages (e.g., networkx)

AndW
  • 726
  • 6
  • 31

1 Answers1

0

Solved! Package installed by Conda, Python cannot find it

Doing conda init then restarting the shell worked.

AndW
  • 726
  • 6
  • 31