XF 1.2 Abstract.php has a broken class?

Shinracorp

Member
Hey everyone,

I was just rebuilding my caches today and when it came to building it I get a fatal error saying that: Class name must be a valid object or a string in /library/XenForo/Search/DataHandler/Abstract.php on line 291

The function in question is this

PHP:
public static function create($class)
    {
        $class = XenForo_Application::resolveDynamicClass($class, 'search_data');
        return new $class;
    }

Being a total fool at programming I have no idea what it's supposed to do this function.
 
Hey everyone,

I was just rebuilding my caches today and when it came to building it I get a fatal error saying that: Class name must be a valid object or a string in /library/XenForo/Search/DataHandler/Abstract.php on line 291

The function in question is this

PHP:
public static function create($class)
    {
        $class = XenForo_Application::resolveDynamicClass($class, 'search_data');
        return new $class;
    }

Being a total fool at programming I have no idea what it's supposed to do this function.
3 things come to mind.

Try re-uploading the file again.

I've seen 1 add-on (TapaTalk) conflict with the rebuilding the search. If you have it, try disabling it.

Also what version of php are you using?
 
Hey, I've reuploaded twice but same error, but I will list all my add-ons here perhaps it's a conflict with one of them:


Bb Codes & Buttons Manager 1.1.8
Resource Manager - Thread Reassign 1.0.1
sonnb - Bulk importer for smilies management 1.0.4
Steam Auth 1.3.5
TaigaChat 0.5.5
XenForo Resource Manager 1.0.1
[8wayRun.Com] XenPorta (Portal) 1.5.8
[8wayRun.Com] XenUtiles (Spam) 1.0.1
[bd] Tag Me 1.7.5
[bd] Widget Framework 2.2.3

The PHP version I got is 5.3.27
 
I've updated all of my add-ons (they should work with 1.2.3 now) sadly the error still happens, is there a way to debug the rebuild the cache? To see what it's trying to rebuild before it crashes? Because it tries to rebuild the Search Index and that's where it crashes.
 
It either means that an add-on is bugged or a content type has been added to the search index but the class doesn't exist. This could be related to an add-on that was uninstalled but didn't clean itself up properly.

If you try to rebuild the search index one content type at a time, you should be able to build it except (presumably) one type. What type is that?
 
It either means that an add-on is bugged or a content type has been added to the search index but the class doesn't exist. This could be related to an add-on that was uninstalled but didn't clean itself up properly.

If you try to rebuild the search index one content type at a time, you should be able to build it except (presumably) one type. What type is that?

Hey Mike, you mean instead of Rebuild All I go to each type? I tried Rebuild Threads which lead me to an error
Code:
Argument 1 passed to XenForo_DataWriter_Discussion_Thread::_discussionPostSave() must be an array, none given, called in  library/EWRporta/DataWriter/Discussion/Thread.php on line 7 and defined
1.XenForo_Application::handlePhpError() in XenForo/DataWriter/Discussion/Thread.php at line 183
2.XenForo_DataWriter_Discussion_Thread->_discussionPostSave() in EWRporta/DataWriter/Discussion/Thread.php at line 7
3.EWRporta_DataWriter_Discussion_Thread->_discussionPostSave() in XenForo/DataWriter/Discussion.php at line 391
4.XenForo_DataWriter_Discussion->_postSave() in XenForo/DataWriter.php at line 1385
5.XenForo_DataWriter->save() in XenForo/CacheRebuilder/Thread.php at line 73
6.XenForo_CacheRebuilder_Thread->rebuild() in XenForo/ControllerHelper/CacheRebuild.php at line 26
7.XenForo_ControllerHelper_CacheRebuild->rebuildCache() in XenForo/ControllerAdmin/Tools.php at line 78
8.XenForo_ControllerAdmin_Tools->actionCacheRebuild() in XenForo/FrontController.php at line 313
9.XenForo_FrontController->dispatch() in XenForo/FrontController.php at line 132
10.XenForo_FrontController->run() in /home/trish769/public_html/admin.php at line 13

So I`m guessing it has something to do with XenPorta correct?
 
Hey Mike, you mean instead of Rebuild All I go to each type? I tried Rebuild Threads which lead me to an error
Code:
Argument 1 passed to XenForo_DataWriter_Discussion_Thread::_discussionPostSave() must be an array, none given, called in  library/EWRporta/DataWriter/Discussion/Thread.php on line 7 and defined
1.XenForo_Application::handlePhpError() in XenForo/DataWriter/Discussion/Thread.php at line 183
2.XenForo_DataWriter_Discussion_Thread->_discussionPostSave() in EWRporta/DataWriter/Discussion/Thread.php at line 7
3.EWRporta_DataWriter_Discussion_Thread->_discussionPostSave() in XenForo/DataWriter/Discussion.php at line 391
4.XenForo_DataWriter_Discussion->_postSave() in XenForo/DataWriter.php at line 1385
5.XenForo_DataWriter->save() in XenForo/CacheRebuilder/Thread.php at line 73
6.XenForo_CacheRebuilder_Thread->rebuild() in XenForo/ControllerHelper/CacheRebuild.php at line 26
7.XenForo_ControllerHelper_CacheRebuild->rebuildCache() in XenForo/ControllerAdmin/Tools.php at line 78
8.XenForo_ControllerAdmin_Tools->actionCacheRebuild() in XenForo/FrontController.php at line 313
9.XenForo_FrontController->dispatch() in XenForo/FrontController.php at line 132
10.XenForo_FrontController->run() in /home/trish769/public_html/admin.php at line 13

So I`m guessing it has something to do with XenPorta correct?
I would say yes, as I could find this error in that add-on thread.

