ImportError: cannot import name FileCache

811 views
Skip to first unread message

evoandres

unread,
Sep 10, 2015, 4:18:53 PM9/10/15
to Qiime Forum
Hi,

When i do because i was trying to install qiime 1.9 and qiime deploy. i write:

print_qiime_config.py -t

i get:

NOTE: In order to use the FileCache you must have
lockfile installed. You can install it via pip:
  pip install lockfile

Traceback (most recent call last):
  File "/usr/local/bin/print_qiime_config.py", line 40, in <module>
    raise ImportError("%s\n%s" % (e, core_dependency_missing_msg))
ImportError: cannot import name FileCache
See the QIIME Installation Guide: http://qiime.org/install/install.html


i have do pip install lockfile and also, pip install lockfile --upgrade but i still have the same error.

i show this diagnose:


[Downloads] pip show six                                     [ 3:10PM]
---
Name: six
Version: 1.9.0
Location: /usr/local/lib/python2.7/dist-packages
Requires:
[Downloads] pip show python-dateutil                         [ 3:10PM]
---

[Downloads] pip show python-dateutil                         [ 3:10PM]
---
Name: python-dateutil
Version: 1.5
Location: /usr/lib/python2.7/dist-packages
Requires:
__
[Downloads] echo $PYTHONPATH

_____



When i do

python -c "from tempfile import mkdtemp"

_________________________

python -c "from skbio.util import remove_files"  [ 3:11PM]

NOTE: In order to use the FileCache you must have
lockfile installed. You can install it via pip:
  pip install lockfile

Traceback (most recent call last):
  File "<string>", line 1, in <module>
  File "/usr/local/lib/python2.7/dist-packages/skbio/__init__.py", line 14, in <module>
    import skbio.io  # noqa
  File "/usr/local/lib/python2.7/dist-packages/skbio/io/__init__.py", line 202, in <module>
    from .registry import write, read, sniff, create_format, io_registry
  File "/usr/local/lib/python2.7/dist-packages/skbio/io/registry.py", line 184, in <module>
    from .util import _resolve_file, open_file, open_files, _d as _open_kwargs
  File "/usr/local/lib/python2.7/dist-packages/skbio/io/util.py", line 36, in <module>
    from skbio.io._iosources import get_io_sources, get_compression_handler
  File "/usr/local/lib/python2.7/dist-packages/skbio/io/_iosources.py", line 21, in <module>
    from cachecontrol.caches import FileCache
ImportError: cannot import name FileCache
____________________

python -c "from burrito.util import ApplicationNotFoundError, ApplicationError"

_____________________

[Downloads] pip show future                                  [ 3:13PM]
---
Name: future
Version: 0.15.1
Location: /usr/local/lib/python2.7/dist-packages
Requires:

_________________


All the problem is when i try the EXAMPLE data from http://nbviewer.ipython.org/github/biocore/qiime/blob/1.9.1/examples/ipynb/Fungal-ITS-analysis.ipynb

 qiime > core_diversity_analyses.py -i otus/otu_table_mc2_w_tax.biom -o cdout/ -m its-soils-tutorial/map.txt -e 353 --nonphylogenetic_diversity
Traceback (most recent call last):
  File "/usr/local/bin/core_diversity_analyses.py", line 202, in <module>
    main()
  File "/usr/local/bin/core_diversity_analyses.py", line 199, in main
    status_update_callback=status_update_callback)
  File "/usr/lib/python2.7/dist-packages/qiime/workflow/core_diversity_analyses.py", line 203, in run_core_diversity_analyses
    close_logger_on_success=False)
  File "/usr/lib/python2.7/dist-packages/qiime/workflow/util.py", line 116, in call_commands_serially
    raise WorkflowError, msg
qiime.workflow.util.WorkflowError:

*** ERROR RAISED DURING STEP: Generate BIOM table summary
Command run was:
 biom summarize-table -i otus/otu_table_mc2_w_tax.biom -o cdout//biom_table_summary.txt --suppress-md5
Command returned exit status: 1
Stdout:

