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

LTI v1.3 Tool: A+ should not create LTI grade items if the Platform has disabled it #1252

Open
markkuriekkinen opened this issue Sep 5, 2023 · 0 comments
Labels
area: LTI LTI protocol (Learning Tools Interoperability, worldwide standard) effort: hours Estimated to take less than one day, from the creation of a new branch to the merging experience: beginner required knowledge estimate requester: team The issue is raised by a person inside the A+ developer team type: bug This is a bug

Comments

@markkuriekkinen
Copy link
Contributor

If the LTI Platform (Moodle) defines in its LTI activity settings that no grades should be received from the LTI Tool, then A+ as the Tool should not (try to) create any grade items to the Platform.

For example, when a course is selected via LTI Deep Link, A+ does not check if the grades are enabled in the LTI settings:

a-plus/lti_tool/views.py

Lines 254 to 264 in a932c51

def post(self, request, *args, **kwargs):
# Create gradebook items
ags = self.message_launch.get_ags()
lineitems = ags.get_lineitems()
exercises = BaseExercise.objects.filter(course_module__course_instance=self.instance)
for e in exercises:
lineitem_exists = bool([li for li in lineitems if li['tag'] == str(e.id)])
if e.max_points > 0 and not lineitem_exists:
li = LineItem()
li.set_tag(str(e.id)).set_score_maximum(e.max_points).set_label(pick_localized(str(e), 'en'))
ags.find_or_create_lineitem(li)

https://github.com/dmitry-viskov/pylti1.3#assignments-and-grades-service
Methods like

# ability to create new line item
ags.can_create_lineitem()
@markkuriekkinen markkuriekkinen added area: LTI LTI protocol (Learning Tools Interoperability, worldwide standard) type: bug This is a bug effort: hours Estimated to take less than one day, from the creation of a new branch to the merging experience: beginner required knowledge estimate requester: team The issue is raised by a person inside the A+ developer team labels Sep 5, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
area: LTI LTI protocol (Learning Tools Interoperability, worldwide standard) effort: hours Estimated to take less than one day, from the creation of a new branch to the merging experience: beginner required knowledge estimate requester: team The issue is raised by a person inside the A+ developer team type: bug This is a bug
Projects
Status: Todo
Development

No branches or pull requests

1 participant