Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

error on notebook 'DiGraph' object has no attribute 'node' #153

Open
enaeini opened this issue Jan 6, 2020 · 3 comments
Open

error on notebook 'DiGraph' object has no attribute 'node' #153

enaeini opened this issue Jan 6, 2020 · 3 comments

Comments

@enaeini
Copy link

enaeini commented Jan 6, 2020

I get this error. Any thoughts please to help?

WARNING: Couldn't open 'parser.out'. [Errno 20] Not a directory: '/usr/local/lib/python3.6/dist-packages/smop-0.41b0-py3.6.egg/smop/parser.out'
WARNING: Token 'CLASSDEF' defined, but not used
WARNING: Token 'END_UNEXPECTED' defined, but not used
WARNING: There are 2 unused tokens
Generating LALR tables
WARNING: Couldn't create 'parsetab'. [Errno 20] Not a directory: '/usr/local/lib/python3.6/dist-packages/smop-0.41b0-py3.6.egg/smop/parsetab.py'
str
Traceback (most recent call last):
File "/usr/local/lib/python3.6/dist-packages/smop-0.41b0-py3.6.egg/smop/main.py", line 66, in main
G = resolve.resolve(stmt_list)
File "/usr/local/lib/python3.6/dist-packages/smop-0.41b0-py3.6.egg/smop/resolve.py", line 54, in resolve
u = G.node[n]["ident"]
AttributeError: 'DiGraph' object has no attribute 'node'
Errors: 1

@oryba
Copy link

oryba commented Jan 7, 2020

An easy fix would be pip install networkx==1.11. Just faced the same issue and this workaround helped. Networkx v2 is somewhat non-backward compatible with the version used here

@DanHickstein
Copy link

DanHickstein commented Apr 16, 2020

G.node needs to be changed to G.nodes in two places in resolve.py. This is due to a change in networkx, as mentioned by oryba.
see dgorissen/pycel#80

@GBR-613
Copy link

GBR-613 commented Nov 21, 2021

Duplicating #165

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

4 participants