Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fatal error while opening courses in Snap theme #285

Open
amita435 opened this issue Oct 9, 2024 · 2 comments
Open

Fatal error while opening courses in Snap theme #285

amita435 opened this issue Oct 9, 2024 · 2 comments

Comments

@amita435
Copy link

amita435 commented Oct 9, 2024

Fatal error: Declaration of theme_snap\output\core\course_renderer::course_section_cm_completion($course, &$completioninfo, cm_info $mod, $displayoptions = []) must be compatible with core_course_renderer::course_section_cm_completion() in /var/www/moodle_1click/theme/snap/classes/output/core/course_renderer.php on line 29

The error comes while debugging.

Please help. New to Moodle.

@EdTechSavvy
Copy link

I am having the same problem with Snap theme PHP 8.1 Moodle version 4.3.

Snap is using a method (core_course_renderer::course_section_cm_completion) that has been removed from core Moodle in 4.3+
From Moodle documentation:

=== 4.3 ===

  • The core_course_renderer::course_section_cm_completion method has been removed, and can no longer be used
  • External function core_course_external::get_course_contents() now returns a new field activitybadge with the data to display
    the activity badge when the module implements it.
  • prepare_new_moduleinfo_data() now accepts a parameter "suffix" that will be added to the name of the completion rules.
  • The method core_course_bulk_activity_completion_renderer:: edit_default_completion() has been deprecated and will be removed.
  • The core_course\output\activity_information output class has been deprecated. Use core_course\output\activity_completion
    and core_course\output\activity_dates instead.

Alongside with that, the following methods have been deprecated too:

  • core_course_renderer::render_activity_information()
  • renderer_base::activity_information()

@lvidgen
Copy link

lvidgen commented Dec 8, 2024

Yes, this is broken and needs to be fixed by the dev team. Snap 4.3 will not work with Moodle 4.3 as reported in Issue 284. The latest working Moodle version that you can use this theme with is Moodle 4.1

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants