question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

graph_models error with pydot lastest version

See original GitHub issue

I’m working with python 2.7.11+ and latest version of pydot (1.2.2) and pyparsing (2.1.5). When I run:

django-admin graph_models -o models.png

I get:

Traceback (most recent call last): File "/home/ebujeque/.virtualenvs/gmp/bin/django-admin", line 11, in <module> sys.exit(execute_from_command_line()) File "/home/ebujeque/.virtualenvs/gmp/local/lib/python2.7/site-packages/django/core/management/__init__.py", line 353, in execute_from_command_line utility.execute() File "/home/ebujeque/.virtualenvs/gmp/local/lib/python2.7/site-packages/django/core/management/__init__.py", line 345, in execute self.fetch_command(subcommand).run_from_argv(self.argv) File "/home/ebujeque/.virtualenvs/gmp/local/lib/python2.7/site-packages/django/core/management/base.py", line 348, in run_from_argv self.execute(*args, **cmd_options) File "/home/ebujeque/.virtualenvs/gmp/local/lib/python2.7/site-packages/django/core/management/base.py", line 399, in execute output = self.handle(*args, **options) File "/home/ebujeque/.virtualenvs/gmp/local/lib/python2.7/site-packages/django_extensions/management/utils.py", line 58, in inner ret = func(self, *args, **kwargs) File "/home/ebujeque/.virtualenvs/gmp/local/lib/python2.7/site-packages/django_extensions/management/commands/graph_models.py", line 164, in handle self.render_output_pydot(dotdata, **options) File "/home/ebujeque/.virtualenvs/gmp/local/lib/python2.7/site-packages/django_extensions/management/commands/graph_models.py", line 221, in render_output_pydot graph.write(output_file, format=format) AttributeError: 'list' object has no attribute 'write'

I tried with pyparsing(1.5.7) and pydot(1.2.2), but it fails too. I solved it with:

  • pyparsing==1.5.7
  • pydot=1.1.0

But It can’t work with lastest version of both libraries.

Issue Analytics

  • State:closed
  • Created 7 years ago
  • Reactions:1
  • Comments:10 (6 by maintainers)

github_iconTop GitHub Comments

1reaction
trbscommented, Nov 24, 2016

sorry, i see this hasn’t made it into a release yet 😦

hope to have a new release out soon !

0reactions
trbscommented, May 9, 2017
Read more comments on GitHub >

github_iconTop Results From Across the Web

Django Model Graph (pydot) Error - python - Stack Overflow
I have recently started working on a big Django project with existing complicated model. I needed to visualize that model, ...
Read more >
Graph models — django-extensions 3.2.1 documentation
Creates a GraphViz dot file for the specified app names based on their models.py. You can pass multiple app names and they will...
Read more >
GraphViz not working when imported inside PydotPlus ...
In my case I am able to find graphviz executables manually in anaconda3\Library\bin\graphviz , but I still would get the GraphViz's Executables not...
Read more >
No module named 'pydotplus' | Data Science and ... - Kaggle
Hello, I want to visualize my decison tree models in Kaggle Notebook. My code is written in Python. But, i got error 'No...
Read more >
Generating Graph Visualizations with pydot and Graphviz
Hi, for my latest college assignment I had to find a way to visualize data that is interrelated. For instance, my application generated...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found