Conversation
Added a check to ignore "answered" events for Single Choice Set library.
|
@pjotrsavitski Good catch! Something similar would need to be implemented in other compound content types with similar behavior that use SingleChoice set. So I wonder if it would make more sense to change SingleChoice Set and either make it use a real SingleChoice subcontent or to check whether the xAPI "answered" event could be "forged" to make it look like it belongs to a subcontent. Would be more effort, but cleaner I think. Either way, nicely done - and it's not up to me to decide about the pull request. |
|
@otacke The |
|
@pjotrsavitski It's not about what's inside the event, but what instance sends it. Normally, a subcontent (SingleChoice, if that existed) would send its own statements and Column would not care. I'd have to check the content of SingleChoiceSet, but I think it bakes in some "fake" subcontent, but all xAPI statements are in fact send by SingleChoiceSet and Column cares. That can potentially be fixed. But again, that were my 2 cents only. Not more. |
|
@otacke You are correct, all the events originate from within the Single Choice Set code and Column does use a direct event listener on the instance. |
|
@pjotrsavitski Then my original comment applies :-) |
If
Single Choice Setis the only content in theColumnor it is the last one that has not been answered yet, then answering each of the questions will make thatColumnsend acompletedevent with incorrect score. This is because the check only makes sure that event has score and thusansweredxAPI event is considered suitable.The change checks for a specific library and ignores
answeredevents.