Hi, I'm struggling with something that I am sure has a very simple method, but I am not getting it right. I am trying to pass a value from the urlconf to the feeds.py file. What I am trying to do is generate specific feeds for comments on a page.
I have been reading the example in the documentation:
http://docs.djangoproject.com/en/dev/ref/contrib/syndication/
of how to use the get_object() method, but I cannot seem to pass the right values.
Here is what I have been trying. In the url.py file:
('^post/(?P<sl>.*)/comment_feed/$', CommentFeed()),
And in the feeds.py file:
class CommentFeed(Feed):
def get_object(self, request, sl):
return get_object_or_404(Post, ????)
And I keep getting a ValueError saying:
invalid literal for int() with base 10: 'Test-1'
What is the right way to pass the object to the feeds CommnetFeed class?