Try disabling the add-on and see if you're able to rebuild anything
 
Yeap Threads are being rebuilt with XenPorta disabled.... so I guess I should do a clean uninstall (is there a way how?) and then Reinstall it?
You could do that, but if I may, I would suggest an alternative.

Extra Portal which is developed by @ExtraLicense is what I'm using on my site http://www.sociallyuncensored.eu It's a lot more well developed and the developer supports it completely.

XenPorta was "popular" mostly because it was the 1st portal that was truly developed. And so many people kind of stuck with it. But the developer himself has stated he has not real desire to extensively support it and you can see a lot of issues in the thread for it.

http://xenforo.com/community/resources/extra-portal.2321/

Everyone who've I've migrated over to this has had no issues or conflict. It is also very widget friendly as well as hook friendly. Best of all, it is free. :)
 
  • Like
Reactions: Dan
Thanks although it came out with an error when installing it.
Code:
Missing argument 3 for SimplePortal_Install_Controller::install()
1.XenForo_Application::handlePhpError() in SimplePortal/Install/Controller.php at line 165
2.SimplePortal_Install_Controller::install()
3.call_user_func() in XenForo/Model/AddOn.php at line 214
4.XenForo_Model_AddOn->installAddOnXml() in XenForo/Model/AddOn.php at line 169
5.XenForo_Model_AddOn->installAddOnXmlFromFile() in XenForo/ControllerAdmin/AddOn.php at line 178
6.XenForo_ControllerAdmin_AddOn->actionInstall() in XenForo/FrontController.php at line 313
7.XenForo_FrontController->dispatch() in XenForo/FrontController.php at line 132
8.XenForo_FrontController->run() in /home/trish769/public_html/admin.php at line 13
 
Thanks although it came out with an error when installing it.
Code:
Missing argument 3 for SimplePortal_Install_Controller::install()
1.XenForo_Application::handlePhpError() in SimplePortal/Install/Controller.php at line 165
2.SimplePortal_Install_Controller::install()
3.call_user_func() in XenForo/Model/AddOn.php at line 214
4.XenForo_Model_AddOn->installAddOnXml() in XenForo/Model/AddOn.php at line 169
5.XenForo_Model_AddOn->installAddOnXmlFromFile() in XenForo/ControllerAdmin/AddOn.php at line 178
6.XenForo_ControllerAdmin_AddOn->actionInstall() in XenForo/FrontController.php at line 313
7.XenForo_FrontController->dispatch() in XenForo/FrontController.php at line 132
8.XenForo_FrontController->run() in /home/trish769/public_html/admin.php at line 13
Did you suggestfully un-install XenPorta before installing Extra Portal? I don't think you can have more than one portal install at a time (I'm sure you could, but I don't see it being a good idea personally).
 
Thanks although it came out with an error when installing it.
Code:
Missing argument 3 for SimplePortal_Install_Controller::install()
1.XenForo_Application::handlePhpError() in SimplePortal/Install/Controller.php at line 165
2.SimplePortal_Install_Controller::install()
3.call_user_func() in XenForo/Model/AddOn.php at line 214
4.XenForo_Model_AddOn->installAddOnXml() in XenForo/Model/AddOn.php at line 169
5.XenForo_Model_AddOn->installAddOnXmlFromFile() in XenForo/ControllerAdmin/AddOn.php at line 178
6.XenForo_ControllerAdmin_AddOn->actionInstall() in XenForo/FrontController.php at line 313
7.XenForo_FrontController->dispatch() in XenForo/FrontController.php at line 132
8.XenForo_FrontController->run() in /home/trish769/public_html/admin.php at line 13
What xenforo version are you using?

This is a "known" problem with our installer, which is happening with xenforo < 1.2.0 (and extra portal requires xenforo >=1.2.0
 
Nah I uninstalled it but... get ready for a facepalm.... I thought I installed Xenforo 1.2.3 but apparently it's at version 1.1.5.... Soooooo this thing could of probably avoided if I installed the lastest....
 
Nah I uninstalled it but... get ready for a facepalm.... I thought I installed Xenforo 1.2.3 but apparently it's at version 1.1.5.... Soooooo this thing could of probably avoided if I installed the lastest....
Don't feel bad. It happens.

Just be sure to have all your add-ons disabled when you upgrade to XenForo 1.2.x. Then slowly enable them one by one (should make a backup before hand too, just for good measure).
 
Top Bottom