Uploaded image for project: 'Moodle'
  1. Moodle
  2. MDL-84107

Remove mlbackend_php plugin from core

XMLWordPrintable

    • MOODLE_500_STABLE
    • MOODLE_500_STABLE
    • MDL-84107-main
    • Hide

      Cover by PHPUnit. Manual testing as below

      Initial setup

      1. Run

        docker run -d -p 5000:5000 --name=mlbackendpython --rm --add-host=mlbackendpython:0.0.0.0 moodlehq/moodle-mlbackend-python:3.0.5-python3.7.5 

      1. Log in as an admin and go to Site administration > Plugins > Machine Learning backend settings > Python machine learning backend.
      2. Tick 'Use a server', set 'Host' to 'mlbackendpython', 'localhost' or '127.0.0.1', the field 'Port' to 5000 and the field 'Password' to 'sshhhh' and save changes.

       

      Test 1

      1. Checkout to the previous weekly release.
      2. Install the Moodle instance.
      3. Log in as admin
      4. Go to Site admin -> Analytics -> Analytics models
      5. Create a new model that explicitly uses the 'PHP machine learning backend'
      6. Inspect the database table called 'analytics_models' and ensure you have an entry in there with '\mlbackend_php\processor' set as the 'predictionsprocessor'
      7. Checkout the latest main branch and perform the upgrade
      8. CONFIRM that mlbackend_php is removed in the upgrade process
      9. Inspect the 'analytics_models' table again
      10. CONFIRM there are no entries with '\mlbackend_php\processor'
      11. Go to Site admin -> Advanced features
      12. CONFIRM that 'Analytics' is disabled

      Test 2 (upgrade with mlbackend_php present)

      1. Checkout to the previous weekly release.
      2. Install the Moodle instance.
      3. Checkout to the latest main branch.
      4. Start the upgrade process, but pause when you see the 'Plugin check' screen. It will warn you about mlbackend_php being missing from the disk.
      5. In your Moodle root, clone the mlbackened_php repo

        git clone https://github.com/moodlehq/moodle-mlbackend_php.git lib/mlbackend/php

      6. Go back to the 'Plugin check' screen and continue upgrading Moodle.
      7. Go to Site admin -> Advanced features
      8. CONFIRM that Analytics is still enabled
      9. Go to Site admin -> Analytics -> Analytics models
      10.  CONFIRM that 'PHP machine learning backend' is selected for 'Default predictions processor'

       

      Show
      Cover by PHPUnit. Manual testing as below Initial setup Run docker run -d -p 5000 : 5000 --name=mlbackendpython --rm --add-host=mlbackendpython: 0.0 . 0.0 moodlehq/moodle-mlbackend-python: 3.0 . 5 -python3. 7.5 Log in as an admin and go to Site administration > Plugins > Machine Learning backend settings > Python machine learning backend. Tick 'Use a server', set 'Host' to 'mlbackendpython', 'localhost' or '127.0.0.1', the field 'Port' to 5000 and the field 'Password' to 'sshhhh' and save changes.   Test 1 Checkout to the previous weekly release. Install the Moodle instance. Log in as admin Go to Site admin -> Analytics -> Analytics models Create a new model that explicitly uses the 'PHP machine learning backend' Inspect the database table called 'analytics_models' and ensure you have an entry in there with '\mlbackend_php\processor' set as the 'predictionsprocessor' Checkout the latest main branch and perform the upgrade CONFIRM that mlbackend_php is removed in the upgrade process Inspect the 'analytics_models' table again CONFIRM there are no entries with '\mlbackend_php\processor' Go to Site admin -> Advanced features CONFIRM that 'Analytics' is disabled Test 2 (upgrade with mlbackend_php present) Checkout to the previous weekly release. Install the Moodle instance. Checkout to the latest main branch. Start the upgrade process, but pause when you see the 'Plugin check' screen. It will warn you about mlbackend_php being missing from the disk. In your Moodle root, clone the mlbackened_php repo git clone https: //github.com/moodlehq/moodle-mlbackend_php.git lib/mlbackend/php Go back to the 'Plugin check' screen and continue upgrading Moodle. Go to Site admin -> Advanced features CONFIRM that Analytics is still enabled Go to Site admin ->   Analytics -> Analytics models   CONFIRM that 'PHP machine learning backend' is selected for 'Default predictions processor'  
    • Hide

      Code verified against automated checks.

      Checked MDL-84107 using repository: https://github.com/davewoloszyn/moodle.git

      More information about this report

      Built on: Thu Feb 13 05:26:14 AM UTC 2025

      Show
      Code verified against automated checks. Checked MDL-84107 using repository: https://github.com/davewoloszyn/moodle.git main (0 errors / 0 warnings) [branch: MDL-84107-main | CI Job ] More information about this report Built on: Thu Feb 13 05:26:14 AM UTC 2025
    • Show
      Launching automatic jobs for branch MDL-84107 -main https://ci.moodle.org/view/Testing/job/DEV.02%20-%20Developer-requested%20PHPUnit/18428/ PHPUnit (sqlsrv) https://ci.moodle.org/view/Testing/job/DEV.01%20-%20Developer-requested%20Behat/63142/ Behat (NonJS - boost and classic) https://ci.moodle.org/view/Testing/job/DEV.01%20-%20Developer-requested%20Behat/63143/ Behat (Firefox - boost) https://ci.moodle.org/view/Testing/job/DEV.01%20-%20Developer-requested%20Behat/63144/ Behat (Firefox - classic) https://ci.moodle.org/view/Testing/job/DEV.01%20-%20Developer-requested%20Behat/63131/ App tests (stable app version) --> MDL-84744 Built on: Mon Feb 10 04:30:16 AM UTC 2025
    • 2
    • Team Hedgehogs 2025 Sprint 1.1, Team Hedgehogs 2025 Sprint 1.2

      The phpml library that this plugin depends on has been abandoned. We do not have the resources to maintain this library so we're instead looking at moving the plugin out of core and into the plugins database.

      In reality I doubt that this is widely used, though sadly I don't believe we have any stats on usage of it.

        1. (1) 10 Passed -- (Main)MDL-84107.png
          62 kB
          Kim Jared Lucas
        2. (1) 12 Passed -- (Main)MDL-84107.png
          109 kB
          Kim Jared Lucas
        3. (1) 8 Passed -- (Main)MDL-84107.png
          46 kB
          Kim Jared Lucas
        4. (2) 10 Passed -- (Main)MDL-84107.png
          54 kB
          Kim Jared Lucas
        5. (2) 8 Passed -- (Main)MDL-84107.png
          107 kB
          Kim Jared Lucas
        6. 2025-03-16 , 16_37_04 - Plugins overview _ Plugins _ Administration _ M5dev — Mozilla Firefox.png
          70 kB
          Przemek Kaszubski
        7. Screen Shot 2025-02-03 at 4.32.34 pm.png
          107 kB
          David Woloszyn

            david.woloszyn@moodle.com David Woloszyn
            dobedobedoh Andrew Lyons
            Stevani Andolo Stevani Andolo
            Huong Nguyen Huong Nguyen
            Kim Jared Lucas Kim Jared Lucas
            Votes:
            1 Vote for this issue
            Watchers:
            13 Start watching this issue

              Created:
              Updated:
              Resolved:

                Estimated:
                Original Estimate - 0 minutes
                0m
                Remaining:
                Remaining Estimate - 0 minutes
                0m
                Logged:
                Time Spent - 3 days, 6 hours, 58 minutes
                3d 6h 58m

                  Error rendering 'clockify-timesheets-time-tracking-reports:timer-sidebar'. Please contact your Jira administrators.