This is a pre-production deployment of Warehouse, however changes made here WILL affect the production instance of PyPI.
Latest Version Dependencies status unknown Test status unknown Test coverage unknown
Project Description

So the average-joe RSS is binary ie either you subscribe to a feed or you don’t. This approach results in a ridiculous amount of junk in our inbox. What if we could subscribe define the feed that we would like to subscribe to? Thanks to the stellar django syndication framework and django filters, I was able to hack together a fix.

If you have a Book model like so:

class Book(models.Model):
    name = models.CharField(max_length=256)
    pages = models.IntegerField()

def __unicode__(self):

A django_filter FilterSet like so:

class BookFilterSet(django_filters.FilterSet):
    pages = django_filters.NumberFilter(lookup_type='lt')
    class Meta:
        model = Book
        fields = ['pages']

A FilteredFeed class like so:

class BookFilteredFeed(BaseFilteredFeed):
    model = Book
    filter_set = BookFilterSet
    title = "BookFeed"
    link = "http://localhost:8000"
    description = "Get alerts for new books - less than given number of pages!"

    def item_link(self, item):
        return reverse('book_detail', args=[])

Hook up the necessary urls like so:

urlpatterns = patterns('',
    url(r'^books/feed$', BookFilteredFeed.as_view(), name='book_feed'),

And finally, if we have the following 3 books in our DB:

  1. Introduction to Python (100 pages)
  2. Introduction to C (300 pages)
  3. Javascript - The good parts (300 pages)

Hitting http://localhost:8000/books/feed will give you an RSS feed includes:

  • Introduction to Python
  • Introduction to C
  • Javascript - The good parts

And hitting http://localhost:8000/books/feed?pages=200 will give you an RSS feed that just includes:

  • Introduction to Python

You users will forever remain grateful for sparing them the deluge that follows a binary subscription. You will be hailed the king of syndication, worshipped as a rock star and live happily ever after. The best part is that it takes a minute to get started:

pip install django_filtered_feed

Followed ofcourse by including filtered_feed in your INSTALLED_APPS.



0.1.0 (2014-08-18)

  • First release on PyPI.
Release History

Release History


This version

History Node

TODO: Figure out how to actually get changelog content.

Changelog content for this version goes here.

Donec et mollis dolor. Praesent et diam eget libero egestas mattis sit amet vitae augue. Nam tincidunt congue enim, ut porta lorem lacinia consectetur. Donec ut libero sed arcu vehicula ultricies a non tortor. Lorem ipsum dolor sit amet, consectetur adipiscing elit.

Show More

Download Files

Download Files

TODO: Brief introduction on what you do with files - including link to relevant help section.

File Name & Checksum SHA256 Checksum Help Version File Type Upload Date
django_filtered_feed-0.1.0.tar.gz (14.2 kB) Copy SHA256 Checksum SHA256 Source Aug 19, 2014

Supported By

WebFaction WebFaction Technical Writing Elastic Elastic Search Pingdom Pingdom Monitoring Dyn Dyn DNS HPE HPE Development Sentry Sentry Error Logging CloudAMQP CloudAMQP RabbitMQ Heroku Heroku PaaS Kabu Creative Kabu Creative UX & Design Fastly Fastly CDN DigiCert DigiCert EV Certificate Rackspace Rackspace Cloud Servers DreamHost DreamHost Log Hosting