| 110 | == Troubleshooting == |
| 111 | |
| 112 | === Is setuptools properly installed? === |
| 113 | |
| 114 | Try this from the command line: |
| 115 | {{{ |
| 116 | $ python -c "import pkg_resources" |
| 117 | }}} |
| 118 | |
| 119 | If you get '''no output''', setuptools '''is''' installed. Otherwise, you'll need to install it before plugins will work in Trac. |
| 120 | |
| 121 | === Did you get the correct version of the Python egg? === |
| 122 | |
| 123 | Python eggs have the Python version encoded in their filename. For example, `MyPlugin-1.0-py2.4.egg` is an egg for Python 2.4, and will '''not''' be loaded if you're running a different Python version (such as 2.3 or 2.5). |
| 124 | |
| 125 | Also, verify that the egg file you downloaded is indeed a ZIP archive. If you downloaded it from a Trac site, chances are you downloaded the HTML preview page instead. |
| 126 | |
| 127 | === Is the plugin enabled? === |
| 128 | |
| 129 | If you install a plugin globally (i.e. ''not'' inside the `plugins` directory of the Trac project environment) you will have to explicitly enable it in [wiki:TracIni trac.ini]. Make sure that: |
| 130 | * you actually added the necessary line(s) to the `[components]` section |
| 131 | * the package/module names are correct |
| 132 | * if you're reference a module (as opposed to a class), you've appended the necessary “.*” |
| 133 | * the value is “enabled", not e.g. “enable” |
| 134 | |
| 135 | === Check the permissions on the egg file === |
| 136 | |
| 137 | Trac must of course be able to read the file. Yeah, you knew that ;-) |
| 138 | |
| 139 | === Check the log files === |
| 140 | |
| 141 | Enable [wiki:TracLogging logging] in Trac, set the log level to `DEBUG` and then watch the log file for messages about loading plugins. |
| 142 | |