In Django 1.2, the access to the feeds object was moved
to from django.contrib.feeds from django.contrib.syndication
and marked it as deprecated. Django 1.4 removed it entirely,
so this change makes the web app actually compatible with
both versions of Django.

Signed-off-by: Lucas Meneghel Rodrigues <l...@redhat.com>
---
 frontend/afe/feeds/feed.py |    6 +++---
 1 file changed, 3 insertions(+), 3 deletions(-)

diff --git a/frontend/afe/feeds/feed.py b/frontend/afe/feeds/feed.py
index 76314de..4e013b4 100644
--- a/frontend/afe/feeds/feed.py
+++ b/frontend/afe/feeds/feed.py
@@ -1,5 +1,5 @@
 import django.http
-from django.contrib.syndication import feeds
+from django.contrib.syndication import views
 from autotest.frontend.afe import models
 
 
@@ -28,7 +28,7 @@ def feed_view(request, url, feed_dict=None):
         # this line is changed from the Django library version to pass
         # in request instead of request.path
         feedgen = f(slug, request).get_feed(param)
-    except feeds.FeedDoesNotExist:
+    except views.FeedDoesNotExist:
         raise Http404, "Invalid feed parameters. Slug %r is valid, but other 
parameters, or lack thereof, are not." % slug
 
     response = HttpResponse(mimetype=feedgen.mime_type)
@@ -36,7 +36,7 @@ def feed_view(request, url, feed_dict=None):
     return response
 # end copied code
 
-class JobFeed(feeds.Feed):
+class JobFeed(views.Feed):
     """\
     Common feed functionality.
     """
-- 
1.7.10.2

_______________________________________________
Autotest mailing list
Autotest@test.kernel.org
http://test.kernel.org/cgi-bin/mailman/listinfo/autotest

Reply via email to