Installation

Strange LTI behavior (Moodle-WeBWorK via LTI)

Strange LTI behavior (Moodle-WeBWorK via LTI)

by Bernd Sing -
Number of replies: 4

Hi!

Since upgrade to WeBWorK 2.16, I experience a strange behavior when using WeBWorK from Moodle via LTI):
Using a Gateway Quiz works as expected (so, I can navigate between questions, the timer is running, it gets graded etc.).
Using a Homework Set (no matter if the user is a student or professor in WeBWorK), immediately after following the link in Moodle, the WeBWorK page loads in an iFrame inside Moodle and shows that the user is logged into WeBWorK (and the list of problems is shown, as expected). However, then clicking any link in WeBWorK logs the user out of WeBWorK and shows the login page for that course prompting the user to enter username and password (the latter of which the user does not have).

I suspect that I am overlooking some configuration here, but nothing I tried has helped so far. Any help/hints/suggestions would be greatly appreciated.

In reply to Bernd Sing

Re: Strange LTI behavior (Moodle-WeBWorK via LTI)

by Bernd Sing -
Finally found what I was overlooking all the time:
Under Session Management in localOverrides.conf the line containing
$session_management_via = "key";
was commented out; uncommenting it resolved the issue.

Hope this can also help somebody else.


In reply to Bernd Sing

Re: Strange LTI behavior (Moodle-WeBWorK via LTI)

by Danny Glin -

See this thread as well.  In the long run, cookies will be better supported in WeBWorK for session management than keys.  For now, there are still some complications regarding third party cookies and browsers that block them.

In reply to Danny Glin

Re: Strange LTI behavior (Moodle-WeBWorK via LTI)

by Bernd Sing -
Indeed, as discussed in issue https://github.com/openwebwork/webwork2/issues/1473 -- which can be found in that thread -- setting the External Tool (LTI) in Moodle to open in a new window allows to set 
$session_management_via = "session_cookie";
respectively leave the line with that variable commented out. Only if WeBWorK opens embedded in Moodle, that issue occurs for homework sets.

Thanks Danny.
In reply to Bernd Sing

Re: Strange LTI behavior (Moodle-WeBWorK via LTI)

by L Ng -
yeah.. embedding seems to create problems.. i just use open in new window instead