Changes between Version 4 and Version 5 of TracModPython


Ignore:
Timestamp:
Feb 22, 2022, 1:38:35 PM (3 years ago)
Author:
trac
Comment:

Legend:

Unmodified
Added
Removed
Modified
  • TracModPython

    v4 v5  
    5555  SetHandler mod_python
    5656  PythonInterpreter main_interpreter
    57   PythonHandler trac.web.modpython_frontend 
     57  PythonHandler trac.web.modpython_frontend
    5858  PythonOption TracEnv /var/trac/myproject
    5959  PythonOption TracUriRoot /projects/myproject
     
    8989PythonOption TracLocale en_GB.UTF8
    9090
    91 # See description above       
     91# See description above
    9292PythonOption TracUriRoot /projects/myproject
    9393}}}
     
    110110=== Setting the Python Egg Cache
    111111
    112 If the Egg Cache isn't writeable by your Web server, you'll either have to change the permissions, or point Python to a location where Apache can write. This can manifest itself as a `500 internal server error` and/or a complaint in the syslog. 
     112If the Egg Cache isn't writeable by your Web server, you'll either have to change the permissions, or point Python to a location where Apache can write. This can manifest itself as a `500 internal server error` and/or a complaint in the syslog.
    113113
    114114{{{#!apache
    115115<Location /projects/myproject>
    116116  ...
    117   PythonOption PYTHON_EGG_CACHE /tmp 
     117  PythonOption PYTHON_EGG_CACHE /tmp
    118118  ...
    119119</Location>
     
    140140  SetHandler mod_python
    141141  PythonInterpreter main_interpreter
    142   PythonHandler trac.web.modpython_frontend 
     142  PythonHandler trac.web.modpython_frontend
    143143  PythonOption TracEnvParentDir /var/trac
    144144  PythonOption TracUriRoot /projects
     
    147147
    148148When you request the `/projects` URL, you will get a listing of all subdirectories of the directory you set as `TracEnvParentDir` that look like Trac environment directories. Selecting any project in the list will bring you to the corresponding Trac environment.
     149
     150Directories residing in `TracEnvParentDir` that are not environment directories will display an error message on the [TracInterfaceCustomization#ProjectList project index page]. The directories can be excluded by listing them in a `.tracignore` file residing in `TracEnvParentDir`. Unix [https://docs.python.org/2/library/fnmatch.html shell-style wildcard patterns] can be used in the newline separated list of directories.
    149151
    150152If you don't want to have the subdirectory listing as your projects home page you can use a
     
    232234
    233235   #remove these if you don't want to force SSL
    234    RewriteEngine On 
     236   RewriteEngine On
    235237   RewriteCond %{HTTPS} off
    236238   RewriteRule (.*) https://%{HTTP_HOST}%{REQUEST_URI}
     
    277279SetHandler mod_python
    278280PythonInterpreter main_interpreter
    279 PythonHandler trac.web.modpython_frontend 
     281PythonHandler trac.web.modpython_frontend
    280282PythonOption TracEnv /system/path/to/this/directory
    281283PythonOption TracUriRoot /path/on/apache
     
    316318}}}
    317319
    318 See also [http://subversion.apache.org/faq.html#reposperms How do I set repository permissions correctly?]
     320See also [https://subversion.apache.org/faq.html#reposperms How do I set repository permissions correctly?]
    319321
    320322==== FreeBSD issues
     
    359361
    360362'''Note''': For the above configuration to have any effect it must be put after the configuration of your project root location, ie {{{<Location /myproject />}}}.
    361 
    362 **Note:** Do not enable python optimizations using the directive `PythonOptimize On`. When optimizations are enabled the page header/footer and documentation for macros and plugins will be hidden. An error will be raised in Trac 1.0.11 and later when optimizations are enabled.
    363363
    364364=== HTTPS issues
     
    376376=== Segmentation fault with php5-mhash or other php5 modules
    377377
    378 You may encounter segfaults (reported on Debian etch) if php5-mhash module is installed. Try to remove it to see if this solves the problem. See [http://bugs.debian.org/cgi-bin/bugreport.cgi?bug=411487 Debian bug report].
    379 
    380 Some people also have troubles when using PHP5 compiled with its own third party libraries instead of system libraries. Check [http://www.djangoproject.com/documentation/modpython/#if-you-get-a-segmentation-fault Django segmentation fault].
     378You may encounter segfaults (reported on Debian etch) if php5-mhash module is installed. Try to remove it to see if this solves the problem. See [https://bugs.debian.org/cgi-bin/bugreport.cgi?bug=411487 Debian bug report].
     379
     380Some people also have troubles when using PHP5 compiled with its own third party libraries instead of system libraries. Check [https://www.djangoproject.com/documentation/modpython/#if-you-get-a-segmentation-fault Django segmentation fault].
    381381
    382382----