Closed frmokoena closed 8 years ago
The FSEventsListener
stuff is just a warning (see #194).
To your second issue, can you let me know which version of Python you're using here?
Cheers,
I'm using Python 3.4.3
and I installed cactus in my virtualenv using pip
. I expected everything to work flawlessly after i created my site as is stated in #194.
This might be a Windows-only problem (it's not showing up in the tests).
I'll try to reproduce.
I'm not sure what am i doing wrong, but I tried to re-install cactus, and now i'm getting a totally new moster:
Here is all the steps i followed:
(envcactus) d:\cloud\Projects\PyProjects\projects>pip install --upgrade cactus
Collecting cactus
Downloading Cactus-3.3.0-py2.py3-none-any.whl (319kB)
100% |################################| 323kB 7.2kB/s
Collecting colorlog (from cactus)
Using cached colorlog-2.6.0-py2.py3-none-any.whl
Collecting keyring (from cactus)
Collecting argparse (from cactus)
Using cached argparse-1.4.0-py2.py3-none-any.whl
Collecting tornado>=3.2 (from cactus)
Collecting Django<1.7,>=1.6 (from cactus)
Using cached Django-1.6.11-py2.py3-none-any.whl
Collecting django-markwhat<2,>=1.4 (from cactus)
Collecting colorama (from cactus)
Collecting six>=1.9.0 (from cactus)
Using cached six-1.10.0-py2.py3-none-any.whl
Collecting boto>=2.4.1 (from cactus)
Using cached boto-2.38.0-py2.py3-none-any.whl
Collecting markdown2 (from cactus)
Installing collected packages: colorlog, keyring, argparse, tornado, Django, django-markwhat, colorama, six, boto, markdown2, cactus
Successfully installed Django-1.6.11 argparse-1.4.0 boto-2.38.0 cactus-3.3.0 colorama-0.3.3 colorlog-2.6.0 django-markwhat-1.4 keyring-5.6 markdown2-2.3.0 six-1.10.0 tornado-4.2.1
(envcactus) d:\cloud\Projects\PyProjects\projects>cactus create my-new-web-app
Traceback (most recent call last):
File "c:\python34\Lib\runpy.py", line 170, in _run_module_as_main
"main", mod_spec)
File "c:\python34\Lib\runpy.py", line 85, in _run_code
exec(code, run_globals)
File "C:\Users\rethabile\Envs\envcactus\Scripts\cactus.exemain.py", line 9, in
Re that second issue: see #199, it should be fixed now.
Yeah. It seems the problem has gone away, but i still can't get the server up.
I can create
a site, and build
it.
But when I run cactus serve
I still get the same old error. Does it perhaps have anything to do with Python version I'm using?
(envcactus) D:\cloud\Projects\PyProjects\projects\my-new-web-app>cactus serve
Running webserver at http://127.0.0.1:8000 for D:\cloud\Projects\PyProjects\projects\my-new-web-app.build
Type control-c to exit
Traceback (most recent call last):
File "c:\python34\Lib\runpy.py", line 170, in _run_module_as_main
"main", mod_spec)
File "c:\python34\Lib\runpy.py", line 85, in _run_code
exec(code, run_globals)
File "C:\Users\rethabile\Envs\envcactus\Scripts\cactus.exemain.py", line 9, in
As I mentioned earlier, this might have to do with the fact that you're using Windows since I'm not able to reproduce the issue elsewhere (on that Python version).
I know it's not fixed, and I haven't closed the issue.
I'll look into it when I can. I just don't have a Windows VM or computer available right this moment.
Cheers,
This problem happens with Linux too. It is caused by this line self.path = path.decode("utf-8")
at server.py.
I don't know if decode('utf-8')
is necessary in OSX, but on Linux, removing it and changing the line to self.path = path
solved the problem.
I installed
cactus
viapip
on my windows machine without any problems. I'm using Python 3.4.3.But when i try
cactus create my-awe-site
I get the following error message:Failed to load FSEventsListener
Traceback (most recent call last):
File "c:\users\username\envs\cactusenv\lib\site-packages\cactus\listener\__init__.py", line 11, in <module>
from cactus.listener.mac import FSEventsListener as Listener
File "c:\users\username\envs\cactusenv\lib\site-packages\cactus\listener\mac.py", line 12, in <module>
from fsevents import Observer, Stream
ImportError: No module named 'fsevents'
my-awe-site
folder get created, but when i runcactus serve
, I get the following:Failed to load FSEventsListener
Traceback (most recent call last):
File "c:\users\username\envs\cactusenv\lib\site-packages\cactus\listener\__init__.py", line 11, in <module>
from cactus.listener.mac import FSEventsListener as Listener
File "c:\users\username\envs\cactusenv\lib\site-packages\cactus\listener\mac.py", line 12, in <module>
from fsevents import Observer, Stream
ImportError: No module named 'fsevents'
Running webserver at http://127.0.0.1:8000 for D:\cloud\Projects\PyProjects\projects\my-awe-site\.build
Type control-c to exit
Traceback (most recent call last):
File "c:\python34\Lib\runpy.py", line 170, in _run_module_as_main
"__main__", mod_spec)
File "c:\python34\Lib\runpy.py", line 85, in _run_code
exec(code, run_globals)
File "C:\Users\username\Envs\cactusenv\Scripts\cactus.exe\__main__.py", line 9, in <module>
File "c:\users\username\envs\cactusenv\lib\site-packages\cactus\cli.py", line 143, in main
args.target(**{k: v for k, v in vars(args).items() if k != 'target'})
File "c:\users\username\envs\cactusenv\lib\site-packages\cactus\cli.py", line 66, in serve site.serve(port=port, browser=browser)
File "c:\users\username\envs\cactusenv\lib\site-packages\cactus\site.py", line 449, in serve self.server = WebServer(self.build_path, port=port)
File "c:\users\username\envs\cactusenv\lib\site-packages\cactus\server.py", line 85, in __init__ self.path = path.decode("utf-8")
AttributeError: 'str' object has no attribute 'decode'