migration-tool
migration-tool copied to clipboard
Error while migrating relations -
yes , i have followed these steps :
- i have created a empty database in mysql
- import sql dumb files one-by-one
- ran v8 directus project and got user auth token by api
- ran v9 new fresh project and got user auth token by api
- ran migration-tool , its now giving error on migrating relations

v8 Database :

Error Log File While Migration:
V9 =>
/relations
undefined
undefined
V9 <=
400
{
"errors": [
{
"message": "Field \"output_destination_id\" in collection \"output_destination_deal_pool\" already has an associated relationship",
"extensions": {
"code": "INVALID_PAYLOAD"
}
}
]
}
Error: V9 => /relations undefined undefined V9 <= 400 { "errors": [ { "message": "Field "output_destination_id" in collection "output_destination_deal_pool" already has an associated relationship", "extensions": { "code": "INVALID_PAYLOAD" } } ] }
at file:///C:/Omair%20Folder/Office%20Projects/Directus%20Database%20Migration%20Project/migration-tool/api.js:41:9
at processTicksAndRejections (node:internal/process/task_queues:96:5)
at async migrateRelationsData (file:///C:/Omair%20Folder/Office%20Projects/Directus%20Database%20Migration%20Project/migration-tool/tasks/relations.js:116:3)
I get this: Cannot read properties of undefined (reading 'reduce')
Error log
V8 =>
/relations
[object Object]
{
"limit": -1
}
V8 <=
401
{
"error": {
"code": 3,
"message": "Unauthorized request"
}
}
Error:
V8 =>
/relations
[object Object]
{
"limit": -1
}
V8 <=
401
{
"error": {
"code": 3,
"message": "Unauthorized request"
}
}
at file:///home/walfin/Dokumentujo/Github/migration-tool/api.js:18:9
at processTicksAndRejections (node:internal/process/task_queues:96:5)
at async getRelationsData (file:///home/walfin/Dokumentujo/Github/migration-tool/tasks/relations.js:40:20)