Exception - Class 'core_reportbuilder\permission' not found

Exception - Class 'core_reportbuilder\permission' not found

by Josh Wilson -
Number of replies: 12

We had to update our windows server OS and when it was done the moodle site was stuck in maintenance mode and spits out this error on login as well as anytime we try to access the site administration menu. I cant seem to find a direct answer as to what this exactly does and why it wouldnt allow us to access the menus. We have purged the site cache via command line, updated moodle (we have not moved to 4.0 yet though), added the path (it didnt exist before), and other general wisardry. Nothing has worked so far. Once we added the path back it did populate the folder for us but the error still persists.

Exception - Class 'core_reportbuilder\permission' not found

Attachment Moodle in English_ Add discussion topic — Mozilla Firefox 5_15_2022 4_37_30 PM.png
Attachment TPC_ Administration_ Server_ Maintenance mode - In maintenance mode — Mozilla Firefox 5_15_2022 4_36_40 PM.png
Average of ratings: -
In reply to Josh Wilson

Re: Exception - Class 'core_reportbuilder\permission' not found

by Eric Steiner -

So we had the same problem on our server. There is 2 things you need to move. 


In the Moodle folder you will find another folder called "Report Builder". Move this anywhere outside of the live website folder structure. 


In the moodle/admin/settings folder there will be a php file called "reportbuilder.php". again move this outside of the  live website folder structure. 


After restarting the website, the error went away for us and have found no other issues. 


If anyone from Moodle has any other fixes let me know but after removing those files, the site worked with no problems.  

Average of ratings: Useful (1)
In reply to Josh Wilson

Re: Exception - Class 'core_reportbuilder\permission' not found

by Howard Miller -
Picture of Core developers Picture of Documentation writers Picture of Particularly helpful Moodlers Picture of Peer reviewers Picture of Plugin developers
Isn't report builder part of 'Moodle workplace"??
In reply to Josh Wilson

Re: Exception - Class 'core_reportbuilder\permission' not found

by Paul Holden -
Picture of Core developers Picture of Moodle HQ Picture of Moodle Workplace team Picture of Particularly helpful Moodlers Picture of Peer reviewers Picture of Plugin developers Picture of Testers

Hi Josh,

You say:

We have purged the site cache via command line, updated moodle (we have not moved to 4.0 yet though), added the path (it didnt exist before), and other general wisardry. Nothing has worked so far. Once we added the path back it did populate the folder for us but the error still persists.

The error suggests you have at some point upgraded your site codebase to 4.0 (the line doesn't exist at all in 3.11) and then rolled back to 3.11? Can you confirm exactly what you've done, specifically where you say "added the path", "populate the folder".

I'd suggest taking a look at the upgrade docs to ensure it goes smoothly next time.

Average of ratings: Useful (2)
In reply to Paul Holden

Re: Exception - Class 'core_reportbuilder\permission' not found

by Howard Miller -
Picture of Core developers Picture of Documentation writers Picture of Particularly helpful Moodlers Picture of Peer reviewers Picture of Plugin developers
Yeh - agree. Report builder is in Workplace and in Moodle 4.0. It's NOT in Moodle 3.11.

As you don't mention Workplace and you specifically say that you have not upgraded to Moodle 4.0, it begs the question where did that code come from?
Average of ratings: Useful (1)
In reply to Howard Miller

Re: Exception - Class 'core_reportbuilder\permission' not found

by Iago Felicio -
I have production site and the same problem happened a hour ago, removing file reportbuilder.php resolve the issue to acess admin menus but not the courses, all of them return error "Exceção - Class 'core_courseformat\output\section_renderer' not found", can someone help?

Attachment moodle error.PNG
In reply to Iago Felicio

Re: Exception - Class 'core_reportbuilder\permission' not found

by Howard Miller -
Picture of Core developers Picture of Documentation writers Picture of Particularly helpful Moodlers Picture of Peer reviewers Picture of Plugin developers
Which version of Moodle are you running?
In reply to Howard Miller

Re: Exception - Class 'core_reportbuilder\permission' not found

by Iago Felicio -
currently 4.0Dev, yes, mistakes were made in the beginning, i also do once a week backup, i restore all 'course' folder from last backup and issue was gone, a very scary situation, you guys have found the trigger that made that mess? my win server also update today and the problem start, is this relevant or just coincident?
In reply to Iago Felicio

Re: Exception - Class 'core_reportbuilder\permission' not found

by Cecilia De Leon -

Did you manage to fix this? If so, what troubleshooting have you done? I have the problem with same exact issue as yours. I can't find a concrete solution on forums and I found your post here. Please reply if you have the time. Thanks!

In reply to Cecilia De Leon

Re: Exception - Class 'core_reportbuilder\permission' not found

by Ken Task -
Picture of Particularly helpful Moodlers

@Ceclia   *CAUTION*

I sent to your direct email my finding for your site ... which was a failed Softac upgrade and old site restore to a 3.9.x by hosting tech support.

In that message, how to fix ...

Course format error
Exception - Class 'core_courseformat\output\section_renderer' not found

which is not the same as reportbuilder ... which exist in 4.0.x but not 3.9, 3.10, or 3.11.

The fix I sent applies to your server ... and may not ... repeat may NOT apply to others!

Also ... in your message to me ... a 4.0DEV version is for development ONLY ... DEV = bugs for sure!   So where ever you are running that ... think you said localhost Windows ... upgrade that to a supported version of 4 now that it has been officially release.

'SoS', Ken


In reply to Cecilia De Leon

Re: Exception - Class 'core_reportbuilder\permission' not found

by Iago Felicio -
Hello Folks,

Cecilia, Ken has far more experience than me in this case but long story short, thankfully my server has routinely backup jobs, to resolve the issue i replace all content on the 'course' from previous backup and restart webserver, fix the problem immediately.

Glad to help

Iago Felicio
In reply to Iago Felicio

Re: Exception - Class 'core_reportbuilder\permission' not found

by Ken Task -
Picture of Particularly helpful Moodlers

@Iago - glad that fixed your issue ... Cecilia had tech support where she host do an entire **site restore** - and tech support may/may not have done moodledata/filedir where ALL files uploaded to moodle are stored.  Linux server.

You:

".. to resolve the issue i replace all content on the 'course' from previous backup"

This to say simply ... one solution doesn't fit all! ... that's all! smile

 'SoS', Ken


In reply to Ken Task

Re: Exception - Class 'core_reportbuilder\permission' not found

by valentin philip -

Hello everyone,

I put Moodle 3.11.10+ on Debian 11 with VirtualBox (a virtual machine) with the LAMP requirement for Moodle 3.11.10+

At the end of the installation I have the message of Josh Wilson : 

Exception - Class 'core_reportbuilder\permission' not found

So, I follow the advice of Eric Steiner and I move the folder reportbuilder anywhere outside of the live website folder structure and I move the file moodle/admin/settings/reportbuilder.php outside of the  live website folder structure. 

After, I hat access to my new serveur moodle

But when I create my first course I have the message of Iago Felicio : 

Exception - Class 'core_courseformat\output\section_renderer' not found

I understand that the second error message is come from the first but my development skills are absolutely outmoded.

Can you help me?

Thank you very much