-
Notifications
You must be signed in to change notification settings - Fork 732
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
Survey modality #9000
Survey modality #9000
Conversation
fixes to current try overview spec remove unused in attemptloglist spec
28c25e8
to
a39eaba
Compare
and some lint
a39eaba
to
3a3084b
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Spotted 1 potential regression in code review. Have not manually tested yet.
}, | ||
computed: { | ||
...mapGetters(['currentUserId']), | ||
// QUESTION: Why? Wouldn't anything else fail validation? Why not just call tryValidator here? |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Validators don't run in production, only in development. This value can still be undefined, so we need to handle that case. Could swap it out for tryValidator
instead, which might be more robust.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
If the component defines a prop as required and validates it then I think it should be able to operate under the assumption that it won't be used incorrectly. The parent component should (and I think in all/most cases do - can confirm in a bit) guard rendering CurrentTryOverview w/ v-if
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I don't disagree - but it's not how Vue handles it, so better to be defensive, I think.
@@ -171,7 +175,9 @@ | |||
return this.currentTryDefined && !isUndefined(this.currentTry.correct); | |||
}, | |||
score() { | |||
return this.currentTryDefined ? this.currentTry.correct / this.totalQuestions : 0; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Have lost the division here in the small refactor.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Will update the test scenario to be more robust thank you!
@@ -403,6 +421,7 @@ | |||
return; | |||
} | |||
this.loading = true; | |||
console.log(this.getParams()); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Spare console.log
Hi @radinamatic and @nucleogenesis, I tried testing this PR with all of the Buildkite builds plus directly from the nucleogenesis:survey-modality branch but I am not able to see any of the changes. |
@pcenov and @nucleogenesis -- I'm running into a similar problem after having updated an exercise to the SURVEY modality while trying to do some manual QA after a code read through this morning (which looks good!). One thing I did notice as I was troubleshooting is that Modalities.SURVEY coming from |
@nucleogenesis looks like you updated the version of |
kolibri/plugins/learn/assets/src/views/CompletionModal/index.vue
Outdated
Show resolved
Hide resolved
kolibri/plugins/learn/assets/src/views/QuizRenderer/QuizReport.vue
Outdated
Show resolved
Hide resolved
kolibri/plugins/learn/assets/src/views/CompletionModal/index.vue
Outdated
Show resolved
Hide resolved
Tested running from source (@pcenov please re-test with DEB and EXE assets), and seeing various issues in Firefox on Linux.
There is also a bit of weirdness in displaying the question area when changing browsing width, and hint appearance seems to be affecting the width of the paragraph (shifting may be affecting readability), but those could be issues with the channel/ricecooker, and not this PR.
|
In addition to the issues observed by @radinamatic I've reported separately the following issues: #9020, #9021, #9022, #9023 |
…t button was hidden
The following fixes have been pushed here:
I could not replicate the issue where the first question stopped working when accessed through the QA channel because I cannot upgrade my channel. I'll see if I can get it working later on. |
330edf5
to
b7e9b4e
Compare
|
kolibri/plugins/perseus_viewer/assets/src/views/PerseusRendererIndex.vue
Outdated
Show resolved
Hide resolved
b7e9b4e
to
b2d2e57
Compare
Tooltips are not hints. There's nothing that should be stopping the tooltips from appearing, so this is expected behaviour.
Users can take surveys anonymously - I'd say this is intended behaviour for now (even if potentially undesirable in some contexts). |
The error looks like an issue with loading the next question inside Perseus - so it is probably being passed a question identifier that does not exist inside the perseus file. |
Ok, since we decided this is not a blocker, let's merge this in! 👍🏽 |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Manual QA cleared up, good to go! 🎉
Summary
Introduces Survey modality support by adding some display logic based on whether the content is a Survey or not.
It's not super complex logic there in CurrentTryOverview, but I wanted to be sure it was covered and started writing tests for the bits I was going to change and I figured that since I was there I should cover all of the props and display logic.
survey.mp4
References
Figma
Reviewer guidance
I tried to make the video cover everything so you don't have to do all this but I think it'd be good if someone spun this up.
Setup
options: { modality: SURVEY }
value. I do this in SQLite Browser, but you can probably do it in the Kolibri Shell getting the content node by id, updating it'sextra_fields
JSON accordingly.Actually testing
Testing checklist
PR process
Reviewer checklist
yarn
andpip
)