Uploaded image for project: 'Sakai'
  1. Sakai
  2. SAK-44137

Rationalize the Auto-generated Line Items for LTI Advantage Launch and AGS

    XMLWordPrintable

    Details

    • 20 status:
      Resolved
    • Property addition/change required:
      Yes
    • Test Plan:
      Hide

      OK - Here goes.  Make a site with at least Lessons and a Grade book.  Set up an LTI Advantage security arrangement (i.e. with sakai.tsugicloud.org) if you don't already have one.

      Go into Lessons.  Add Learning App and pick Trophy.  As part of installation, ask to create a line item.  Set the score maximum to "123" and the resource id and tag to some string.  After linking it in - look in the grade book to verify a new entry with a max score of 123.   The dates won't will be ignored for links in Lessons.

      Then log in as student, go to lessons and launch the tool - look through the JWT for a line that looks like:

      "lineitem":"http://localhost:8080/imsblis/lti13/lineitems/191..e0a:::1b47..c27:::content:136/119"

      Find the "lineitem" (singular) entry in the JWT and verify that there is an integer at the end after the slash.

      Then add a student to the site and launch the link.  Again verify the syntax of the lineitem.  Trophy will send back a 0.95 grade automatically.  Check the gradebook and the score should be 116.85 as it was expanded to a max points of 123 (SAK-44180).

      Then go back as instructor and add the LMS Test tool.  Do not configure the lineitem. 

      Go back to the student account and launch LMSTest.  The lineitem should not have a number suffix and should look like:

      lineitem":"http://localhost:8080/imsblis/lti13/lineitem/e3a...9:::ead...59f:::content:141"

      This is the legacy lineitem that we hope tools won't use. 

      Proceed with the launch and list the line items - there should only be one (Trophy) and its url should have the number suffix. Use interact and send a score of 500 and scoreMaximum of 1000 and a comment of something.  Go into the gradebook and the score should be 61.5 - again scaled to the max of the column of 123 - and the comment should be there.

      Go back as admin, add another copy of Trophy but set the title to Trophy 2.  Do not configure the line item at all.  Go to the student and launch Trophy 2.  Then check the gradebook the score should be 0.95 / 1.

      Then add a Content Item source aimed at:

      https://www.tsugi.org/lti-test/tool.php

      12345 / secret

      Then add an LTI 1.1 link to lessons using Content Item. 

      Go to the student, and launch the Awesome Sakaiger link.  Check out the launch data - there should be a lis_result_sourcedid - then continue the launch.  Test the outcome service and send a 0.75 grade back and send a comment.  Check the grade book and you should see 82.5 /110 because the scaling happened.

       

       

       

       

      Show
      OK - Here goes.  Make a site with at least Lessons and a Grade book.  Set up an LTI Advantage security arrangement (i.e. with sakai.tsugicloud.org) if you don't already have one. Go into Lessons.  Add Learning App and pick Trophy.  As part of installation, ask to create a line item.  Set the score maximum to "123" and the resource id and tag to some string.  After linking it in - look in the grade book to verify a new entry with a max score of 123.   The dates won't will be ignored for links in Lessons. Then log in as student, go to lessons and launch the tool - look through the JWT for a line that looks like: "lineitem":"http://localhost:8080/imsblis/lti13/lineitems/191..e0a:::1b47..c27:::content:136/119" Find the "lineitem" (singular) entry in the JWT and verify that there is an integer at the end after the slash. Then add a student to the site and launch the link.  Again verify the syntax of the lineitem.  Trophy will send back a 0.95 grade automatically.  Check the gradebook and the score should be 116.85 as it was expanded to a max points of 123 ( SAK-44180 ). Then go back as instructor and add the LMS Test tool.  Do not configure the lineitem.  Go back to the student account and launch LMSTest.  The lineitem should not have a number suffix and should look like: lineitem":"http://localhost:8080/imsblis/lti13/lineitem/e3a...9:::ead...59f:::content:141" This is the legacy lineitem that we hope tools won't use.  Proceed with the launch and list the line items - there should only be one (Trophy) and its url should have the number suffix. Use interact and send a score of 500 and scoreMaximum of 1000 and a comment of something.  Go into the gradebook and the score should be 61.5 - again scaled to the max of the column of 123 - and the comment should be there. Go back as admin, add another copy of Trophy but set the title to Trophy 2.  Do not configure the line item at all.  Go to the student and launch Trophy 2.  Then check the gradebook the score should be 0.95 / 1. Then add a Content Item source aimed at: https://www.tsugi.org/lti-test/tool.php 12345 / secret Then add an LTI 1.1 link to lessons using Content Item.  Go to the student, and launch the Awesome Sakaiger link.  Check out the launch data - there should be a lis_result_sourcedid - then continue the launch.  Test the outcome service and send a 0.75 grade back and send a comment.  Check the grade book and you should see 82.5 /110 because the scaling happened.        

      Description

      The first hint of this bug/issue bug was reported from Martin and Karen at TurnitIn.  Originally filed as "Put to LineItem Fails" (see text attachment for original report).  But Andrea also saw some issues in her Sakai-21 LTI testing after SAK-43890 was completed.  They are connected and need to be fixed together:

      (1) A PUT to update the data on some lineitem urls fails while it works for other lineitem urls

      (2) when you retrieve all the line items for a tool, sometimes grade book columns appear more than once with different lineitem URLs.

      These issues were introduced when Sakai suported two lineitem formats in an attempt to mimic the old LTI 1.1 auto-creation of line items that use the title of the resource link.  Also in Sakai-20 it ignored the "create lineitem" request in the deep link response (SAK-43890) - so we depended on the auto-creation of gradebook columns based on the receipt of the first score.  This of course meant that things like max-score were wrong as the "autocreate" always set the max score to 100 or 1.0 depending on the scenario.

      With SAK-43890 completed, Sakai now properly handles the "create line item" feature in Deep Link returns.

      The problem (1) for GradeScope is that the LTI 1.1 style auto creation URLs did not support altering things like the label, etc - so those PUTs failed.

      The source of the lineitems appearing more than once (2) was when the tool asked for all of its line items, Sakai returned all the line items that were created by the tool through the calls to AGS and Deep Link responses and then also added the "auto-create" lineitem for each of the resource links for the tool in the site.  So you almost always got two different lineitem urls for the same grade book column.

      In addition, in the year since LTI Advantage came out there was surprisingly little effort given to giving a smooth LTI 1.1 -> LTI Advantage migration path for existing links.  So nearly all LMS's made a bit of a clean break of it and eliminated the LTI 1.1 style for providing lineitem when the tool did not request a lineitem through the Deep Link response or the AGS service.  Their feeling was that LTI Advantage had sufficient features for explicit provisioning of grade columns, that there was no need to "implicitly" provision a grade column.

      Sakai felt very strongly that a smooth transition of existing LTI 1.1 links to LTI Advantage was an important feature and fully supported it.  But since no one other LMS bothered to support this, tools approached LTI Advantage as a fresh problem to solve and did not depend on LTI 1.1 like features hidden in LTI Advantage.

       Solution

      The AGS service will never send the "autocreate line items" back when the line items are requested.  Tools will only sees line items created via Deep Link Response or an AGS Create LineItem call.

      If a tool sets up a content link with a deep link response that includes a line item section, when that link is launched, the lineitem value will be the auto-created line item.  It will show up in AGS lists, and you can do all operations on that line item.

      If an LTI Advantage content  link in Sakai is created without explicitly asking for a lineitem, when that link is launched, Sakai will provide an "auto-create" line item - but this line item does not support any function except score and result.  PUT will not be supported.   Tools should not depend on this behavior and the preferred behavior is to either request a line item in the Deep Link Response or create their own lineitem using AGS.  If they create their own line item in AGS and the label matches the title of the content link - it will be given to them as the lineitem for the launch - but once the tool takes over managing its own line items it should retain those values and not use the auto-provision "lineitem" value from launch.

      Tools should avoid depending on the auto-create score/result only URL - this might be removed from a future version of Sakai.   But for Sakai 20 and 21 the behavior will be the same.

      This introduces a new property:

      lti.advantage.construct.lineitem=true

      The default is true, which is to construct an auto-provision lineitem url if the tool has not created their own line item for the content item.   Perhaps in Sakai-22 or later this should switch to false.  But since this code is intending to fix both Sakai-20 and Sakai-21 the legacy behavior needs to continue to work. This property should not be changed lightly - it could negatively affect existing LTI Advantage integrations.  It is present in case IMS issues a new best practice that says that the "lineitem" claim should only be included if explicitly requested by the tool via a deep link response.

       

       

       

       

        Gliffy Diagrams

          Zeplin

            Attachments

              Issue Links

                Activity

                  People

                  Assignee:
                  csev Charles Severance
                  Reporter:
                  csev Charles Severance
                  Votes:
                  1 Vote for this issue
                  Watchers:
                  4 Start watching this issue

                    Dates

                    Created:
                    Updated:
                    Resolved:

                      Git Integration