ImportError: cannot import name _remove_dead_weakref

Chris Angelico rosuav at gmail.com
Thu May 3 13:15:03 EDT 2018


On Fri, May 4, 2018 at 1:53 AM, joseph pareti <joepareti54 at gmail.com> wrote:
> on an Ubuntu VM with :
>
>
>    1. Linux JP-Paid-UBUNTU-DSVM 4.13.0-1014-azure
>    2. Python 3.5.4 :: Anaconda custom (64-bit)
>
> $ manta manta_genSimData.py
> Loading script 'manta_genSimData.py'
> Traceback (most recent call last):
>
> skipping some details
>
> ...
> File "/anaconda/lib/python2.7/weakref.py", line 14, in <module>
>     from _weakref import (
> *ImportError: cannot import name _remove_dead_weakref*
> Script finished.

Somehow, the details you're skipping include jumping from a Python
3.5.4 into a Python 2.7's standard library. Check your Anaconda
settings and see if you have something bizarre going on with your
PYTHONPATH.

ChrisA



More information about the Python-list mailing list