Tilovell 908 curated packages uniqueness

Fixing issue #908 duplicated curated packages in feed which results from having duplicates in the database. The other part of this fix is we need to do a one-time cleanup of the database tables.

Also fixes #987 (curated feed perf)