Open mkdbns opened 2 years ago
from @svelle
I knew this issue sounded familiar. I actually started writing a patch for this error a couple years back https://github.com/mattermost/mmetl/pull/6/files for several reasons the changes never made it into mmetl but my changes are still available on GH so feel free to use them in case you want to build a patch for this.
basically the issue is that slack does not create bot users for any bots in the export but references their user/bot-id which in turn causes mmetl to error out because it finds a message with no user attached to it. I think if you ignore this all that happens is that those messages will be missing from the export, however there's some customers for whom this wouldn't be an option.
My patch did a first pass before any conversions happened to fetch all user ids in the posts lists and checked if there's a userid existing in the users.json. If that wasn't the case it created a intermittent user that got a generic username which could then accept all the bot posts.
We were following the Slack migration guide. Running step:
./mmetl transform slack --team <TEAM NAME> --file export-with-emails-and-attachments.zip --output mattermost_import.jsonl
mmetl reports numerous errors similar to the following: