Opened 17 years ago
Closed 16 years ago
#2469 closed defect (fixed)
announcerplugin does not work
Reported by: | Owned by: | Stephen Hansen | |
---|---|---|---|
Priority: | normal | Component: | AnnouncerPlugin |
Severity: | blocker | Keywords: | |
Cc: | David Fraser | Trac Release: | 0.11 |
Description
Error description
After the installation of the announcerplugin revision 3130 and the restart of the webserver the following error is displayed when trying to load trac in a browser:
Trac Error TracError: The Trac Environment needs to be upgraded. Run "trac-admin c:/trac_projekte\testtrac upgrade"
The corresponding warning in the log file goes like this:
Trac[env] WARNING: Component <announcerplugin.api.AnnouncementSystem object at 0x06BFEAF0> requires environment upgrade
OK -> Try to upgrade trac. The result can be viewed here:
c:\>trac-admin c:/trac_projekte\testtrac upgrade --no-backup Command failed: Parent module 'announcerplugin' not loaded
Any ideas?
Trac Server - system information
Operating system | Windows 2003 Server |
Trac | 0.11b1 |
Python | 2.5.1 (r251:54863, Apr 18 2007, 08:51:08) [MSC v.1310 32 bit (Intel)] |
setuptools | 0.6c7 |
MySQL | server: "5.0.45-community-nt", client: "5.0.27", thread-safe: 1 |
MySQLdb | 1.2.2 |
Genshi | 0.4.4 |
Pygments | 0.8.1 |
Subversion | 1.4.6 (r28521) |
jQuery | 1.2.1 |
trac.ini
[components]
announcerplugin.* = enabled
[announcer]
admit_domains =
always_notify_owner = true
always_notify_reporter = false
always_notify_updater = false
ignore_domains =
mime_encoding = base64
smtp_always_bcc =
smtp_always_cc =
smtp_default_domain =
smtp_enabled = false
smtp_from = trac@localhost
smtp_from_name =
smtp_password =
smtp_port = 25
smtp_replyto = trac@localhost
smtp_server = localhost
smtp_subject_prefix = default
smtp_user =
ticket_subject_template = $prefix #$ticket.id: $summary
use_public_cc = false
use_short_addr = false
use_tls = false
Attachments (1)
Change History (5)
comment:1 Changed 17 years ago by
comment:2 Changed 17 years ago by
Cc: | David Fraser added; anonymous removed |
---|
I got this as well. After some debugging it turns out that the from trac.db import DatabaseManager
in the _upgrade_db
method in announcer/api.py
triggers this. Replacing this with a normal import fixes it. I'll attach a brief patch (since we're already importing stuff from trac.db this shouldn't materially affect the operation)
Changed 17 years ago by
Attachment: | normal-databasemanager-import.patch added |
---|
Import trac.db.DatabaseManager normally, not only when upgrading
comment:3 Changed 17 years ago by
I've tried to install the egg without the patch and it failed, I was getting the error "Command failed: Parent Module 'Announcer Plugin' not loaded".
Next I tried David's patch and it worked like a charm!
Please consider adding this patch to the repository!
Kelvin
The first two are expected and normal; the last odd. Turn logging to DEBUG and see what it says?