Gatsu Without Varnish cache it's better (I immediately see the posts, without delay) but now I have this debug error:
POST http://mysite.com/api/mybb-to-flarum
{
"errors": [
{
"status": "500",
"code": "unknown",
"detail": "TypeError: Argument 1 passed to Flarum\\Discussion\\Discussion::setFirstPost() must be an instance of Flarum\\Post\\Post, null given, called in /home/omaggiec/public_html/vendor/michaelbelgium/mybb-to-flarum/src/Migrator.php on line 262 and defined in /home/omaggiec/public_html/vendor/flarum/core/src/Discussion/Discussion.php:201\nStack trace:\n#0 /home/omaggiec/public_html/vendor/michaelbelgium/mybb-to-flarum/src/Migrator.php(262): Flarum\\Discussion\\Discussion->setFirstPost(NULL)\n#1 /home/omaggiec/public_html/vendor/michaelbelgium/mybb-to-flarum/src/Controllers/MybbToFlarumController.php(68): Michaelbelgium\\Mybbtoflarum\\Migrator->migrateDiscussions(false, true, false, false)\n#2 /home/omaggiec/public_html/vendor/flarum/core/src/Http/RouteHandlerFactory.php(38): Michaelbelgium\\Mybbtoflarum\\Controllers\\MybbToFlarumController->handle(Object(Laminas\\Diactoros\\ServerRequest))\n#3 /home/omaggiec/public_html/vendor/flarum/core/src/Http/Middleware/DispatchRoute.php(65): Flarum\\Http\\RouteHandlerFactory->Flarum\\Http\\{closure}(Object(Laminas\\Diactoros\\ServerRequest), Array)\n#4 /home/omaggiec/public_html/vendor/laminas/laminas-stratigility/src/Next.php(61): Flarum\\Http\\Middleware\\DispatchRoute->process(Object(Laminas\\Diactoros\\ServerRequest), Object(Closure))\n#5 /home/omaggiec/public_html/vendor/flarum/core/src/Http/Middleware/SetLocale.php(50): Laminas\\Stratigility\\Next->handle(Object(Laminas\\Diactoros\\ServerRequest))\n#6 /home/omaggiec/public_html/vendor/laminas/laminas-stratigility/src/Next.php(61): Flarum\\Http\\Middleware\\SetLocale->process(Object(Laminas\\Diactoros\\ServerRequest), Object(Laminas\\Stratigility\\Next))\n#7 /home/omaggiec/public_html/vendor/flarum/core/src/Http/Middleware/CheckCsrfToken.php(45): Laminas\\Stratigility\\Next->handle(Object(Laminas\\Diactoros\\ServerRequest))\n#8 /home/omaggiec/public_html/vendor/laminas/laminas-stratigility/src/Next.php(61): Flarum\\Http\\Middleware\\CheckCsrfToken->process(Object(Laminas\\Diactoros\\ServerRequest), Object(Laminas\\Stratigility\\Next))\n#9 /home/omaggiec/public_html/vendor/flarum/core/src/Http/Middleware/AuthenticateWithHeader.php(55): Laminas\\Stratigility\\Next->handle(Object(Laminas\\Diactoros\\ServerRequest))\n#10 /home/omaggiec/public_html/vendor/laminas/laminas-stratigility/src/Next.php(61): Flarum\\Http\\Middleware\\AuthenticateWithHeader->process(Object(Laminas\\Diactoros\\ServerRequest), Object(Laminas\\Stratigility\\Next))\n#11 /home/omaggiec/public_html/vendor/flarum/core/src/Http/Middleware/AuthenticateWithSession.php(32): Laminas\\Stratigility\\Next->handle(Object(Laminas\\Diactoros\\ServerRequest))\n#12 /home/omaggiec/public_html/vendor/laminas/laminas-stratigility/src/Next.php(61): Flarum\\Http\\Middleware\\AuthenticateWithSession->process(Object(Laminas\\Diactoros\\ServerRequest), Object(Laminas\\Stratigility\\Next))\n#13 /home/omaggiec/public_html/vendor/flarum/core/src/Http/Middleware/RememberFromCookie.php(51): Laminas\\Stratigility\\Next->handle(Object(Laminas\\Diactoros\\ServerRequest))\n#14 /home/omaggiec/public_html/vendor/laminas/laminas-stratigility/src/Next.php(61): Flarum\\Http\\Middleware\\RememberFromCookie->process(Object(Laminas\\Diactoros\\ServerRequest), Object(Laminas\\Stratigility\\Next))\n#15 /home/omaggiec/public_html/vendor/flarum/core/src/Http/Middleware/StartSession.php(61): Laminas\\Stratigility\\Next->handle(Object(Laminas\\Diactoros\\ServerRequest))\n#16 /home/omaggiec/public_html/vendor/laminas/laminas-stratigility/src/Next.php(61): Flarum\\Http\\Middleware\\StartSession->process(Object(Laminas\\Diactoros\\ServerRequest), Object(Laminas\\Stratigility\\Next))\n#17 /home/omaggiec/public_html/vendor/flarum/core/src/Api/Middleware/FakeHttpMethods.php(29): Laminas\\Stratigility\\Next->handle(Object(Laminas\\Diactoros\\ServerRequest))\n#18 /home/omaggiec/public_html/vendor/laminas/laminas-stratigility/src/Next.php(61): Flarum\\Api\\Middleware\\FakeHttpMethods->process(Object(Laminas\\Diactoros\\ServerRequest), Object(Laminas\\Stratigility\\Next))\n#19 /home/omaggiec/public_html/vendor/flarum/core/src/Http/Middleware/ParseJsonBody.php(28): Laminas\\Stratigility\\Next->handle(Object(Laminas\\Diactoros\\ServerRequest))\n#20 /home/omaggiec/public_html/vendor/laminas/laminas-stratigility/src/Next.php(61): Flarum\\Http\\Middleware\\ParseJsonBody->process(Object(Laminas\\Diactoros\\ServerRequest), Object(Laminas\\Stratigility\\Next))\n#21 /home/omaggiec/public_html/vendor/flarum/core/src/Http/Middleware/HandleErrors.php(57): Laminas\\Stratigility\\Next->handle(Object(Laminas\\Diactoros\\ServerRequest))\n#22 /home/omaggiec/public_html/vendor/laminas/laminas-stratigility/src/Next.php(61): Flarum\\Http\\Middleware\\HandleErrors->process(Object(Laminas\\Diactoros\\ServerRequest), Object(Laminas\\Stratigility\\Next))\n#23 /home/omaggiec/public_html/vendor/laminas/laminas-stratigility/src/MiddlewarePipe.php(84): Laminas\\Stratigility\\Next->handle(Object(Laminas\\Diactoros\\ServerRequest))\n#24 /home/omaggiec/public_html/vendor/middlewares/request-handler/src/RequestHandler.php(84): Laminas\\Stratigility\\MiddlewarePipe->process(Object(Laminas\\Diactoros\\ServerRequest), Object(Laminas\\Stratigility\\Next))\n#25 /home/omaggiec/public_html/vendor/laminas/laminas-stratigility/src/Next.php(61): Middlewares\\RequestHandler->process(Object(Laminas\\Diactoros\\ServerRequest), Object(Laminas\\Stratigility\\Next))\n#26 /home/omaggiec/public_html/vendor/middlewares/base-path-router/src/BasePathRouter.php(97): Laminas\\Stratigility\\Next->handle(Object(Laminas\\Diactoros\\ServerRequest))\n#27 /home/omaggiec/public_html/vendor/laminas/laminas-stratigility/src/Next.php(61): Middlewares\\BasePathRouter->process(Object(Laminas\\Diactoros\\ServerRequest), Object(Laminas\\Stratigility\\Next))\n#28 /home/omaggiec/public_html/vendor/laminas/laminas-stratigility/src/Middleware/OriginalMessages.php(42): Laminas\\Stratigility\\Next->handle(Object(Laminas\\Diactoros\\ServerRequest))\n#29 /home/omaggiec/public_html/vendor/laminas/laminas-stratigility/src/Next.php(61): Laminas\\Stratigility\\Middleware\\OriginalMessages->process(Object(Laminas\\Diactoros\\ServerRequest), Object(Laminas\\Stratigility\\Next))\n#30 /home/omaggiec/public_html/vendor/middlewares/base-path/src/BasePath.php(53): Laminas\\Stratigility\\Next->handle(Object(Laminas\\Diactoros\\ServerRequest))\n#31 /home/omaggiec/public_html/vendor/laminas/laminas-stratigility/src/Next.php(61): Middlewares\\BasePath->process(Object(Laminas\\Diactoros\\ServerRequest), Object(Laminas\\Stratigility\\Next))\n#32 /home/omaggiec/public_html/vendor/laminas/laminas-stratigility/src/MiddlewarePipe.php(84): Laminas\\Stratigility\\Next->handle(Object(Laminas\\Diactoros\\ServerRequest))\n#33 /home/omaggiec/public_html/vendor/laminas/laminas-stratigility/src/MiddlewarePipe.php(73): Laminas\\Stratigility\\MiddlewarePipe->process(Object(Laminas\\Diactoros\\ServerRequest), Object(Laminas\\Stratigility\\EmptyPipelineHandler))\n#34 /home/omaggiec/public_html/vendor/laminas/laminas-httphandlerrunner/src/RequestHandlerRunner.php(96): Laminas\\Stratigility\\MiddlewarePipe->handle(Object(Laminas\\Diactoros\\ServerRequest))\n#35 /home/omaggiec/public_html/vendor/flarum/core/src/Http/Server.php(42): Laminas\\HttpHandlerRunner\\RequestHandlerRunner->run()\n#36 /home/omaggiec/public_html/index.php(26): Flarum\\Http\\Server->listen()\n#37 {main}"
}
]
}
And stuck always on 1K discussions and 40K posts
EDIT: Resolved!!! (For now)
I had 0 on firstpost column in mybb database, about a discussion. Deleted discussion and now it's importing again 😃
mybb_threads table -> check firstpost column, you don't have to have 0
But again stuck 🙁 This time I have this error:
POST http://mysite.com/api/mybb-to-flarum
{
"errors": [
{
"status": "405",
"code": "method_not_allowed",
"detail": "Flarum\\Http\\Exception\\MethodNotAllowedException: GET in /home/omaggiec/public_html/vendor/flarum/core/src/Http/Middleware/DispatchRoute.php:60\nStack trace:\n#0 /home/omaggiec/public_html/vendor/laminas/laminas-stratigility/src/Next.php(61): Flarum\\Http\\Middleware\\DispatchRoute->process(Object(Laminas\\Diactoros\\ServerRequest), Object(Laminas\\Stratigility\\Next))\n#1 /home/omaggiec/public_html/vendor/flarum/core/src/Http/Middleware/SetLocale.php(50): Laminas\\Stratigility\\Next->handle(Object(Laminas\\Diactoros\\ServerRequest))\n#2 /home/omaggiec/public_html/vendor/laminas/laminas-stratigility/src/Next.php(61): Flarum\\Http\\Middleware\\SetLocale->process(Object(Laminas\\Diactoros\\ServerRequest), Object(Laminas\\Stratigility\\Next))\n#3 /home/omaggiec/public_html/vendor/flarum/core/src/Http/Middleware/CheckCsrfToken.php(37): Laminas\\Stratigility\\Next->handle(Object(Laminas\\Diactoros\\ServerRequest))\n#4 /home/omaggiec/public_html/vendor/laminas/laminas-stratigility/src/Next.php(61): Flarum\\Http\\Middleware\\CheckCsrfToken->process(Object(Laminas\\Diactoros\\ServerRequest), Object(Laminas\\Stratigility\\Next))\n#5 /home/omaggiec/public_html/vendor/flarum/core/src/Http/Middleware/AuthenticateWithHeader.php(55): Laminas\\Stratigility\\Next->handle(Object(Laminas\\Diactoros\\ServerRequest))\n#6 /home/omaggiec/public_html/vendor/laminas/laminas-stratigility/src/Next.php(61): Flarum\\Http\\Middleware\\AuthenticateWithHeader->process(Object(Laminas\\Diactoros\\ServerRequest), Object(Laminas\\Stratigility\\Next))\n#7 /home/omaggiec/public_html/vendor/flarum/core/src/Http/Middleware/AuthenticateWithSession.php(32): Laminas\\Stratigility\\Next->handle(Object(Laminas\\Diactoros\\ServerRequest))\n#8 /home/omaggiec/public_html/vendor/laminas/laminas-stratigility/src/Next.php(61): Flarum\\Http\\Middleware\\AuthenticateWithSession->process(Object(Laminas\\Diactoros\\ServerRequest), Object(Laminas\\Stratigility\\Next))\n#9 /home/omaggiec/public_html/vendor/flarum/core/src/Http/Middleware/RememberFromCookie.php(51): Laminas\\Stratigility\\Next->handle(Object(Laminas\\Diactoros\\ServerRequest))\n#10 /home/omaggiec/public_html/vendor/laminas/laminas-stratigility/src/Next.php(61): Flarum\\Http\\Middleware\\RememberFromCookie->process(Object(Laminas\\Diactoros\\ServerRequest), Object(Laminas\\Stratigility\\Next))\n#11 /home/omaggiec/public_html/vendor/flarum/core/src/Http/Middleware/StartSession.php(61): Laminas\\Stratigility\\Next->handle(Object(Laminas\\Diactoros\\ServerRequest))\n#12 /home/omaggiec/public_html/vendor/laminas/laminas-stratigility/src/Next.php(61): Flarum\\Http\\Middleware\\StartSession->process(Object(Laminas\\Diactoros\\ServerRequest), Object(Laminas\\Stratigility\\Next))\n#13 /home/omaggiec/public_html/vendor/flarum/core/src/Api/Middleware/FakeHttpMethods.php(29): Laminas\\Stratigility\\Next->handle(Object(Laminas\\Diactoros\\ServerRequest))\n#14 /home/omaggiec/public_html/vendor/laminas/laminas-stratigility/src/Next.php(61): Flarum\\Api\\Middleware\\FakeHttpMethods->process(Object(Laminas\\Diactoros\\ServerRequest), Object(Laminas\\Stratigility\\Next))\n#15 /home/omaggiec/public_html/vendor/flarum/core/src/Http/Middleware/ParseJsonBody.php(28): Laminas\\Stratigility\\Next->handle(Object(Laminas\\Diactoros\\ServerRequest))\n#16 /home/omaggiec/public_html/vendor/laminas/laminas-stratigility/src/Next.php(61): Flarum\\Http\\Middleware\\ParseJsonBody->process(Object(Laminas\\Diactoros\\ServerRequest), Object(Laminas\\Stratigility\\Next))\n#17 /home/omaggiec/public_html/vendor/flarum/core/src/Http/Middleware/HandleErrors.php(57): Laminas\\Stratigility\\Next->handle(Object(Laminas\\Diactoros\\ServerRequest))\n#18 /home/omaggiec/public_html/vendor/laminas/laminas-stratigility/src/Next.php(61): Flarum\\Http\\Middleware\\HandleErrors->process(Object(Laminas\\Diactoros\\ServerRequest), Object(Laminas\\Stratigility\\Next))\n#19 /home/omaggiec/public_html/vendor/laminas/laminas-stratigility/src/MiddlewarePipe.php(84): Laminas\\Stratigility\\Next->handle(Object(Laminas\\Diactoros\\ServerRequest))\n#20 /home/omaggiec/public_html/vendor/middlewares/request-handler/src/RequestHandler.php(84): Laminas\\Stratigility\\MiddlewarePipe->process(Object(Laminas\\Diactoros\\ServerRequest), Object(Laminas\\Stratigility\\Next))\n#21 /home/omaggiec/public_html/vendor/laminas/laminas-stratigility/src/Next.php(61): Middlewares\\RequestHandler->process(Object(Laminas\\Diactoros\\ServerRequest), Object(Laminas\\Stratigility\\Next))\n#22 /home/omaggiec/public_html/vendor/middlewares/base-path-router/src/BasePathRouter.php(97): Laminas\\Stratigility\\Next->handle(Object(Laminas\\Diactoros\\ServerRequest))\n#23 /home/omaggiec/public_html/vendor/laminas/laminas-stratigility/src/Next.php(61): Middlewares\\BasePathRouter->process(Object(Laminas\\Diactoros\\ServerRequest), Object(Laminas\\Stratigility\\Next))\n#24 /home/omaggiec/public_html/vendor/laminas/laminas-stratigility/src/Middleware/OriginalMessages.php(42): Laminas\\Stratigility\\Next->handle(Object(Laminas\\Diactoros\\ServerRequest))\n#25 /home/omaggiec/public_html/vendor/laminas/laminas-stratigility/src/Next.php(61): Laminas\\Stratigility\\Middleware\\OriginalMessages->process(Object(Laminas\\Diactoros\\ServerRequest), Object(Laminas\\Stratigility\\Next))\n#26 /home/omaggiec/public_html/vendor/middlewares/base-path/src/BasePath.php(53): Laminas\\Stratigility\\Next->handle(Object(Laminas\\Diactoros\\ServerRequest))\n#27 /home/omaggiec/public_html/vendor/laminas/laminas-stratigility/src/Next.php(61): Middlewares\\BasePath->process(Object(Laminas\\Diactoros\\ServerRequest), Object(Laminas\\Stratigility\\Next))\n#28 /home/omaggiec/public_html/vendor/laminas/laminas-stratigility/src/MiddlewarePipe.php(84): Laminas\\Stratigility\\Next->handle(Object(Laminas\\Diactoros\\ServerRequest))\n#29 /home/omaggiec/public_html/vendor/laminas/laminas-stratigility/src/MiddlewarePipe.php(73): Laminas\\Stratigility\\MiddlewarePipe->process(Object(Laminas\\Diactoros\\ServerRequest), Object(Laminas\\Stratigility\\EmptyPipelineHandler))\n#30 /home/omaggiec/public_html/vendor/laminas/laminas-httphandlerrunner/src/RequestHandlerRunner.php(96): Laminas\\Stratigility\\MiddlewarePipe->handle(Object(Laminas\\Diactoros\\ServerRequest))\n#31 /home/omaggiec/public_html/vendor/flarum/core/src/Http/Server.php(42): Laminas\\HttpHandlerRunner\\RequestHandlerRunner->run()\n#32 /home/omaggiec/public_html/index.php(26): Flarum\\Http\\Server->listen()\n#33 {main}"
}
]
}
Now stuck on 3K discussions and 63K posts.
OTHER EDIT: Maybe now it works, I don't know why.
Only I noticed that even if the red error message comes out, in the administration panel the posts and discussions continued to increase, up to almost everyone, only a few it did not import but patience, most yes.
Then I had to put some things in place, for example when I clicked on the homepage (logo of the forum) it always gave me POST null error, so I pressed on "mark all posts as read" and now it seems to be fine too.
I actived together the options "migrate categories, posts and threads" because otherwise it did not correlate with each other forum and post and it was a disaster. Now, however, it seems that the categories are also more or less ok.