Classic template changes
Tom Ekberg <[email protected]>
| Newsgroups | gmane.comp.bug-tracking.roundup.user |
|---|---|
| Message-ID | <DM6PR08MB4778C0677100D0BABC02072CCAAF0@DM6PR08MB4778.namprd08.prod.outlook.com> |
I finally have the demo tracker working well with ansible. It's kind of a pain, but is now automated. I can make local changes to the demo tracker files, which get pushed to the remote host that runs roundup. I'm using a site_config.json to allow me to define test trackers. I need to do more work on creating a new tracker with ansible, which is my next step. I have made what I think are improvements to several of the classic templates. Mostly added config/TRACKER_NAME to pull in the tracker name so one knows where one is at. Not all of the templates do that. At our site we have 16 production trackers and 7 test trackers so these changes are useful here. What is the next step for me? I read the docs and it looks like for small changes I could send (to roundup-dev?) 'diff -u' runs for each file. I have made about 17 file changes. I came up with a spreadsheet that gives guidance on how to exercise each template change. Not sure what to do with that. [cid:599abafd-5968-419e-8428-a98bd95ea95c] ________________________________ From: John P. Rouillard <[email protected]> Sent: Wednesday, November 14, 2018 4:50 PM To: Tom Ekberg Cc: [email protected] Subject: Re: [Roundup-users] Apache WSGI woes In message <DM6PR08MB4778FEA089A9C31A4FA3C46ECAC30@DM6PR08MB4778.namprd08.prod.o utlook.com>, Tom Ekberg writes: > Occasionally, I get an HTTP 500 error (Internal Server Error). I've > tried restarting apache which doesn't help. I instrumented mod_wsgi to > add more detail to the logs in 29 places where errors are detected > thinking that might help isolate the problem. The log for this error is: > >[Wed Nov 14 21:24:52.014080 2018] [wsgi:error] [pid 19848] [remote 10.146.1= >22.53:52967] mod_wsgi (pid=3D19848): Exception occurred processing TWE1 WSG= >I script '/opt/roundup/trackers/demo/apache/demo_wsgi.py': mod_wsgi.c:Adapt= >er_run: PyErr_Occurred 1. >[Wed Nov 14 21:24:52.014311 2018] [wsgi:error] [pid 19848] [remote 10.146.1= >22.53:52967] RuntimeError: response has not been started > >The part I added says the file (mod_wsgi.c) and function (Adapter_run) wher= >e the error is detected. The '1' is there because there is a similar proble= >m in the same function. It is used to distinguish the two cases. TWE1 tells= > me which log message is generated. There are 2. The other 29 places call t= >he logging function in wsgi_logger.c > > >The mod_wsgi module is written in C. It loads and executes Python code usin= >g the Python C API. > > >I can display the demo tracker's home page, create an issue and modify >attributes on the issue. I can create and modify users. When I try to >add a Change Note on an issue with a nosy filled in, I get the >Internal Server Error. Doing an import on demo_wsgi generates no errors. >The demo_wsgi.py file specifically sets sys.path to the virtualenv >Python directory. It imports roundup successfully which is only >installed in the virtualenv. > >Having mod_wsgi generate a stack trace, and maybe even the error code would >be nice, but I don't know how to do that using the Python C API. > >When you encounter mod_wsgi errors like this, what do you do? I am speaking off the cuff here, but does: https://modwsgi.readthedocs.io/en/develop/user-guides/debugging-techniques.html Debugging Techniques — mod_wsgi 4.6.5 documentation<https://modwsgi.readthedocs.io/en/develop/user-guides/debugging-techniques.html> modwsgi.readthedocs.io For the case of the process group as recorded by the ‘mod_wsgi.process_group’ variable in the WSGI request environment, if the value is an empty string then the WSGI application is running in embedded mode. help any? Maybe wrap the application call in the demo_wsgi python script in try/except and capture everything decoding the exception and writing it to wsgi.errors? It also discusses error catching middleware that writes to wsgi.errors object. Also it discusses using gdb to debug/dump stack traces which seems to be what you are looking for. Good luck in your bug hunt. -- -- rouilj John Rouillard =========================================================================== My employers don't acknowledge my existence much less my opinions. _______________________________________________ Roundup-users mailing list [email protected] https://lists.sourceforge.net/lists/listinfo/roundup-users
Outlook-ujd12opi.jpg
(image/jpeg, 14.3 KB) - not displayed