Jump to:

7940 Posts in 1543 Topics by 946 members

DataObjectManager Module

SilverStripe Forums » DataObjectManager Module » Fatal error: Class 'TranslatableObject' not found in /var/www/awattgarde-test/mysite/_config.php on line 103

Discuss the DataObjectManager module, and the related ImageGallery module.

Moderators: martimiz, UncleCheese, Sean, biapar, Willr, Ingo, swaiba, simon_w

Page: 1
Go to End
Author Topic: 602 Views
  • krisacup
    Community Member
    1 Post

    Fatal error: Class 'TranslatableObject' not found in /var/www/awattgarde-test/mysite/_config.php on line 103 Link to this post

    Running the following update script on a linux server: sudo -u www-data sh /var/www/awattgarde-test/sapphire/sake dev/build

    Gives: Fatal error: Class 'TranslatableObject' not found in /var/www/awattgarde-test/mysite/_config.php on line 103
    However, dev/build through the browser works.

    On the config.php file, some extensions were added:


    Object::add_extension('ApplianceData', 'TranslatableObject');
    Object::add_extension('Quiz', 'TranslatableObject');
    Object::add_extension('QuizOption', 'TranslatableObject');
    Object::add_extension('SavingTip', 'TranslatableObject');

    Adding another extension also threw the same error. For example, after creating a class which will be an extension and then adding the extension on the _config.php file, then running the /dev/build script returned the same error: 'Class not found.'

    The problem was curiously solved by commenting the recently ::add_extension() in the _config.php file, running the /dev/build script, and then adding (uncommenting) the extension in the _config.php file and running /dev/build again. It seems like it's necessary to build the class that will be an extension and afterwards build the extension...

    However it makes things a bit complicated... Is this a known bug ? Or is there something wrong in the procedure?

Page: 1
Go to Top

Want to know more about the company that brought you SilverStripe? Then check out SilverStripe.com

Comments on this website? Please give feedback.