https://bugs.gpodder.org/show_bug.cgi?id=1198

[email protected] changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
                 CC|                            |[email protected]

--- Comment #3 from [email protected] 2010-11-11 09:37:39 GMT ---
This is happening because upgrade_table calls recreate_table to fill in default
values on channels_save before upgrade_table adds the new columns.  So
recreate_table tries to "UPDATE channels_save SET feed_update_enabled = 1 where
feed_update_enabled IS NULL" , but the feed_update_enabled column exists only
on the new table (channels) and not on the old table (channels_save).

As a workaround you can add the column manually:

$ sqlite3 ~/.config/gpodder/database.sqlite
sqlite> select * from channels; -- Make sure it's empty first (no output).
sqlite> drop table channels; -- It was empty, right?
sqlite> alter table channels_save rename to channels; -- Move it back
sqlite> alter table channels add feed_update_enabled INTEGER;
sqlite> .quit

Then I'm able to run gpodder 2.9.



Schema dump of the two tables after the first crash:

sqlite> .schema channels_save
CREATE TABLE "channels_save" (
            id INTEGER PRIMARY KEY,
            url TEXT,
            title TEXT,
            override_title TEXT,
            link TEXT,
            description TEXT,
            image TEXT,
            pubDate INTEGER,
            sync_to_devices INTEGER,
            device_playlist_name TEXT,
            username TEXT,
            password TEXT,
            last_modified TEXT,
            etag TEXT,
            deleted INTEGER
            , channel_is_locked INTEGER, foldername TEXT, auto_foldername
INTEGER, release_expected INTEGER, release_deviation INTEGER, updated_timestamp
INTEGER);
CREATE INDEX idx_deleted ON "channels_save" (deleted);
sqlite> .schema channels
CREATE TABLE channels (
  id INTEGER PRIMARY KEY NOT NULL DEFAULT -1,
  url TEXT NOT NULL DEFAULT '',
  title TEXT NOT NULL DEFAULT '',
  override_title TEXT NOT NULL DEFAULT '',
  link TEXT NOT NULL DEFAULT '',
  description TEXT,
  image TEXT,
  pubDate INTEGER NOT NULL DEFAULT 0,
  sync_to_devices INTEGER NOT NULL DEFAULT 1,
  device_playlist_name TEXT NOT NULL DEFAULT 'gPodder',
  username TEXT NOT NULL DEFAULT '',
  password TEXT NOT NULL DEFAULT '',
  last_modified TEXT,
  etag TEXT,
  channel_is_locked INTEGER NOT NULL DEFAULT 0,
  foldername TEXT NOT NULL DEFAULT '',
  auto_foldername INTEGER NOT NULL DEFAULT 1,
  release_expected INTEGER NOT NULL DEFAULT 0,
  release_deviation INTEGER NOT NULL DEFAULT 0,
  updated_timestamp INTEGER NOT NULL DEFAULT 0,
  feed_update_enabled INTEGER NOT NULL DEFAULT 1);
sqlite>

-- 
Configure bugmail: https://bugs.gpodder.org/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are watching all bug changes.
_______________________________________________
gPodder-Bugs mailing list
[email protected]
https://lists.berlios.de/mailman/listinfo/gpodder-bugs

Reply via email to