* W. Trevor King <wk...@tremily.us> [130917 08:12]:
> I haven't used the conversion script myself, but if you're using
> slugify(url) to generate feed names in add(), I'd recommend using
> the same feed name (and not the feed index) for pausing:
> 
>   def pause(url):
>       return subprocess.call(['r2e', 'pause', slugify(url)])
>
> Then there is no need for enumerate(), and you don't run into errors
> if there are already feeds in the 3.x database when you run the
> conversion script (which would shift the index numbers).
> Feeds.index() allows you to index by name since ff650e8 (Cleanups to
> Feed and Feeds, 2012-10-04), which was well before 3.0.

Thanks a lot for the patch!

Feed names are indeed generated with slugify(url), which is the best
we can have while staying offline.

The index shifting that you describe can not happen as r2e-migrate
exits with an error if a 3.x database already exists.

These two points are of course open to ideas for improvement (and
patches).

I didn't know that it was possible to use the feed name for
run/delete/pause/unpause/reset, but it's indeed mentioned in the
manpage. I think it will make a simpler patch, so I'll apply the
simplified version and release this with version 3.6.

Cheers,

-- 
Etienne Millon


-- 
To UNSUBSCRIBE, email to debian-bugs-dist-requ...@lists.debian.org
with a subject of "unsubscribe". Trouble? Contact listmas...@lists.debian.org

Reply via email to