moodle-qtype_coderunner
moodle-qtype_coderunner copied to clipboard
Plugin is not updated
Hello. The plugin qtype_coderunner version 4.2.3 (2022022300) is installed on my site. When I try to update it to version 5.0.0 (2022082201), I get a message "There is a request to install plugin CodeRunner (qtype_coderunner) version 2022082201 from the Moodle plugins directory on this site. However, this plugin is already installed on the site." and the update does not happen.
I don't understand this either. When logged in as an administrator, do you see any pending updates under Site administration > Notifications?
It might be worth rebooting your server?
No. There are no site updates and no plugins updates when logged in as an administrator. The server has rebooted.
I'd like to understand the situation before making any further suggestions.
- What version do you see under Site administration > Manage plugins > CodeRunner (paste a screen dump perhaps)?
- What version do you see in
/question/type/coderunner/version.php? - What's the recent upgrade history - how did you upgrade Moodle and what steps have you taken to upgrade CodeRunner?
Site administration > Manage plugins > CodeRunner: CodeRunner qtype_coderunner 4.2.3 2022022300
File /question/type/coderunner/version.php: $plugin->version = 2022022300; $plugin->requires = 2019111800; $plugin->cron = 0; $plugin->component = 'qtype_coderunner'; $plugin->maturity = MATURITY_STABLE; $plugin->release = '4.2.3';
$plugin->dependencies = array( 'qbehaviour_adaptive_adapted_for_coderunner' => 2021112300 );
I update the system usually like this: $ cd /var/www/html/moodle/ $ sudo -u www-data php admin/cli/maintenance.php --enable $ sudo git pull $ sudo -u www-data php admin/cli/upgrade.php $ sudo -u www-data php admin/cli/maintenance.php --disable
and update plugins: $ sudo chown -R www-data:www-data /var/www/html/moodle/ $ #update in web site $ sudo chown -R root:root /var/www/html/moodle/ $ sudo chmod -R 0755 /var/www/html/moodle/ $ sudo chown www-data /var/www/html/moodle/admin/cli/cron.php
Firstly, can you confirm please that you did initially install CodeRunner from the plugins repository rather than from GitHub directly, and that you are running Moodle 4.0. If you're not running Moodle 4.0 you MUST NOT install CodeRunner 5.0, as it doesn't work with earlier versions of Moodle.
If you are running Moodle 4.0 and you installed CodeRunner from the Moodle plugins repository, please read on ...
I just checked the Moodle source code and you get the message "This plugin is already installed" if the code files for the plugin are present regardless of version. This seems like a confusing error message to me.
Next, can you click the Check for updates button on the Site administration > Plugins > Plugins overview page. Do you get told there is an update available for CodeRunner (with an Update button to click)? If so click the button. If not, I'm puzzled. If you're running Moodle 4.0 should should be seeing such a button, although it's possible that Moodle isn't offering you the update because the version in the repo is marked Release candidate rather than Stable. Please confirm.
If the above fails, then it looks to me like you could probably get the plugin install to proceed simply by moving the question/type/coderunner directory sideways (out of Moodle altogether) and then retrying the install. As always, you should back up your server before trying this.
If even that fails, post back and I'll explain how to install from github. But I'd prefer people to be working from the official Plugins repository.
Yes, I initially install CodeRunner from the plugins repository and use Moodle 4.0. There is no plugin update: Site administration > Plugins > Plugins overview. I renamed the directory question/type/coderunner. Then the site updated the database. The plugin has become marked disabled. And I was able to install it again. Now it's version 5.0. Coderunner is working now. Thanks!
Closed as problem appears to have been solved.