Details

    • Type: Sub-task Sub-task
    • Status: Closed
    • Priority: Minor Minor
    • Resolution: Fixed
    • Affects Version/s: 2.2
    • Fix Version/s: 2.2
    • Component/s: Enrolments
    • Labels:
    • Rank:
      18318

      Description

      add -v verbose option to enrol/database/cli_sync.php

        Issue Links

          Activity

          Hide
          Petr Škoda added a comment -

          Please note I have fixed one extra bug here: when creating external course the idnumber was required which is a bug, I did not want to create a separate issue because it would not merge, instead I will create a separate backporting issue for stable.

          Show
          Petr Škoda added a comment - Please note I have fixed one extra bug here: when creating external course the idnumber was required which is a bug, I did not want to create a separate issue because it would not merge, instead I will create a separate backporting issue for stable.
          Hide
          Eloy Lafuente (stronk7) added a comment -

          Silly question for this... in the case that we decide to match by idnumber... shouldn't it be mandatory? Perhaps it's being checked already, note I've not looked the whole sync_enrolments(), just the condition used here and in MDL-29022 seems to ignore that case.

          Show
          Eloy Lafuente (stronk7) added a comment - Silly question for this... in the case that we decide to match by idnumber... shouldn't it be mandatory? Perhaps it's being checked already, note I've not looked the whole sync_enrolments(), just the condition used here and in MDL-29022 seems to ignore that case.
          Hide
          Petr Škoda added a comment -

          The user sync and course sync is independent, we do not need the idnumber in external course even if it is later user in user sync.

          Show
          Petr Škoda added a comment - The user sync and course sync is independent, we do not need the idnumber in external course even if it is later user in user sync.
          Hide
          Eloy Lafuente (stronk7) added a comment -

          Yes but if you create courses without idnumber (only short/full names are mandatory) and later you try to make user sync by idnumber... nothing will match, isn't it? Surely I'm wrong, just I concluded that in my review.

          Just say "ignore" and I'll integrate these two, lol.

          Show
          Eloy Lafuente (stronk7) added a comment - Yes but if you create courses without idnumber (only short/full names are mandatory) and later you try to make user sync by idnumber... nothing will match, isn't it? Surely I'm wrong, just I concluded that in my review. Just say "ignore" and I'll integrate these two, lol.
          Hide
          Petr Škoda added a comment -

          yes, but the two parts are completely separate - it is bug in external data and moodle will work fine with that because for course sync we use shortname for identification of the course, not the idnumber.

          Show
          Petr Škoda added a comment - yes, but the two parts are completely separate - it is bug in external data and moodle will work fine with that because for course sync we use shortname for identification of the course, not the idnumber.
          Hide
          Eloy Lafuente (stronk7) added a comment -

          Integrated, thanks!

          Show
          Eloy Lafuente (stronk7) added a comment - Integrated, thanks!
          Hide
          Aparup Banerjee added a comment -

          This seems to work for me.

          setup incorrect:-

          Error while communicating with external enrolment database

          semi incorrect config output:-

          Starting course synchronisation...
          Error reading data from the external course table
          Starting user enrolment synchronisation...
          ...user enrolment synchronisation finished.

          correct config output:-

          Starting course synchronisation...
            creating course: 13, external_course_full, ext sht A, a4wgr, 1
            creating course: 14, extenrla course B, ext B, 3344d, 1
            creating course: 15, ext fullname C, extC, 4r4rw, 1
          ...course synchronisation finished.
          Starting user enrolment synchronisation...
          ...user enrolment synchronisation finished.
          Show
          Aparup Banerjee added a comment - This seems to work for me. setup incorrect:- Error while communicating with external enrolment database semi incorrect config output:- Starting course synchronisation... Error reading data from the external course table Starting user enrolment synchronisation... ...user enrolment synchronisation finished. correct config output:- Starting course synchronisation... creating course: 13, external_course_full, ext sht A, a4wgr, 1 creating course: 14, extenrla course B, ext B, 3344d, 1 creating course: 15, ext fullname C, extC, 4r4rw, 1 ...course synchronisation finished. Starting user enrolment synchronisation... ...user enrolment synchronisation finished.
          Hide
          Eloy Lafuente (stronk7) added a comment -

          Many thanks for the hard work, this has been sent upstream and is available in all the git and cvs repositories.

          Show
          Eloy Lafuente (stronk7) added a comment - Many thanks for the hard work, this has been sent upstream and is available in all the git and cvs repositories.

            People

            • Votes:
              0 Vote for this issue
              Watchers:
              1 Start watching this issue

              Dates

              • Created:
                Updated:
                Resolved: