Edgewall Software

Changes between Version 13 and Version 14 of TracTroubleshooting


Ignore:
Timestamp:
Jun 4, 2015, 6:37:40 AM (9 years ago)
Author:
Ryan J Ollos
Comment:

Add syntax highlighting.

Legend:

Unmodified
Added
Removed
Modified
  • TracTroubleshooting

    v13 v14  
    5454As this template engine is also written in Python, no specific data format is needed and a simple Python dictionary is used to feed the engine. It's very easy to inspect any part of this data by modifying the template and inserting `${pprint(...)}` statements, possibly in between `<pre>...</pre>` tags.
    5555Each modification to a template will be detected on the fly and you'll be able to see the result of the change immediately, provided you have the following setup in your TracIni:
    56 {{{
     56{{{#!ini
    5757[trac]
    5858auto_reload = yes
     
    6969Best is to start from a [TracSubversion checkout] of the pristine source code you're interested to debug or develop for.
    7070Then, you can run the standalone server by doing:
    71 {{{
     71{{{#!sh
    7272$ python scripts/tracd <options>
    7373}}}
    7474
    7575If you're using [source:trunk] (Trac [milestone:0.11]dev), since the SetupTools integrations, you'll have to run the standalone module directly:
    76 {{{
     76{{{#!sh
    7777$ python trac/web/standalone.py <options>
    7878}}}
    7979Note that the very first time in a fresh working copy, you'll have to at least initialize the ''Trac.egg-info'' folder, by doing:
    80 {{{
     80{{{#!sh
    8181$ python setup.py egg_info
    8282}}}
     
    9696
    9797Getting a backtrace for `tracd`:
    98 {{{
     98{{{#!sh
    9999$ gdb $(which python)
    100100(gdb) run /opt/trac-0.10/scripts/tracd -p 8080 /srv/trac/yourproject
     
    103103
    104104Getting a backtrace for Apache's `httpd` can be done in a similar way:
    105 {{{
     105{{{#!sh
    106106$ apachectl -k stop
    107107$ gdb $(which httpd)
     
    115115
    116116Here it might be interesting to just "attach" to an already running process:
    117 {{{
     117{{{#!sh
    118118$ ps -ef | grep httpd
    119119...