Skip to main content

Expert Python Programming - Main package for Atomisator app

Project description

This package is part of the Expert Python Programming book written by Tarek Ziadé.

For more information, go to http://atomisator.ziade.org

The big picture

Atomisator is a feed framework. Its purpose it to provide an engine to build a feed by merging several sources of data.

The big picture

The big picture.

Building a feed is done by two processes :

  • 1, 2, 3 : Reading and filtering data

  • 4, 5, 6 : Building the feed

Reading and filtering data is done in three steps :

  1. read the data sources

  2. filter the collected data

  3. store them into a dedicated database

Building the feed is done in threesteps :

  1. read the database

  2. enhance the entries with dynamic data

  3. render the feed

The nice thing about readers, filters and enhancers is that they are plugins. This means you can write your own plugins and use Atomisator to build your own custom feed generator.

Quick Start

To use it, create a configuration file somewhere, using the -c option:

$ atomisator -c atomisator.cfg

A default configuration file will be generated, that looks like this:

[atomisator]

# put here the feeds you wish to parse
sources =
    rss     http://tarekziade.wordpress.com/atom
    rss     http://digg.com/rss2.xml

# put here the filters you want to use
filters =
    doublons

# put here the enhancers you want to use
enhancers =

# put here the database location
database = sqlite:///atomisator.db

# this is the file that will be generated
file = atomisator.xml

# infos that will appear in the generated feed.
title = meta
description = Automatic feed created by Atomisator.
link =  http://atomisator.ziade.org/example

You can then build your feed by using this configuration file with the -f option:

$ atomisator -f /path/to/atomisator.cfg
Reading source http://tarekziade.wordpress.com/atom
10 entries read.
Reading source http://digg.com/rss/index.xml
40 entries read.
50 total.
Writing feed in atomisator.xml
Feed ready.

You can specify the path as a free argument as well:

$ atomisator /path/to/atomisator.cfg

Atomisator will then generate an atomisator.xml file, after reading the sources.

You can also call separately the process that fills the database:

$ atomisator -r -f /path/to/atomisator.cfg

In this case the feed generation will not occur.

The -g option can be used to generate the xml file on its own:

$ atomisator -g -f /path/to/atomisator.cfg

This is useful to read sources and generate the feed within different process and different time basis.

For other useful options, run:

$ atomisator --help

Available plugins

XXX to be written

How to write a plugin

XXX to be written

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

atomisator.main-0.2.5.tar.gz (16.1 kB view details)

Uploaded Source

File details

Details for the file atomisator.main-0.2.5.tar.gz.

File metadata

File hashes

Hashes for atomisator.main-0.2.5.tar.gz
Algorithm Hash digest
SHA256 861fc78d15e6b67ef236d55c7de6480f78c128cebb42c0c7a181185d3d559767
MD5 bbfea121357634478a1c5d80b07b3617
BLAKE2b-256 95a53a49d05a0c0a19c99ec2a880a2497572d84cfa2adb04b60c22f0f0279034

See more details on using hashes here.

Supported by

AWS AWS Cloud computing and Security Sponsor Datadog Datadog Monitoring Fastly Fastly CDN Google Google Download Analytics Microsoft Microsoft PSF Sponsor Pingdom Pingdom Monitoring Sentry Sentry Error logging StatusPage StatusPage Status page