Stderr
Traceback (most recent call last):
  File "/usr/local/bin/pyqi", line 27, in <module>
    from pyqi.util import get_version_string
ImportError: cannot import name get_version_string

_______-

I also update pyqi and biom, and scikit-bio. I also uninstall and reinstall qiime. Before that i was ahveing problem with emperor, because qiime was using an older version, and this is the main reason why i uninstall qiime

Thanks for your help.


Jamie Morton

unread,
Sep 11, 2015, 1:42:17 PM9/11/15
to Qiime Forum
Could you run the following command and upload the results here

pip freeze > pkgs.txt

evoandres

unread,
Sep 11, 2015, 3:08:58 PM9/11/15
to Qiime Forum
Babel==1.3
Brlapi==0.6.1
CacheControl==0.11.5
Cython==0.20.1post0
DendroPy==3.12.0
GnuPGInterface==0.3.2
Jinja2==2.7.2
MACS==1.4.1
Mako==0.9.1
MarkupSafe==0.18
MySQL-python==1.2.3
PAM==0.4.2
Pillow==2.3.0
PyChart==1.39
PyOpenGL==3.0.2
PyWebDAV==0.9.8
PyYAML==3.10
Pygments==1.6
Pyrex==0.9.8.5
Sphinx==1.2.2
Twisted-Core==13.2.0
Twisted-Names==13.2.0
Twisted-Web==13.2.0
Werkzeug==0.9.4
ZSI==2.1-a1
adium-theme-ubuntu==0.3.4
apt-xapian-index==0.45
argparse==1.2.1
beautifulsoup4==4.2.1
biom-format==1.2.0
burrito==0.9.1
burrito-fillings==0.1.1
bz2file==0.98
chardet==2.0.1
cogent==1.5.3
colorama==0.2.5
command-not-found==0.2.44
configglue==1.1.2
contextlib2==0.4.0
cvxopt==1.1.4
debtagshw==0.1
decorator==4.0.2
defer==1.0.6
dirspec==13.10
dnspython==1.11.1
docutils==0.11
duplicity==0.6.23
emperor==0.9.3
feedparser==5.1.3
funcsigs==0.4
future==0.15.1
gdata==2.0.18
gevent==1.1b4
gnuplot-py==1.8
green==2.0.4
greenlet==0.4.9
gufw==12.04.1
html5lib==0.999
httplib2==0.8
ipython==1.2.1
ipython-genutils==0.1.0
joblib==0.7.1
keyring==0.9.2
launchpadlib==1.10.2
lazr.restfulclient==0.13.3
lazr.uri==1.0.3
lockfile==0.10.2
louis==2.5.3
lxml==3.3.3
matplotlib==1.4.3
mock==1.0.1
mpi4py==1.3.1
natsort==4.0.3
ndg-httpsclient==0.4.0
nose==1.3.1
numexpr==2.2.2
numpy==1.9.2
numpydoc==0.4
oauth==1.0.1
oauthlib==0.6.1
onboard==0.97.1
oneconf==0.3.7
openpyxl==1.7.0
pandas==0.13.1
path.py==8.1
patsy==0.2.1
pbr==1.7.0
pdfshuffler==0.6.0
pexpect==3.1
pickleshare==0.5
piston-mini-client==0.7.5
protobuf==2.5.0
psutil==1.2.1
psycopg2==2.4.5
pyOpenSSL==0.13
pyPdf==1.13
pyasn1==0.1.8
pycrypto==2.6.1
pycryptopp==0.6.0.1206569328141510525648634803928199668821045408958
pycups==1.9.66
pycurl==7.19.3
pydot==1.0.28
pygobject==3.12.0
pyinotify==0.9.4
pynast==1.2.2
pyparsing==2.0.1
pyqi==0.2.0
pyserial==2.6
pysmbc==1.0.14.1
pysqlite==2.6.3
python-apt==0.9.3.5ubuntu1
python-dateutil==1.5
python-debian==0.1.21-nmu2ubuntu2
python-ldap==2.4.10
python-openid==2.2.5
python-termstyle==0.1.10
pytz==2012c
pyxdg==0.25
pyzmq==14.0.1
qcli==0.1.0
qiime==1.9.1
qiime-default-reference==0.1.3
reportlab==3.0
requests==2.2.1
roman==2.0.0
rpy==1.0.3
rpy2==2.4.2
scikit-bio==0.2.3
scipy==0.13.3
sessioninstaller==0.0.0
simplegeneric==0.8.1
simplejson==3.3.1
six==1.9.0
software-center-aptd-plugins==0.0.0
statsmodels==0.5.0
stevedore==1.8.0
suds==0.4.1
sympy==0.7.4.1
system-service==0.1.6
tables==3.1.1
tornado==3.1.1
traitlets==4.0.0
uTidylib==0.2
unittest2==0.5.1
unity-singlet==0.2.2
urllib3==1.7.1
usb-creator==0.2.23
vatnumber==1.1
virtkey==0.63.0
virtualenv==13.1.2
virtualenv-clone==0.2.6
virtualenvwrapper==4.7.0
vobject==0.8.1c
wadllib==1.3.2
weblogo==3.1
wheel==0.24.0
wsgiref==0.1.2
wxPython==2.8.12.1
wxPython-common==2.8.12.1
xdiagnose==2.5.3
xkit==0.0.0
xlrd==0.9.2
xlwt==0.7.5
zope.interface==4.0.5

