Modify

Opened 13 years ago

Closed 9 years ago

#8637 closed defect (fixed)

Context object changes breaks email2trac compatibility

Reported by: keith@… Owned by: Steffen Hoffmann
Priority: high Component: DiscussionPlugin
Severity: major Keywords: email2trac
Cc: Trac Release: 0.11

Description

email2trac trac:   File "/usr/local/bin/email2trac", line 1643, in parse
    self.discussion_topic_reply(m, subject[result.end('topic'):])

email2trac trac:   File "/usr/local/bin/email2trac", line 1350, in discussion_topic_reply
    topic = api.get_topic(context, self.id)

email2trac trac:   File "build/bdist.freebsd-7.2-STABLE-i386/egg/tracdiscussion/api.py", line 1544, in get_topic
    if subscriber not in context.users:

email2trac trac: AttributeError: 'Context' object has no attribute 'users'

I'm running trac 0.12.1 and the latest svn of discussion plugin and email2trac.

I think changeset 9770 might have something to do with this: http://trac-hacks.org/changeset/9770/discussionplugin/0.11/tracdiscussion/api.py

I opened a ticket w/ the email2trac devs as well, I don't know enough about trac hacking to figure out if the context object needs to be changed in email2trac or if something in discussion plugin needs to be changed. Please let me know if I can provide more information or test patches. Thanks

Attachments (0)

Change History (8)

comment:1 Changed 13 years ago by Radek Bartoň

Priority: normalhigh
Severity: normalmajor
Status: newassigned

This is caused by unfinished implementation of TracTags support. I'll will finish it as soon as my free time allows. Please meanwhile use older revision if you don't need tag support.

comment:2 in reply to:  description Changed 10 years ago by Steffen Hoffmann

Replying to keith@…:

I opened a ticket w/ the email2trac devs as well,

Any pointer? I cannot seem to find it, only two other tickets related to this plugin.

comment:3 Changed 10 years ago by keith@…

It looks like their bug tracking system is not at the old url. The ticket I filed with them was https://subtrac.sara.nl/oss/email2trac/ticket/240 (deleted?)

I tracked the problem to a change in the discussion plugin api: http://trac-hacks.org/changeset/9770/discussionplugin/0.11/tracdiscussion/api.py (I think)

That's about all I remember about this problem.

Last edited 10 years ago by Steffen Hoffmann (previous) (diff)

comment:4 Changed 10 years ago by Steffen Hoffmann

I see. I've updated the URL to point at the current bug tracker, but exactly that ticket is not there.

comment:5 Changed 10 years ago by Steffen Hoffmann

In 13930:

DiscussionPlugin: Prevent AttributeError when using API methods with pristine Trac context, refs #8637 and #11706.

This shall fix the issue reported for email2trac (yet untested) as well as
contribute to code robustness in general.

comment:6 in reply to:  5 Changed 10 years ago by Steffen Hoffmann

Replying to hasienda:

This shall fix the issue reported for email2trac (yet untested) ...

Test reports heartily welcome.

comment:7 Changed 10 years ago by Steffen Hoffmann

Owner: changed from Radek Bartoň to Steffen Hoffmann

comment:8 Changed 9 years ago by Ryan J Ollos

Resolution: fixed
Status: assignedclosed

Modify Ticket

Change Properties
Set your email in Preferences
Action
as closed The owner will remain Steffen Hoffmann.
The resolution will be deleted. Next status will be 'reopened'.

Add Comment


E-mail address and name can be saved in the Preferences.

 
Note: See TracTickets for help on using tickets.