mybb / merge-system

The MyBB Merge System allows for easy merging of an existing forum (be it MyBB or another forum software) into a MyBB 1.8.x forum.
Other
34 stars 34 forks source link

Vanilla not importing correctly with a fresh MyBB (1.8.26) #272

Open luisalvarado opened 3 years ago

luisalvarado commented 3 years ago

I downloaded MyBB 1.8.26 and used the latest backup from Vanilla from June 2021, apart form the latest Git update from the MyBB Merger. After I did this, Here are the issues encountered:

  1. I was not able to import the users because it said there were duplicates. I did a temp change where the username was not unique in the mybb_users table to solve that issue.
  2. Categories were not imported in a way that they had a parent child relationship.
  3. Because of point 2, Posts, threads and more had issues.

I have uploaded a video to youtube about it here:

https://www.youtube.com/watch?v=V5BNnVn1DBM

luisalvarado commented 3 years ago

Can anyone be hired for the this. We would pay for someone to solve this. There is a $500 USD bounty for it.

Sama34 commented 3 years ago

According to #269 https://github.com/mybb/merge-system/issues/264#issuecomment-855244179

Posts and categories were the last issues, but it got worse?

Sama34 commented 3 years ago

You can send me your test DB and I will attempt to figure it out.

euantorano commented 3 years ago

Sorry for the delay on this, I've been busy with work.

  1. Duplicate usernames are probably going to cause other issues (mostly with logins I guess) - I'm quite surprised Vanilla allows this! The duplicate username appears to be an empty string ('') in your video, which is even weirder... Empty usernames are not supported in MyBB so I guess there's something wrong with the mapping of the username.
  2. When I did a test merge with a previous database I ended up with one category and a whole load of nested forums, but I did have to do recount and rebuild and flush caches and stuff to get it to work at all. When I looked at your test board I did notice that nothing got nested at all which is odd.
yuliu commented 3 years ago
1. Duplicate usernames are probably going to cause other issues (mostly with logins I guess) - I'm quite surprised Vanilla allows this! The duplicate username appears to be an empty string (`''`) in your video, which is even weirder... Empty usernames are not supported in MyBB so I guess there's something wrong with the mapping of the username.

For this one, I think we may use randomized usernames for users whose old usernames are empty, or maybe there are other fields like "display name", etc. that we can use.

Sama34 commented 3 years ago

If no additional similar fields exists, should probably be built with the UID and some stock name. i.e: MergedUser<UID>

luisalvarado commented 3 years ago

Apologies, got caught up with kids and work. Yes I also was under that impression with Vanilla but could not believe it. I thought I was getting it wrong. Maybe because they might allow for the same username but different password?

nstaff commented 2 years ago

Hi everyone. I've made some progress on this one. I've been able to correct the issues with a couple of direct queries prior to the cleanup step of the import, but I'm a bit strapped for time to find the right places in the code base to get the resolved implemented into a PR without some guidance.

In the import, it appears many of the posts get orphaned from their user when they get imported. Additionally, some threads are showing "Invalid" due to a missing parent list.

I was hoping to discuss with someone:

a) find the right place to drop these into the code base, or b) point me in the direction of just fixing them in the code base, (not asking you to do the work, just a quick "yeah, its probably over here." kind of thing might be helpful), rather than doing post-run queries.

There's a chance that a query at the end to join across databases is just the correct way to do this, also. Happy to just drop that in the code.

Just want to make sure I'm adhering to any project standards before I do.