Jamie Morton

unread,
Sep 11, 2015, 6:27:22 PM9/11/15
to Qiime Forum
This is a bit weird, FileCache is only required for scikit-bio 0.4, but your pip freeze says that scikit-bio 0.2.3 is installed.

Try the following command to reinstall scikit-bio 0.2.3 and uninstall any remnants of your scikit-bio 0.4 install

pip install -U scikit-bio==0.2.3

Then let me know if you have further problems with the qiime install.

Jamie

On Thursday, September 10, 2015 at 1:18:53 PM UTC-7, evoandres wrote:

evoandres

unread,
Sep 17, 2015, 5:10:09 PM9/17/15
to Qiime Forum
I tried the command  pip install -U scikit-bio==0.2.3. After i write in qiime: core_diversity_analyses.py -i otus/otu_table_mc2_w_tax.biom -o cdout/ -m its-soils-tutorial/map.txt -e 353 --nonphylogenetic_diversity and i get:

Jamie Morton

unread,
Sep 17, 2015, 6:55:36 PM9/17/15
to Qiime Forum
Making progress :)

Noticed that your pip freeze shows that biom-format was 1.2.  That version should be at least biom-format 2.0.
Should be able to run the following to upgrade that by 

pip install biom-format --upgrade


Let me know if that fixes that problem with biom


Best,

Jamie

evoandres

unread,
Sep 18, 2015, 3:49:26 PM9/18/15
to Qiime Forum
i still having the same error


*** ERROR RAISED DURING STEP: Generate BIOM table summary
Command run was:
 biom summarize-table -i otus/otu_table_mc2_w_tax.biom -o cdout//biom_table_summary.txt --suppress-md5
Command returned exit status: 1
Stdout:

Stderr
Traceback (most recent call last):
  File "/usr/local/bin/pyqi", line 27, in <module>
    from pyqi.util import get_version_string
ImportError: cannot import name get_version_string

i did pip freeze and i stil get biom 1.2.

I have upgrade a lot of libraries and i can not run the example

Jamie Morton

unread,
Sep 18, 2015, 4:56:47 PM9/18/15
to Qiime Forum
That's a little surprising.  Do you get the same problem when you run

pip install -U biom-format==2.0 

Jamie

evoandres

unread,
Sep 22, 2015, 11:24:15 AM9/22/15
to Qiime Forum
Yes. when i do pip install -U biom-format==2.0  i still have the same error. When i do pip freeze i have installed on my machine
biom-format==1.2.0.

Also, i realized that i have qiime 1.8. i have installed the latest version but it looks that i did not.
Reply all
Reply to author
Forward
0 new messages