#0033 Subscriber property sticky
If you create a new Issue Tracker then when you start to add issues it picks up the last subscribed user from any other previous Issue Tracker and appears to automatically notify them.
This can be compromising if not embarrassing.
3 years and 8 months and 4 days old
This is with "Show Always notify status" checked.
If you go into the properties of the Issue itself then it shows as one of the subscribers to the issue.
When you display the Issue then its the [x] Notify the others (<email~AT~domain_._name>) string at the bottom of the issue if you have the Show Always Notify status checked.
Sorry but I can't reproduce this. I really want to because this is an embarrasing bug.
What I tried:
- go to localhost:8080/test-tracker/0012
- subscribe to that issue
- go to localhost:8080/manage
- create a new issue tracker "second-tracker"
- go to localhost:8080/second-tracker
- Add a new issue
It then does not set the subscriber property of any of the new issues.
A couple of questions:
- How do you log in to the issue trackers? location and type of your user folder?
- on the second issue tracker, do you enable the "Allow issue subscription" option in the Properties tab?
Thank you for doing this. I'm determined to solve this one. I'll try looking right at the code to try to figure out why might make it but that's not so easy.
It could well be how I login. I'm the admin for the whole zope and there's a folder called Projects which contains a bunch of IssueTracker folders and I have some simple index_html which puts them up for me and co-workers. Clients only have access to their own Issue Tracker, naturally, and they login using the user folder within their Issue Tracker.
We login either at the Projects Folder level or at the root level. My login is as the zope manager just for simplicity's sake which means I get permissions regardless of whatever is set on an individual folder or object.
I guess its possible that in trying to find a subscriber list that its searching the tree of objects based on the login.
To answer the second question, yes the Allow issue subscription is set to yes.
HTH, I want it fixed too for the same reasons. I'll try only logging in as a user at a particular Issue Tracker.
Hmmm, the picking up of the Notify happens even if I connect directly to the Issue Tracker URL and login as 'someone' other than the zope manager. This is regardless of the role of the user.
Additionally, the subscriber address was the last user to add a new Issue in their own IssueTracker on the whole of the zope server.
I see hope. I've managed to collect some data of how this can happen. It appears to somehow happen when the issue object gets created. It doesn't appear to have anything to do with the widget you see when you view an individual issue.
I'm going to blow up the debugging on this further and see if I can enclose it.
Simon, I've concluded that this is much more complicated than I had imagined. I've checked, read and re-read the code to figure out why instanciating the issue class can accidently map the subscribers parameter to anything. Here's the only code that creates issue instances:
issueinst = IssueTrackerIssue(id, title, status, type, urgency,
sections, fromname, email, url2issue,
confidential, hide_me, description,
display_format, issuedate,
acl_adder=acl_adder,
submission_type=submission_type)
And the __init__() function that gets this looked like this:
def __init__(self, id, title, status, issuetype, urgency, sections,
fromname, email, url2issue, confidential, hide_me,
description, display_format, issuedate='', subscribers=[],
acl_adder='', submission_type=''):
Somehow the subscribers parameter became /acl_users,peterbe in my debugging even though that can't be passed from the parenting function. My only explaination is that there is either a bug in Python or a bug deep down in the ZODB. It could be my fault but it just doesn't make any sense.
To avoid this ever happening again I'm now changing the __init__() function to not accept a subscribers parameter. It just immediately sets the subscribers to an empty list and nothing else. That means that the subscribers attribute can only be set using the addSubscriber function which is far from the creation of the issue.
Thank you for all your help on this issue Simon.