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

Invalid response value detected error message when searching for a course with a multilang title in Messaging

    XMLWordPrintable

    Details

    • Type: Bug
    • Status: Closed
    • Priority: Critical
    • Resolution: Fixed
    • Affects Version/s: 3.2
    • Fix Version/s: 3.2
    • Component/s: Messages
    • Labels:
    • Testing Instructions:
      Hide
      1. Enable multi lang filter for both title and content.
      2. Install more than one lang packs (assuming ar for testing instrucitons)
      3. As admin login and edit course name of a course to contain multi lang. Something like

        <span lang="en" class="multilang">Marketing 101</span><span lang="ar" class="multilang">Marketing AR 101</span>

      4. As admin goto messages>contacts>search for contact.
      5. Make sure search works and you see no errors.
      6. As student who is enrolled in atleast two courses including the multilang course from above, repeat the search test.
      7. Make sure you see the courses in the results with proper names.
      8. As that student goto usermenu>preferences>preferred language and change it to "ar"
      9. Repeat the search, make sure you get "ar" version of the course name based on your multilang text.
      10. Make sure this doesn't break any phpunit or behat tests.
      Show
      Enable multi lang filter for both title and content. Install more than one lang packs (assuming ar for testing instrucitons) As admin login and edit course name of a course to contain multi lang. Something like <span lang="en" class="multilang">Marketing 101</span><span lang="ar" class="multilang">Marketing AR 101</span> As admin goto messages>contacts>search for contact. Make sure search works and you see no errors. As student who is enrolled in atleast two courses including the multilang course from above, repeat the search test. Make sure you see the courses in the results with proper names. As that student goto usermenu>preferences>preferred language and change it to "ar" Repeat the search, make sure you get "ar" version of the course name based on your multilang text. Make sure this doesn't break any phpunit or behat tests.
    • Affected Branches:
      MOODLE_32_STABLE
    • Fixed Branches:
      MOODLE_32_STABLE
    • Pull Master Branch:
      MDL-56656-master

      Description

      I edited the M101 course on the prototype site for messaging and put in some multilang content in the Course Full Name, e.g.

      <span lang="en" class="multilang">Marketing 101</span><span lang="fr" class="multilang">MarketingFR 101</span>

      When I went back to the messaging, clicked the 'Contacts' tab and done a search I was shown the error below:

      Invalid response value detected
      File:
      .../lib/externallib.php
      Line:
      424
      Stack trace:

      courses => Invalid response value detected: fullname => Invalid response value detected: Invalid external api response: the value is "<span lang="en" class="multilang">Marketing 101</span><span lang="fr" class="multilang">MarketingFR 101</span>", the server was expecting "notags" typeError code: invalidresponse

        Attachments

          Activity

            People

            Assignee:
            ankit_frenz Ankit Agarwal
            Reporter:
            craig@moodle.com Craig R Morton
            Peer reviewer:
            Frédéric Massart
            Integrator:
            Dan Poltawski
            Tester:
            Jake Dallimore
            Participants:
            Component watchers:
            Amaia Anabitarte, Carlos Escobedo, Ferran Recio, Sara Arjona (@sarjona), Víctor Déniz Falcón
            Votes:
            0 Vote for this issue
            Watchers:
            4 Start watching this issue

              Dates

              Created:
              Updated:
              Resolved:
              Fix Release Date:
              5/Dec/16