Skip to content

Cohorts should be back to "Created manually" after the plugin is uninstalled #149

Description

@dmitriim

Currently if you uninstall the plugin you have to run SQL update cohorts that were managed by the plugin so they are managed manually. This should be done as plugin uninstall script. Should we also release the members?

Error on the cohorts management page after the plugin is uninstalled:

Whoops\Exception\ErrorException thrown with message "Invalid get_string() identifier: 'pluginname' or component 'tool_dynamic_cohorts'. Perhaps you are missing $string['pluginname'] = ''; in /lang/en/tool_dynamic_cohorts.php?"

Stacktrace:
#17 debugging in /var/www/mdl82521/public/lib/classes/string_manager_standard.php:355
#16 core_string_manager_standard:get_string in /var/www/mdl82521/public/lib/moodlelib.php:7012
#15 get_string in /var/www/mdl82521/public/cohort/classes/reportbuilder/local/entities/cohort.php:229
#14 core_cohort\reportbuilder\local\entities\cohort:core_cohort\reportbuilder\local\entities\{closure} in /var/www/mdl82521/public/reportbuilder/classes/local/report/column.php:733
#13 core_reportbuilder\local\report\column:format_value in /var/www/mdl82521/public/reportbuilder/classes/table/system_report_table.php:235
#12 core_reportbuilder\table\system_report_table:core_reportbuilder\table\{closure} in [internal]:0
#11 array_walk in /var/www/mdl82521/public/reportbuilder/classes/table/system_report_table.php:233
#10 core_reportbuilder\table\system_report_table:format_row in /var/www/mdl82521/public/lib/table/classes/sql_table.php:84
#9 core_table\sql_table:build_table in /var/www/mdl82521/public/lib/table/classes/sql_table.php:227
#8 core_table\sql_table:out in /var/www/mdl82521/public/reportbuilder/classes/output/renderer.php:58
#7 core_reportbuilder\output\renderer:render_system_report_table in /var/www/mdl82521/public/lib/classes/output/plugin_renderer_base.php:78
#6 core\output\plugin_renderer_base:render in /var/www/mdl82521/public/reportbuilder/classes/external/system_report_exporter.php:143
#5 core_reportbuilder\external\system_report_exporter:get_other_values in /var/www/mdl82521/public/lib/classes/external/exporter.php:121
#4 core\external\exporter:export in /var/www/mdl82521/public/reportbuilder/classes/output/system_report.php:72
#3 core_reportbuilder\output\system_report:export_for_template in /var/www/mdl82521/public/reportbuilder/classes/output/renderer.php:45
#2 core_reportbuilder\output\renderer:render_system_report in /var/www/mdl82521/public/lib/classes/output/plugin_renderer_base.php:78
#1 core\output\plugin_renderer_base:render in /var/www/mdl82521/public/reportbuilder/classes/system_report.php:295
#0 core_reportbuilder\system_report:output in /var/www/mdl82521/public/cohort/index.php:118
Image

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    bugSomething isn't workingenhancementNew feature or request

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions