[Twisted-Python] Question about Twistd and PYTHONPATH
Hello Folks: This is my first time using twistd. I have daemonized a server by creating a TAC file. When I execute the server (first I ran it out of its development directory), twistd -y server.tac I get: no module named Reporter (Reporter is a class) when I run a non-daemonized version of the same server, I have no problem. I checked my PYTHONPATH. It seems to be properly set. I tried setting the path using sys.path. No go. Is there embarassingly simple that I am missing? Is there something I should be overriding? Cheers, Andrew ____________________________________________________________________________________ Never miss a thing. Make Yahoo your home page. http://www.yahoo.com/r/hs
I guess your Reporter class is in another module. I ran into the same situation a few days ago and finally made it work like this: import sys sys.path.append('.') from task import Task Matthew On Feb 10, 2008 4:46 AM, Andrew Francis <andrewfr_ice@yahoo.com> wrote:
Hello Folks:
This is my first time using twistd. I have daemonized a server by creating a TAC file. When I execute the server (first I ran it out of its development directory),
twistd -y server.tac
I get:
no module named Reporter (Reporter is a class)
when I run a non-daemonized version of the same server, I have no problem.
I checked my PYTHONPATH. It seems to be properly set. I tried setting the path using sys.path. No go.
Is there embarassingly simple that I am missing? Is there something I should be overriding?
Cheers, Andrew
____________________________________________________________________________________ Never miss a thing. Make Yahoo your home page. http://www.yahoo.com/r/hs
_______________________________________________ Twisted-Python mailing list Twisted-Python@twistedmatrix.com http://twistedmatrix.com/cgi-bin/mailman/listinfo/twisted-python
participants (2)
-
Andrew Francis
-
Matthew Zhang