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

List of licenses is not displayed in the user's preferred language

    XMLWordPrintable

    Details

    • Testing Instructions:
      Hide
      1. Log in as the site admin.
      2. Go to Site administration > Language > Language packs.
      3. Install an additional language pack of your choice (any one that has at least some of the licenses translated will do).
      4. Select the newly installed language as the current language.
      5. Go to Site administration > Plugins > Caching > Configuration.
      6. Purge the "List of licences" cache.
      7. Go to Site administration > Licence > Licence manager.
      8. TEST The list of licenses should appear in your currently selected language.
      9. Switch the current language back to English.
      10. TEST The list of licenses should appear in English now.
      Show
      Log in as the site admin. Go to Site administration > Language > Language packs. Install an additional language pack of your choice (any one that has at least some of the licenses translated will do). Select the newly installed language as the current language. Go to Site administration > Plugins > Caching > Configuration. Purge the "List of licences" cache. Go to Site administration > Licence > Licence manager. TEST The list of licenses should appear in your currently selected language. Switch the current language back to English. TEST The list of licenses should appear in English now.
    • Affected Branches:
      MOODLE_310_STABLE, MOODLE_39_STABLE, MOODLE_400_STABLE
    • Fixed Branches:
      MOODLE_39_STABLE
    • Pull from Repository:
    • Pull 3.9 Branch:
      MDL-69698-39-licensecache
    • Pull 3.10 Branch:
      MDL-69698-310-licensecache
    • Pull Master Branch:
      MDL-69698-master-licensecache

      Description

      This was originally reported as an MDLSITE issue affecting moodle.org:

      When uploading a new plugin version the 'Choose licence' language is not the language of the user.

      See:

      During the triage, it was confirmed and detected that this is actually an MDL core bug.

      In the license_manager::get_licenses() caching was introduced as a part of MDL-45184. The list of all licenses is being cached in MUC, including the localised full name of license. So depending on user's current language (the lucky one who initialised the cache rebuilt), the cache is populated in that language and then displayed as such to everybody.

      We must not cache the localised full names, only the short names.

        Attachments

          Issue Links

            Activity

              People

              Assignee:
              mudrd8mz David Mudrák (@mudrd8mz)
              Reporter:
              gb2048 Gareth J Barnard
              Peer reviewer:
              Víctor Déniz Falcón
              Integrator:
              Eloy Lafuente (stronk7)
              Tester:
              Eloy Lafuente (stronk7)
              Participants:
              Component watchers:
              David Mudrák (@mudrd8mz), Helen Foster, Víctor Déniz Falcón, Amaia Anabitarte, Carlos Escobedo, Ferran Recio, Sara Arjona (@sarjona), Barbara Ramiro, Bas Brands
              Votes:
              0 Vote for this issue
              Watchers:
              6 Start watching this issue

                Dates

                Created:
                Updated:
                Resolved:
                Fix Release Date:
                9/Nov/20

                  Time Tracking

                  Estimated:
                  Original Estimate - Not Specified
                  Not Specified
                  Remaining:
                  Remaining Estimate - 0 minutes
                  0m
                  Logged:
                  Time Spent - 2 hours, 40 minutes
                  2h 40m