You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@allura.apache.org by Dave Brondsema <br...@users.sf.net> on 2014/01/24 17:02:16 UTC
[allura:tickets] #7085 error on activity rss feed for users
---
** [tickets:#7085] error on activity rss feed for users**
**Status:** open
**Labels:** activitystreams
**Created:** Fri Jan 24, 2014 04:02 PM UTC by Dave Brondsema
**Last Updated:** Fri Jan 24, 2014 04:02 PM UTC
**Owner:** nobody
~~~~
File '/var/local/allura/ForgeActivity/forgeactivity/main.py', line 120 in feed
'title': 'Activity for %s' % data['followee'].shortname,
AttributeError: 'User' object has no attribute 'shortname'
~~~~
---
Sent from sourceforge.net because allura-dev@incubator.apache.org is subscribed to https://sourceforge.net/p/allura/tickets/
To unsubscribe from further messages, a project admin can change settings at https://sourceforge.net/p/allura/admin/tickets/options. Or, if this is a mailing list, you can unsubscribe from the mailing list.
[allura:tickets] #7085 error on activity rss feed for users
Posted by Cory Johns <ma...@users.sf.net>.
- **status**: in-progress --> code-review
---
** [tickets:#7085] error on activity rss feed for users**
**Status:** code-review
**Labels:** activitystreams
**Created:** Fri Jan 24, 2014 04:02 PM UTC by Dave Brondsema
**Last Updated:** Fri Jan 24, 2014 08:19 PM UTC
**Owner:** Cory Johns
~~~~
File '/var/local/allura/ForgeActivity/forgeactivity/main.py', line 120 in feed
'title': 'Activity for %s' % data['followee'].shortname,
AttributeError: 'User' object has no attribute 'shortname'
~~~~
---
Sent from sourceforge.net because allura-dev@incubator.apache.org is subscribed to https://sourceforge.net/p/allura/tickets/
To unsubscribe from further messages, a project admin can change settings at https://sourceforge.net/p/allura/admin/tickets/options. Or, if this is a mailing list, you can unsubscribe from the mailing list.
[allura:tickets] #7085 error on activity rss feed for users
Posted by Cory Johns <ma...@users.sf.net>.
- **status**: open --> in-progress
- **assigned_to**: Cory Johns
---
** [tickets:#7085] error on activity rss feed for users**
**Status:** in-progress
**Labels:** activitystreams
**Created:** Fri Jan 24, 2014 04:02 PM UTC by Dave Brondsema
**Last Updated:** Fri Jan 24, 2014 07:15 PM UTC
**Owner:** Cory Johns
~~~~
File '/var/local/allura/ForgeActivity/forgeactivity/main.py', line 120 in feed
'title': 'Activity for %s' % data['followee'].shortname,
AttributeError: 'User' object has no attribute 'shortname'
~~~~
---
Sent from sourceforge.net because allura-dev@incubator.apache.org is subscribed to https://sourceforge.net/p/allura/tickets/
To unsubscribe from further messages, a project admin can change settings at https://sourceforge.net/p/allura/admin/tickets/options. Or, if this is a mailing list, you can unsubscribe from the mailing list.
[allura:tickets] #7085 error on activity rss feed for users
Posted by Dave Brondsema <br...@users.sf.net>.
- **status**: code-review --> closed
- **QA**: Dave Brondsema
---
** [tickets:#7085] error on activity rss feed for users**
**Status:** closed
**Labels:** activitystreams
**Created:** Fri Jan 24, 2014 04:02 PM UTC by Dave Brondsema
**Last Updated:** Thu Jan 30, 2014 10:17 PM UTC
**Owner:** Cory Johns
~~~~
File '/var/local/allura/ForgeActivity/forgeactivity/main.py', line 120 in feed
'title': 'Activity for %s' % data['followee'].shortname,
AttributeError: 'User' object has no attribute 'shortname'
~~~~
---
Sent from sourceforge.net because allura-dev@incubator.apache.org is subscribed to https://sourceforge.net/p/allura/tickets/
To unsubscribe from further messages, a project admin can change settings at https://sourceforge.net/p/allura/admin/tickets/options. Or, if this is a mailing list, you can unsubscribe from the mailing list.
[allura:tickets] #7085 error on activity rss feed for users
Posted by Dave Brondsema <br...@users.sf.net>.
- **Size**: --> 1
---
** [tickets:#7085] error on activity rss feed for users**
**Status:** open
**Labels:** activitystreams
**Created:** Fri Jan 24, 2014 04:02 PM UTC by Dave Brondsema
**Last Updated:** Fri Jan 24, 2014 04:02 PM UTC
**Owner:** nobody
~~~~
File '/var/local/allura/ForgeActivity/forgeactivity/main.py', line 120 in feed
'title': 'Activity for %s' % data['followee'].shortname,
AttributeError: 'User' object has no attribute 'shortname'
~~~~
---
Sent from sourceforge.net because allura-dev@incubator.apache.org is subscribed to https://sourceforge.net/p/allura/tickets/
To unsubscribe from further messages, a project admin can change settings at https://sourceforge.net/p/allura/admin/tickets/options. Or, if this is a mailing list, you can unsubscribe from the mailing list.
[allura:tickets] Re: #7085 error on activity rss feed for users
Posted by Cory Johns <ma...@users.sf.net>.
Agreed, that is much better. I rebased the branch and amended the change to the commit.
`allura:cj/7085`
---
** [tickets:#7085] error on activity rss feed for users**
**Status:** code-review
**Labels:** activitystreams
**Created:** Fri Jan 24, 2014 04:02 PM UTC by Dave Brondsema
**Last Updated:** Thu Jan 30, 2014 10:17 PM UTC
**Owner:** Cory Johns
~~~~
File '/var/local/allura/ForgeActivity/forgeactivity/main.py', line 120 in feed
'title': 'Activity for %s' % data['followee'].shortname,
AttributeError: 'User' object has no attribute 'shortname'
~~~~
---
Sent from sourceforge.net because allura-dev@incubator.apache.org is subscribed to https://sourceforge.net/p/allura/tickets/
To unsubscribe from further messages, a project admin can change settings at https://sourceforge.net/p/allura/admin/tickets/options. Or, if this is a mailing list, you can unsubscribe from the mailing list.
[allura:tickets] #7085 error on activity rss feed for users
Posted by Dave Brondsema <br...@users.sf.net>.
Looks good, but the attribute checking is ugly. How about this:
~~~~
diff --git Allura/allura/model/project.py Allura/allura/model/project.py
index f971293..eaec993 100644
--- Allura/allura/model/project.py
+++ Allura/allura/model/project.py
@@ -228,7 +228,7 @@ class __mongometa__:
@property
def activity_name(self):
- return self.shortname
+ return self.name
@property
def permissions(self):
diff --git ForgeActivity/forgeactivity/main.py ForgeActivity/forgeactivity/main.py
index 752d279..8ec3a78 100644
--- ForgeActivity/forgeactivity/main.py
+++ ForgeActivity/forgeactivity/main.py
@@ -131,10 +131,7 @@ def feed(self, **kw):
data = self._get_activities_data(**kw)
response.headers['Content-Type'] = ''
response.content_type = 'application/xml'
- if hasattr(data['followee'], 'display_name'):
- followee = data['followee'].display_name
- else:
- followee = data['followee'].name
+ followee = data['followee'].activity_name
d = {
'title': 'Activity for %s' % followee,
'link': h.absurl(self.app.url),
~~~~
---
** [tickets:#7085] error on activity rss feed for users**
**Status:** code-review
**Labels:** activitystreams
**Created:** Fri Jan 24, 2014 04:02 PM UTC by Dave Brondsema
**Last Updated:** Fri Jan 24, 2014 09:18 PM UTC
**Owner:** Cory Johns
~~~~
File '/var/local/allura/ForgeActivity/forgeactivity/main.py', line 120 in feed
'title': 'Activity for %s' % data['followee'].shortname,
AttributeError: 'User' object has no attribute 'shortname'
~~~~
---
Sent from sourceforge.net because allura-dev@incubator.apache.org is subscribed to https://sourceforge.net/p/allura/tickets/
To unsubscribe from further messages, a project admin can change settings at https://sourceforge.net/p/allura/admin/tickets/options. Or, if this is a mailing list, you can unsubscribe from the mailing list.
[allura:tickets] #7085 error on activity rss feed for users
Posted by Cory Johns <ma...@users.sf.net>.
`allura:cj/7085`
---
** [tickets:#7085] error on activity rss feed for users**
**Status:** code-review
**Labels:** activitystreams
**Created:** Fri Jan 24, 2014 04:02 PM UTC by Dave Brondsema
**Last Updated:** Fri Jan 24, 2014 08:19 PM UTC
**Owner:** Cory Johns
~~~~
File '/var/local/allura/ForgeActivity/forgeactivity/main.py', line 120 in feed
'title': 'Activity for %s' % data['followee'].shortname,
AttributeError: 'User' object has no attribute 'shortname'
~~~~
---
Sent from sourceforge.net because allura-dev@incubator.apache.org is subscribed to https://sourceforge.net/p/allura/tickets/
To unsubscribe from further messages, a project admin can change settings at https://sourceforge.net/p/allura/admin/tickets/options. Or, if this is a mailing list, you can unsubscribe from the mailing list.