[gpodder-devel] How to add a property to channels without beaking everything?

  • From: justin.forest at gmail.com (Justin Forest)
  • Date: Thu, 17 Jul 2008 14:35:50 +0400

Hi.  My latest patch to bug 57 [1] solves this problem partially by
adding the db.check_column() method.  It can add columns without
recreating table.  You would need to call this in db.__check_schema()
and add new fields to the list in db.load_channnels().

But if you can wait few days, maybe I will come up with a better
solution and update that patch.  I'll post here.

1. http://bugs.gpodder.org/show_bug.cgi?id=57#c11

On 7/17/08, jerome. chabod @ ifrance. com <jerome.chabod at ifrance.com> wrote:
> Hello,
>
> I need for solving bug 90 to add a "xsl_file" property to channels.
> Unfortunaltely, since whe use sqlite, it seems there is no mechanism to
> transparently add  a field. The only way I see is to force the user to
> remove its database in order to run the setup again (table creation), and
> doing so losing its channels configurations and episode's history. Not very
> elegant.
>
> Has somebody already plan to solve this problem or have indication on how it
> could be done?
> From my point of vue, I would maintain a hard coded list of fields, and have
> a function which would check at each start if the fields are already in the
> table and add it if not (alter table). But I'm afraid it could be a very
> expensive task. What do you think?
>
> J?r?me
>
> ________________________________
> My...o? ? You...quoi ? Face...qui ?... Vous ne savez plus comment ?tre
> vous-m?me ?
> Pour Cr?er, Partager et enfin Gagner ... D?couvrez iDOO en vid?o
> _______________________________________________
>  gpodder-devel mailing list
>  gpodder-devel at lists.berlios.de
>  https://lists.berlios.de/mailman/listinfo/gpodder-devel
>
>

Other related posts: