Coder Social home page Coder Social logo

adapt-contrib-assessment's People

Contributors

akshay-bhavsar avatar andrewhosgood avatar brian-learningpool avatar cahirodoherty-learningpool avatar cajones avatar chris-steele avatar chucklorenz avatar dancgray avatar danielghost avatar darylhedley avatar dependabot[bot] avatar eleanor-heath avatar guywillis avatar jamesrea83 avatar joe-allen-89 avatar joe-replin avatar kunjsharma avatar lc-thomasberger avatar moloko avatar olaoluwam avatar oliverfoster avatar olivermartinfoster avatar raspberrypiclass avatar ryan-lynch avatar ryanrolds avatar sarveshwar-gavhane avatar semantic-release-bot avatar taylortom avatar tomgreenfield avatar zenduo avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

adapt-contrib-assessment's Issues

language constants

Subject of the issue/enhancement/features

Hi!
I want to translate the interface into Ukrainian and do not understand how to do it. I'm not a programmer, but I can edit the translation file. :) Please help me. Where do I add language and language constants?

Your environment

  • version (AT/Framework)
  • which browser and its version
  • device(s) + operating system(s)

Steps to reproduce

Tell us how to reproduce this issue.

Expected behaviour

Tell us what should happen

Actual behaviour

Tell us what happens instead

Screenshots (if you can)

Add events on important methods

  • Assessment needs to trigger events when something meaningful happens to keep in line with Adapt's event system
  • Should be done like so:
Adapt.trigger('assessment:score', this.model.get('_score'));

Some might also be prefixed with the plugin name if it is something that is not a global event but is significant enough.

Retry option in the assessment

Currently if you fail an assessment, there isn't an option to reset the assessment to try again. It's included in the dummy feedback pop-up in the framework demo but there isnt a way to actually retry from my investigations?

assessment restoration/completion

Subject of the issue/enhancement/features

It is possible to return to an assessment which has rendered a results component without any feedback.

This seems to be because the assessment is not setting _isAssessmentComplete: true when all questions have been answered but trickle hasn't yet been clicked. Without clicking the trickle button, the block is not set to complete and therefore the assessment doesn't update the saved state.

Your environment

  • Adapt framework: 5.18.6

Steps to reproduce

  • Assessment must be set to "_isResetOnRevisit": false. Trickle needs to configured with the button enabled.
  • Complete all questions. Exit before clicking the trickle button on final question.
  • Relaunch and access the assessment. You can scroll down to the results, but no feedback is rendered as the relevant events have not been triggered.

Authoring tool compatibility

_quizBankID attribute should be within an _assessment object.

Extensions attributes are usually held within an object named after the extension. e.g

"_assessment": {
"_postTotalScoreToLms": true,
"_isPercentageBased": true,
"_scoreToPass": 75,
"_requireAssessmentPassed": true
}

_quizBankID are specific to assessment plugin but are placed directly within the blocks in the readme and example.json.

They should be in an _assessment object within blocks.json.

assessmentUpgrade: suggestions

Hi Ollie,

Please see below for the points discussed:

1 Remove _uniqueQuestions from example JSON (as this is expected behaviour)
2 _banks.randomizeBankQuestionOrder > something less specific like _banks._randomisation
3 Set _randomisation to false in example JSON as per suggestion to not have both enabled at same time
4 _questions._isResetOnRevisit > _questions._resetType
5 _isReloadPageOnReset > _reloadPageOnReset and then remove from example JSON anyway for now
6 Accept “_attempts”: “infinite” instead of just “attempts”: 0
7 Avoid forcing to populate course.json with an assessment object, especially if only a single assessment – read from article instead. Ollie: not currently specified in readme
8 On assessment object in course.json, postScoreToLMS >_postTotalScoreToLms
9 Will probably need to change all from …LMS to …Lms to match convention
10 Remove global _isEnabled from _retry object in assessmentResults, use only versions in bands
11 ~~_bands._isRetryEnabled > something like _bands._allowRetry ? ~~
12 Please consider getting rid of _completionMessage altogether and using displayTitle and body because this causes confusion, especially if displayTitle/body is empty Ollie: Using the component body and switching it out with the _completeionBody on assessment completion

Cheers,

Tom Greenfield

Issue with randomised blocks

Description
The half width components are doubled up when leaving the course/ refreshing a course page.

Steps to replicate

  1. Make an assessment with 100% pass mark set:
  2. Add a course with a multiple choice question component
  3. Add a few items to the component
  4. Make this a half width component
  5. Copy this component and add it to the right of the first component
  6. Add the spoor extension
  7. Download the course and upload it to an LMS
  8. Preview the page
  9. Refresh the page

AttemptsSpent is doubling

Looks like when I have 4 attempts for an assessment instead of infinity. Each time it uses up 2 attempts when I complete the assessment. My thinking is the problem is to do with the _onBlockCompleted & _this._checkAssessmentComplete(); is being dublicated also by _onQuestionCompleted...

_onBlockCompleted(blockModel, value) {
if (value === false) return;
const questionModels = blockModel.findDescendantModels('question');
questionModels.forEach(questionModel => {
this._onQuestionCompleted(questionModel, value);
});
if (!blockModel.get('_isInteractionComplete')) return;
_this.checkAssessmentComplete();
},

_onQuestionCompleted(questionModel, value) {
if (value === false) return;
if (!questionModel.get('_isInteractionComplete')) return;

let numberOfQuestionsAnswered = this.get('_numberOfQuestionsAnswered');
numberOfQuestionsAnswered++;
this.set('_numberOfQuestionsAnswered', numberOfQuestionsAnswered);

this._updateQuestionsState();
Adapt.assessment.saveState();

this._checkAssessmentComplete();

},

assessments restored event triggered too early

Subject of the issue

The assessment:restored event will be triggered with the registration of the first assessment. The state sent with the event may therefore be incorrect if a course has more than one assessment.

Failed to restore banked assessment with xAPI

I had a course with an assessment that uses question banks (AT: 0.10.5, FW: 5.18.4).

It worked as it should when I used SPOOR but when I switched to xAPI, there seemed to be a problem:
If I return to a passed assessment in a new session, it no longer shows as completed in the menu.

I made a miniature course to isolate the issue.
It has just one page with an assessment with 6 questions in 3 banks (two questions in each bank).
My split is "1,1,1".

When I return to the course in a new session after passing the assessment, the assessment article is not completed, even if the question components and their blocks are completed (or this is at least how it looks when I use the course map in the Kineo Developer Tools).

After some investigation, the problem seems to be that when restoring the completion status of the assessment article, it considers all 6 questions in the article - not just the ones that were drawn.
This causes the assessment article to be set as incomplete, as the remaining 3 questions are all incomplete.

When using the SPOOR/scorm extension, it seems to restore the assessment status with regards to the questions drawn.

I am using the adapt-contrib-xapi version 0.9.5.

setRestoreState obliterates article model children

This occurs when a course has mutliple assessments. To replicate, complete one assessment, reload course and note that model children of incomplete assessments are gone. Will PR fix after this issue created.

Model collection reset

Due to an issue in the way Backbone removes models which are no longer included (https://backbonejs.org/docs/backbone.html#section-149) it is possible for models to erroneously be removed by other extensions which manipulate getChildren() collections following an assessment reset (e.g. https://github.com/adaptlearning/adapt-contrib-branching/blob/master/js/BranchingSet.js#L316).

This can be resolved by setting a collections models via the Backbone Collection.reset method, rather than directly on the property. The following lines should be adjusted:
https://github.com/adaptlearning/adapt-contrib-assessment/blob/master/js/adapt-assessmentArticleModel.js#L157
https://github.com/adaptlearning/adapt-contrib-assessment/blob/master/js/adapt-assessmentArticleModel.js#L172
https://github.com/adaptlearning/adapt-contrib-assessment/blob/master/js/adapt-assessmentArticleModel.js#L688

Trickle issue with reset assessment

Subject of the issue

Trickle adds its models after the assessment is initialised, therefore when an assessment restores its original block models upon resetting, it can exclude a laterly configured trickle button.

Trickle models are injected into blocks and articles at adapt:start, from adaptlearning/adapt-contrib-trickle#197
https://github.com/adaptlearning/adapt-contrib-trickle/blob/82a1c23f24f6508d6ed8c0a65e23ddb11ae9d8ad/js/controller.js#L29-L40

Assessment keeps its article's original children at the model init processes, before trickle has added its children.

this._originalChildModels = this.getChildren().models;

Assessment then restores its article's original children when it is reset, removing any subsequently added trickle button.
this.getChildren().reset(this._originalChildModels);

Assessment Banks with Trickle Not Unlocking Next Article

Subject of the issue/enhancement/features

Assessment with banks and trickle enabled does not unlock next section after assessment completion.

Your environment

  • framework 5.34.0/trickle 7.1.1/assessment 5.1.10/vanilla
  • chrome
  • macOS

Steps to reproduce

Create a course with an assessment and banks and trickle enabled.
Create an article below it.
Complete assessment.
Next article does not unlock.
Returning to menu and then returning to the page does show trickled content however.

Expected behaviour

The second article should untrickle and unlock after the assessment is completed.

Actual behaviour

The article does not unlock.

Screenshots (if you can)

chrome-capture-2024-2-27

Assessment banks not used

I updated my test Adapt AT server (AT: v0.10.5, FW: v5.18.5) with the new v4.6.0 "adapt-contrib-assessment" extension.

The course I tested is just a page with one article with an assessment having 7 MCQ questions.

  • The questions are assigned to 3 banks (with 3, 2, and 2 questions).
  • The draw is done using this split: "1,1,1".

But with the new assessment version, I get all 7 questions every time.

I noticed this when I did a little debugging:

  • In the assessment model, the "_setupAssessmentData" function the "shouldResetAssessment" variable is always false, which in turn means that the "_setupBankedAssessment" function is never called.
  • "shouldResetAssessment" is false because "shouldResetOnRevisit" is false, "state.isPass" is undefined, "hasAttemptsLeft" is false, and "force" is undefined.

I would have expected the "_setupBankedAssessment" function to be called on the first visit.

When updating the version of the assessment extension the assessmentResults component stops working

When updating the extension via authoring tools to version 4.5.4 or 4.5.5 the assessmentResult component always shows 0% in the result. When I switch to version 4.2.1 of the extension, the component works correctly.

Doing tests manually we have seen that it starts to fail from version 4.4.0

Adapt authoring version: 0.10.5
adapt-contrib-assessment-4.4.0
adapt-contrib-assessmentResults-4.3.1

Captura de pantalla 2022-02-11 131437

In the capture you can see the variables that we use.

Does not restore non-block children

Any injected non-block component in the article children will be removed when an assessment is restored as the assessment concentrates only on restoring the previous attempt blocks.

Question banks should warn when being used incorrectly

Subject of the issue/enhancement/features

Currently questions will be reused inside a bank if the desired count is greater than that available. A console message should warn about this error.

Your environment

  • FW v5.22.2
  • All browsers
  • All devices

Steps to reproduce

Create a course with an assessment that uses question banks
Set a bank to display 3 but only have 2 blocks/components

Expected behaviour

2 questions should be printed
Console warning to help debug

Actual behaviour

2 questions and a repeat are printed
No explanation of why

assessment always reset when used with branching

With branching the blocks and questions are set to _isAvailable: false and are never used in the assessment, their clones are used instead but aren't available when the assessment is restored.

This causes some older code to assume the assessment should be reset.

let wereQuestionsRestored = true;
const questions = this.get('_questions');
for (const question of questions) {
const questionModel = Adapt.findById(question._id);
if (!questionModel.get('_isSubmitted')) {
wereQuestionsRestored = false;
break;
}
}
if (!wereQuestionsRestored) {
this.set('_assessmentCompleteInSession', true);
return true;
}

This code should have an _isAvailable: true check to stop it from trying to check unavailable questions.

assessment overrides `_canShowFeedback` and `_canShowModelAnswer` even if not set

If you leave these two properties out of the assessment article config, assessmentArticleModel still attempts to set them on every question, which has the effect of forcing _canShowFeedback to false and _canShowModelAnswer to true.

The behaviour should be the same as if you leave out _canShowMarking i.e. the setting for each question is used instead.

assessments "soft" reset

When an assessment is set to use a "soft" reset on its question models, the assessment and assessments models both reset their completion properties, but the _assessmentState saved in https://github.com/adaptlearning/adapt-contrib-core/blob/aacbc90cc7eeedaea649270303a695c9fc7f45a0/js/tracking.js retains the completion for use in its completion checks. However, if a course contains multiple assessments, and one is "soft" reset before the other is completed, the tracking will not have saved the _assessmentState to be used later, meaning any reset assessment needs to be retaken.

When "Allow retry once passed" option enabled in assessment, "Retry assessment" stops working in the assessmentResults component

Subject of the issue/enhancement/features

When "Allow retry once passed" option enabled in assessment, "Retry assessment" stops working in the assessmentResults component

Your environment

  • version Framework: 5.36.2

Steps to reproduce

Open the course in the Authoring tool
2) Update the Assessment settings for the article in the Questions page
3) Force rebuild the course
4) Open the Question page
5) Answer all questions correct
6) Go to the Assessment results page
7) Check that results are displayed
8) Click the Retry Assessment button

Expected behaviour

When “Allow retry once passed” is enabled, clicking the “Retry assessment” button in the results component should return to the page and reset all the questions. When it is enabled alongside “Reset on Revisit” all the questions should also reset when leaving and returning to the page (once the assessment has already been completed)

Actual behaviour

When “Allow retry once passed” is enabled, the “Retry Assessment” button stops working, so there is no way to actually reset the questions.
When enabled alongside “Reset on Revisit” the questions do reset when leaving and returning to the page after completing all questions, however, the Assessment Results component never registers the assessment as complete.

Screenshots (if you can)

image

screen-capture.mp4

Add start event

Subject of the issue

There is no clear event for assessment start, we have preReset, reset, postReset, restored and complete.

Assessment Data Sanity Check

Subject of the issue/enhancement/features

Prefacing this by saying this issue was not spotted in the core assessment plug-in. This issue presented itself after adding complexity to the base assessment with distributed assessments, assessment banks, SCORM & xAPI etc. It was a rare occurrence, but still locked learners out of the course. @chris-steele added this logic but I believe it could be beneficial to the base plug-in as we expand upon various new types of assessments in the future.

The proposal is to add a simple sanity check for bad data and correct it if present.

Your environment

  • FW v5.19.6
  • Assessment v5.0.2
  • All OSs; All Browsers

Steps to reproduce

You wouldn't be able to reproduce in the core assessment. For example, our Adapt course had learners with low broadband connection as well as a distributed assessment & various banks of assessments. SCORM & xAPI was also added to this project so that contributed to slightly longer load times.

  1. Ensure your course is currently SCORM-enabled on an LMS.
  2. Before having another attempt at an assessment, throttle your network speeds with browser devtools
  3. Upon selecting 'Retry Assessment', close the course while the loading screen is present
  4. Even under these circumstances, it may take several times to reproduce.

Expected behaviour

Upon retry, if a learner's connection to the LMS, the assessment should still:

  • reload with suspend data relative to the SCORM data currently committed to the LMS

Actual behaviour

Upon retry, if a learner's connection to the LMS severed at the most opportune moment, the assessment would:

  • reload again with every question still submitted.
  • have an assessment model status of still being 'in progress'.
  • present no opportunity to retry again. The assessment results would inform you only to complete the above assessment (see screenshot)

Screenshots (if you can)

image

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.