diff --git a/apps/djangocms_blog_customizations/feeds.py b/apps/djangocms_blog_customizations/feeds.py index a281c9567..da8c65bc8 100644 --- a/apps/djangocms_blog_customizations/feeds.py +++ b/apps/djangocms_blog_customizations/feeds.py @@ -5,15 +5,13 @@ from djangocms_blog.settings import get_setting from djangocms_blog.cms_appconfig import BlogConfig -import logging - -logger = logging.getLogger(f"portal.{__name__}") - +# XXX: This file is loaded, but it does NOT override the feed +# XXX: Logging via logger fails anywhere; via print fails inside any method class LatestEntriesFeed(DjangoCMSBlogLatestEntriesFeed): feed_type = Rss201rev2Feed feed_items_number = get_setting("FEED_LATEST_ITEMS") - link = "/blog/" + print(f"CUSTOM FEED | FEED_LATEST_ITEMS: {feed_items_number}") def __call__(self, request, *args, **kwargs): namespace = get_setting("AUTO_NAMESPACE") @@ -22,11 +20,13 @@ def __call__(self, request, *args, **kwargs): self.namespace = get_setting("AUTO_NAMESPACE") self.config = BlogConfig.objects.get(namespace=namespace) - logger.debug(f"CUSTOM FEED | NAMESPACE: {self.namespace}, CONFIG: {self.config}") + print(f"CUSTOM FEED | NAMESPACE: {self.namespace}, CONFIG: {self.config}") return super().__call__(request, *args, **kwargs) def items(self): items = super().items() - logging.debug(f"CUSTOM FEED | FEED ITEMS: {items}") + + print(f"CUSTOM FEED | FEED ITEMS: {items}") + return items diff --git a/apps/djangocms_blog_customizations/urls.py b/apps/djangocms_blog_customizations/urls.py index d00a52e22..b3692c024 100644 --- a/apps/djangocms_blog_customizations/urls.py +++ b/apps/djangocms_blog_customizations/urls.py @@ -8,7 +8,9 @@ urlpatterns = [ # To render styled Blog feed # XXX: Does NOT style the feed - # XXX: Does NOT render items within the feed + # XXX: Does NOT customize the feed + # FAQ: See errors at `/blog/feed/`, items at `/blog/feed/fb` + # FAQ: See Blog app feed root at `/news/feed/`, items at `/news/feed/fb` re_path(r'^feed/', LatestEntriesFeed(), name='feed'), # To render current blog, content only (no Core-CMS base.html)