IOError
EntilZha opened this issue · 5 comments
I tried running your package via the readme instructions on github.com/EntilZha/ScalaFunctional, but got this error (python 2.7.10):
$ python -m blackwidow.web functional --exclude *test*
Traceback (most recent call last):
File "/usr/local/Cellar/python/2.7.10_2/Frameworks/Python.framework/Versions/2.7/lib/python2.7/runpy.py", line 162, in _run_module_as_main
"__main__", fname, loader, pkg_name)
File "/usr/local/Cellar/python/2.7.10_2/Frameworks/Python.framework/Versions/2.7/lib/python2.7/runpy.py", line 72, in _run_code
exec code in run_globals
File "/usr/local/lib/python2.7/site-packages/blackwidow/web.py", line 112, in <module>
web.visualize()
File "/usr/local/lib/python2.7/site-packages/blackwidow/web.py", line 64, in visualize
with open(json_file, 'w') as fd:
IOError: [Errno 2] No such file or directory: '/usr/local/lib/python2.7/site-packages/blackwidow/viz/static/graph.json'
On python3, I get a different error, which makes me think that this is a python 2 package?
$ python3 -m blackwidow.web functional --exclude *test*
Traceback (most recent call last):
File "/usr/local/Cellar/python3/3.5.0/Frameworks/Python.framework/Versions/3.5/lib/python3.5/runpy.py", line 170, in _run_module_as_main
"__main__", mod_spec)
File "/usr/local/Cellar/python3/3.5.0/Frameworks/Python.framework/Versions/3.5/lib/python3.5/runpy.py", line 85, in _run_code
exec(code, run_globals)
File "/usr/local/lib/python3.5/site-packages/blackwidow/web.py", line 12, in <module>
from blackwidow.viz.server import serve
File "/usr/local/lib/python3.5/site-packages/blackwidow/viz/server.py", line 6, in <module>
import SimpleHTTPServer, BaseHTTPServer
ImportError: No module named 'SimpleHTTPServer'
Ah, thanks for letting me know. I'll bet that the static folder doesn't get included when installing via pip. Would you mind trying to install via a git clone and python setup.py install
to see if that fixes the issue?
And yes, this is currently a python2.7 repo because of old bad habits. I'll either document that or fix it with a sprinkling of the six
library.
I tried using it both ways, via pip and setup.py install
, same thing
I can try setup.py develop
and see if it does anything
Running it via setup.py develop
seemed to fix the issue. I deleted something in easy-install.pth
before running that, although I think that was an artifact of setup.py install
so I think that setup.py install
is still broken
Thanks again for the ticket, I believe I've resolved things now (took me a few failed pushes to PyPI, though). Let me know if you're still running into issues and I'll patch things up again, but for now I'm closing this issue.