﻿id	summary	reporter	owner	description	type	status	component	version	severity	resolution	keywords	cc	stage	has_patch	needs_docs	needs_tests	needs_better_patch	easy	ui_ux
22078	views.Feed methods cannot be decorated	Germano Gabbianelli	Marcelo Galigniana	"If one applies a decorator on a method which is called by `__get_dynamic_attr` a `TypeError` like this occurs:

{{{
Exception Type: TypeError at /blog/feed/
Exception Value: item_link() takes exactly 2 arguments (1 given)
}}}

I think this is because `__get_dynamic_attr` tries to count the function's arguments, but decorators usally get defined with the `*args, **kwargs` syntax, so this trick does not work here.
{{{
            if code.co_argcount == 2:       # one argument is 'self'
                return attr(obj)
            else:
                return attr()
}}}

I think the best approach would be to remove one of the two methods. IMHO We should have either `attr(item)` or `attr()` not both, as ""there should be one, and preferably only one, obvious way to do it""."	Bug	closed	contrib.syndication	1.6	Normal	fixed			Ready for checkin	1	0	0	0	0	0
