Dan Arbogast schrieb: > I'm getting a "500 Internal Error" from a deployment of a simple TG app > using apache2/mod_wsgi (port 80) that seems to be directly correlated > with an attempt to instantiate a pyserial class. > > Interestingly, if the application is started using the ./start-myapp on > port 8080 (as sudo), the pyserial works just grand. This indicates to > me it's not a path problem, but probably a permission issue. > > Any guesses on what I may be missing, or how I can troubleshoot this? > The apache2 error logs are just telling me I have a 500 internal error, > and I haven't found any cherrypy error logs.
That's poor application design. A serial IO line is a singleton. It should be acquired once the app starts, and only released on it terminating. Or, if anything, based on certain user-actions. However, apache starts/stops processes at will, potentially interrupting serial communication. Additionally, there is no way to share the file-descriptors between processes (or at least no easy way..) So, don't do that. Either delegate your serial communication to an external process, governed e.g. by supervisord, communicating with xmlrpc. Or use (if you insist on using apache somehow) mod_proxy & keep your cherrypy-app running alongside. Diez --~--~---------~--~----~------------~-------~--~----~ You received this message because you are subscribed to the Google Groups "TurboGears" group. To post to this group, send email to [email protected] To unsubscribe from this group, send email to [EMAIL PROTECTED] For more options, visit this group at http://groups.google.com/group/turbogears?hl=en -~----------~----~----~----~------~----~------~--~---

