YunoHost-Apps / audiobookshelf_ynh

Audiobookshelf package for YunoHost
https://audiobookshelf.org/
GNU General Public License v3.0
5 stars 5 forks source link

audiobookshelf broken after upgrade #96

Open KvIKtIFvMN opened 11 months ago

KvIKtIFvMN commented 11 months ago

Describe the bug

App service crashes immediatly after I try to start it. I cant restore from backup because of https://github.com/YunoHost-Apps/audiobookshelf_ynh/issues/95

Context

Steps to reproduce

yunohost app update audiobookshelf --no-safety-backup

yunohost service restart audiobookshelf

Expected behavior

Start the software.

Logs

I have to read through logs line by line to redact potentially de-anonimizing info so lmk if need more details

[20xx-xx-xx xx:xx:x6] INFO: === Starting Server ===
[20xx-xx-xx xx:xx:x6] INFO: [Server] Init v2.5.0
[20xx-xx-xx xx:xx:x6] INFO: [Database] Initializing db at "/home/yunohost.app/audiobookshelf/config/absdatabase.sqlite"
[20xx-xx-xx xx:xx:x6] INFO: [Database] Db connection was successful
[20xx-xx-xx xx:xx:x6] INFO: [Database] Db initialized with models: user, library, libraryFolder, book, podcast, podcastEpisode, libraryItem, mediaProgress, series, bookSeries, author, bookAuthor, collection, collectionBook, playlist, playlistMediaItem, device, playbackSession, feed, feedEpisode, setting
[20xx-xx-xx xx:xx:x6] WARN: [ServerSettings] Invalid metadataFileFormat abs (as of v2.4.5 only json is supported) (ServerSettings.js:114)
[20xx-xx-xx xx:xx:x6] INFO: [dbMigration] Migration patch 2.3.0+ - extraData columns already on model
[20xx-xx-xx xx:xx:x6] INFO: [dbMigration] Applying migration patch from 2.3.0+
[20xx-xx-xx xx:xx:x7] INFO: [oldDbFiles] Loading db data at "/home/yunohost.app/audiobookshelf/config/libraryItems/data"
[20xx-xx-xx xx:xx:x7] INFO: [oldDbFiles] Loading db data file "/home/yunohost.app/audiobookshelf/config/libraryItems/data/data.0.json"
[oldDbFiles] Db file "/home/yunohost.app/audiobookshelf/config/libraryItems/data/data.0.json" processed
[20xx-xx-xx xx:xx:x7] INFO: [oldDbFiles] Processed db data file with 13 entities
[20xx-xx-xx xx:xx:x7] INFO: [oldDbFiles] Loading db data file "/home/yunohost.app/audiobookshelf/config/libraryItems/data/data.1.json"
[oldDbFiles] Db file "/home/yunohost.app/audiobookshelf/config/libraryItems/data/data.1.json" processed
[20xx-xx-xx xx:xx:x7] INFO: [oldDbFiles] Processed db data file with 11 entities
[20xx-xx-xx xx:xx:x7] INFO: [oldDbFiles] Loading db data file "/home/yunohost.app/audiobookshelf/config/libraryItems/data/data.2.json"
[oldDbFiles] Db file "/home/yunohost.app/audiobookshelf/config/libraryItems/data/data.2.json" processed
[20xx-xx-xx xx:xx:x7] INFO: [oldDbFiles] Processed db data file with 16 entities
[20xx-xx-xx xx:xx:x7] INFO: [oldDbFiles] Loading db data file "/home/yunohost.app/audiobookshelf/config/libraryItems/data/data.3.json"
[oldDbFiles] Db file "/home/yunohost.app/audiobookshelf/config/libraryItems/data/data.3.json" processed
[20xx-xx-xx xx:xx:x7] INFO: [oldDbFiles] Processed db data file with 10 entities
[20xx-xx-xx xx:xx:x7] INFO: [oldDbFiles] Loading db data file "/home/yunohost.app/audiobookshelf/config/libraryItems/data/data.4.json"
[oldDbFiles] Db file "/home/yunohost.app/audiobookshelf/config/libraryItems/data/data.4.json" processed
[20xx-xx-xx xx:xx:x7] INFO: [oldDbFiles] Processed db data file with 12 entities
[20xx-xx-xx xx:xx:x7] INFO: [oldDbFiles] Finished loading db data with 62 entities
[20xx-xx-xx xx:xx:x7] INFO: [oldDbFiles] 62 libraryItems loaded
node:internal/process/promises:279
            triggerUncaughtException(err, true /* fromPromise */);
            ^

Error
    at Database.<anonymous> (/var/www/audiobookshelf/node_modules/sequelize/lib/dialects/sqlite/query.js:185:27)
    at /var/www/audiobookshelf/node_modules/sequelize/lib/dialects/sqlite/query.js:183:50
    at new Promise (<anonymous>)
    at Query.run (/var/www/audiobookshelf/node_modules/sequelize/lib/dialects/sqlite/query.js:183:12)
    at /var/www/audiobookshelf/node_modules/sequelize/lib/sequelize.js:315:28
    at runMicrotasks (<anonymous>)
    at processTicksAndRejections (node:internal/process/task_queues:96:5)
    at async SQLiteQueryInterface.select (/var/www/audiobookshelf/node_modules/sequelize/lib/dialects/abstract/query-interface.js:407:12)
    at async Function.findAll (/var/www/audiobookshelf/node_modules/sequelize/lib/model.js:1140:21)
    at async Function.getAllOldLibraryItems (/var/www/audiobookshelf/server/models/LibraryItem.js:116:24) {
  name: 'SequelizeDatabaseError',
  parent: [Error: SQLITE_ERROR: no such column: libraryItem.size] {
    errno: 1,
    code: 'SQLITE_ERROR',
    sql: 'SELECT `libraryItem`.`id`, 
navanchauhan commented 9 months ago

Let me look into this after my finals end