rssgen.py: generating valid feeds, refactorization