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

Placements foundation follow up 1

XMLWordPrintable

    • 1
    • Team Alpha - Planning I2-2025, Team Alpha - Sprint 1 I2-2025

      This issue captures a few minor aspects of the placements API which need improving. Namely:

      1. We're not checking whether the plugintype (and, by extension, the plugin) is deprecated when loading the placement types into core during upgrade. In fact, I accidentally used a deprecated component in the test and it was still passing!
        • Cause: Not all methods in core_component are restricted during plugin deprecation, and we're using one of the ones that WILL return deprecated plugins (\core\component::get_component_directory).
        • Solution: Add a check and skip deprecated plugins during this loading process + test coverage.
      2. We're not checking the component portion of the placement type string matches a real component in placements_manager::is_valid_placement_type_string.
        • Cause: we use a simple regex right now.
        • Solution: Let's preg split this and validate the component portion properly + test coverage.
        • Bonus: Let's validate that the owning component (the component advertising the placement type) matches the prefix.

            jaked Jake Dallimore
            jaked Jake Dallimore
            Andrew Gosali Andrew Gosali
            Votes:
            0 Vote for this issue
            Watchers:
            2 Start watching this issue

              Created:
              Updated:
              Resolved:

                Estimated:
                Original Estimate - 0 minutes
                0m
                Remaining:
                Remaining Estimate - 0 minutes
                0m
                Logged:
                Time Spent - 3 hours, 57 minutes
                3h 57m

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