Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Change the way instructor is identified during the LTI launch to avoid a misleading log message #1381

Closed
jonespm opened this issue May 5, 2022 · 4 comments · Fixed by #1417
Assignees

Comments

@jonespm
Copy link
Member

jonespm commented May 5, 2022

During the LTI certification, there were a few tests where they were sending short, unknown, or missing roles. However, the app printed that they "must be admin".

There's nothing that would indicate that they must be admin if they're not in the roles available. We should remove this message and maybe even log it as an ERROR.

logger.info(f'User {username} does not have course membership roles, must be admin {roles}')

The Logic of the instructor check is modified for clarity and this avoids the flagged logged message


Test Plan:

  1. launch MyLA from a new course that doesn't have an entry in MyLA DB with different roles
    1. Launch the tool as TA in the course who is also an instructor in one of the course sections. He should not enable
      MyLA for the course (start the data extraction )
    2. Launch the tool as `TA only in the course. He should not enable MyLA for the course (start the data extraction )
    3. Launch the tool with an instructor in the course. He is the person who can enable MyLA for the course
    4. Launch the tool with an MyLA Admin, i.e is_staff role enabled in the auth_user table. He is the person who can
      enable MyLA for the course
    5. Launch the tool as Canvas Admin. He should not enable MyLA for the course (start the data extraction )
  2. Basically only instructor and MyLA admin (who has Django admin access) should be enabling the MyLA in the course.

This will eliminate the unnecessary log message that certification flagged.

@jonespm jonespm self-assigned this May 11, 2022
@jonespm jonespm added this to To do in MyLA-2022.01.02 via automation May 11, 2022
@jennlove-um
Copy link
Contributor

This is not something that will happen when users log in to MyLA via Canvas. This should still be reviewed and fixed as part of LTI certification.

@jennlove-um jennlove-um removed this from To do in MyLA-2022.01.02 Jun 22, 2022
@jennlove-um jennlove-um added this to To do in MyLA-2022.02.01 via automation Jun 22, 2022
@jennlove-um jennlove-um assigned pushyamig and unassigned jonespm Aug 31, 2022
@pushyamig pushyamig moved this from To do to In progress in MyLA-2022.02.01 Aug 31, 2022
@pushyamig pushyamig changed the title Remove message "must be admin" from message when checking course_user_roles Change the way instructor is identified during the LTI launch to avoid a misleading log message Sep 1, 2022
MyLA-2022.02.01 automation moved this from In progress to Review/QA Sep 1, 2022
@jennlove-um
Copy link
Contributor

Tested in beta:

  1. Launch the tool as TA in the course who is also an instructor in one of the course sections. He should not enable
    MyLA for the course (start the data extraction ) - PASSED
  2. Launch the tool as `TA only in the course. He should not enable MyLA for the course (start the data extraction ) - PASSED
  3. Launch the tool with an instructor in the course. He is the person who can enable MyLA for the course - PASSED
  4. Launch the tool with an MyLA Admin, i.e is_staff role enabled in the auth_user table. He is the person who can
    enable MyLA for the course - PASSED
  5. Launch the tool as Canvas Admin. He should not enable MyLA for the course (start the data extraction ) - PASSED

@jonespm jonespm moved this from Review/QA to Review/QA - DEV in MyLA-2022.02.01 Sep 19, 2022
@pushyamig
Copy link
Contributor

I am moving this to done, for some reason this is moved to Review/QA- Dev

@pushyamig pushyamig moved this from Review/QA - DEV to Done in MyLA-2022.02.01 Sep 19, 2022
@jennlove-um jennlove-um removed this from Done in MyLA-2022.02.01 Sep 20, 2022
@jennlove-um jennlove-um added this to To do in MyLA-2022.01.03 via automation Sep 20, 2022
@pushyamig pushyamig moved this from To do to Review/QA in MyLA-2022.01.03 Sep 20, 2022
@pushyamig pushyamig moved this from Review/QA to Review/QA - DEV in MyLA-2022.01.03 Sep 20, 2022
@pushyamig pushyamig moved this from Review/QA - DEV to Done in MyLA-2022.01.03 Sep 20, 2022
@pushyamig pushyamig moved this from Done to Review/QA in MyLA-2022.01.03 Sep 20, 2022
@jonespm jonespm moved this from Review/QA to Done in MyLA-2022.01.03 Sep 21, 2022
@jennlove-um
Copy link
Contributor

Testing passes in test environment.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
No open projects
Development

Successfully merging a pull request may close this issue.

3 participants