Hello all!

Could anyone tell me how I can get networkx to work with spyder? I'm new to 
python, macs, and spyder.
I've added /Library/Python/2.7/site-packages to the spyder 
pythonpathmanager. I'm using the 2.7 spyder install.
I would appreciate any help.

With this command:

import networkx as nx


I get this output:

runfile('/Users/salientintent/Desktop/temp.py', 
wdir='/Users/salientintent/Desktop')
Traceback (most recent call last):

  File "<ipython-input-1-bc0ed0fe94bb>", line 1, in <module>
    runfile('/Users/salientintent/Desktop/temp.py', 
wdir='/Users/salientintent/Desktop')

  File 
"/Applications/Spyder-Py2.app/Contents/Resources/lib/python2.7/spyderlib/widgets/externalshell/sitecustomize.py",
 
line 699, in runfile
    execfile(filename, namespace)

  File 
"/Applications/Spyder-Py2.app/Contents/Resources/lib/python2.7/spyderlib/widgets/externalshell/sitecustomize.py",
 
line 81, in execfile
    builtins.execfile(filename, *where)

  File "/Users/salientintent/Desktop/temp.py", line 13, in <module>
    import networkx as nx

  File "/Library/Python/2.7/site-packages/networkx/__init__.py", line 87, 
in <module>
    import networkx.readwrite

  File "/Library/Python/2.7/site-packages/networkx/readwrite/__init__.py", 
line 14, in <module>
    from networkx.readwrite.gml import *

  File "/Library/Python/2.7/site-packages/networkx/readwrite/gml.py", line 
46, in <module>
    from lib2to3.refactor import RefactoringTool

  File "lib2to3/refactor.pyc", line 27, in <module>

  File "lib2to3/fixer_util.pyc", line 9, in <module>

  File "lib2to3/pygram.pyc", line 32, in <module>

  File "lib2to3/pgen2/driver.pyc", line 121, in load_grammar

  File "lib2to3/pgen2/pgen.pyc", line 385, in generate_grammar

  File "lib2to3/pgen2/pgen.pyc", line 15, in __init__

IOError: [Errno 20] Not a directory: 
'/Applications/Spyder-Py2.app/Contents/Resources/lib/python2.7/site-packages.zip/lib2to3/Grammar.txt'

-- 
You received this message because you are subscribed to the Google Groups 
"spyder" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to [email protected].
To post to this group, send email to [email protected].
Visit this group at https://groups.google.com/group/spyderlib.
For more options, visit https://groups.google.com/d/optout.

Reply via email to