Error migration database patch 25-30
Stargateur opened this issue · comments
After run psql -U miaou -d miaou -a -f sql/postgres.creation.sql
when I launch ./start
I get an error:
DB query error in raw_statement
utilisation non sûre de la nouvelle valeur « member » du type enum auth_level
update room_auth set auth='member' where auth='write'
An error prevented DB upgrade : error: utilisation non sûre de la nouvelle valeur « member » du type enum auth_level
at Connection.parseE (/home/stargateur/miaou/node_modules/pg/lib/connection.js:614:13)
at Connection.parseMessage (/home/stargateur/miaou/node_modules/pg/lib/connection.js:413:19)
at Socket.<anonymous> (/home/stargateur/miaou/node_modules/pg/lib/connection.js:129:22)
at Socket.emit (events.js:315:20)
at addChunk (_stream_readable.js:295:12)
at readableAddChunk (_stream_readable.js:271:9)
at Socket.Readable.push (_stream_readable.js:212:10)
at TCP.onStreamRead (internal/stream_base_commons.js:186:23)
From previous event:
at Con.proto._query (/home/stargateur/miaou/libs/db.js:1413:9)
at Con.proto.executeRaw (/home/stargateur/miaou/libs/db.js:1443:14)
at Con.<anonymous> (/home/stargateur/miaou/libs/db.js:1268:17)
at FSReqCallback.readFileAfterClose [as oncomplete] (internal/fs/read_file_context.js:63:3)
From previous event:
at Con.<anonymous> (/home/stargateur/miaou/libs/db.js:1266:6)
From previous event:
at Con.<anonymous> (/home/stargateur/miaou/libs/db.js:1257:4)
at FSReqCallback.oncomplete (fs.js:155:23)
From previous event:
at Object.exports.upgrade (/home/stargateur/miaou/libs/db.js:1251:3)
at /home/stargateur/miaou/libs/db.js:1342:18
at processTicksAndRejections (internal/process/task_queues.js:97:5)
at async Object.exports.start (/home/stargateur/miaou/libs/server.js:243:2) {
length: 243,
severity: 'ERREUR',
code: '55P04',
detail: undefined,
hint: 'Les nouvelles valeurs enum doivent être validées (COMMIT) avant de pouvoir être utilisées.',
position: '27',
internalPosition: undefined,
internalQuery: undefined,
where: undefined,
schema: undefined,
table: undefined,
column: undefined,
dataType: undefined,
constraint: undefined,
file: 'enum.c',
line: '98',
routine: 'check_safe_enum_use'
}
All changes are rollbacked