Bugfix: Text Input problem type expects numeric answer when correct answer starts with a number - #19510
Conversation
|
Thanks for the pull request, @dmitry-viskov! I've created OSPR-2930 to keep track of it in JIRA, where we prioritize reviews. Please note that it may take us up to several weeks or months to complete a review and merge your PR. Feel free to add as much of the following information to the ticket:
All technical communication about the code itself will be done via the GitHub pull request interface. As a reminder, our process documentation is here. Please let us know once your PR is ready for our review and all tests are green. |
|
@dmitry-viskov This is great, thank you for your contribution. Please let me know once it is ready to be reviewed. |
cc8bcb9 to
069f430
Compare
…nswer starts with a number
069f430 to
a30a53a
Compare
|
@natabene hi. it is already ready for review. jenkins quality issues are not mine |
|
@edx/testeng Could you help us out with jenkins/quality test here? |
|
@dmitry-viskov - I checked out the quality failures, and you are right- the build failed because you edited a file containing preexisting xsscommit-lint failures. The issue of running into older xss lint issues was recently discussed on another pull request: https://github.com/edx/edx-platform/pull/19385#issuecomment-448678120. From the PR: |
|
@dmitry-viskov Got it, I will queue it for engineering review, though might take a while due to holidays. |
|
@edx/educator-admins Can you have a look when you have a chance? |
schenedx
left a comment
There was a problem hiding this comment.
I do prefer you can fix the linting issue identified by our quality check. Do you have a strong a reason not to do so?
| checkIsNumeric = function(stringValue) { | ||
| // remove OLX feedback | ||
| if ((stringValue.indexOf('{{') !== -1) && (stringValue.indexOf('}}') !== -1)) { | ||
| stringValue = stringValue.replace(/{{[\s\S]*?}}/g, '').trim(); |
There was a problem hiding this comment.
Can you add some comment on what this replace is meant to do? Is it trying to remove all white space from this string?
There was a problem hiding this comment.
= 3.14159 +- .02 {{ Pie for everyone! }}
->
= 3.14159 +- .02
@schenedx sorry but i'm not going to fix your internal issues |
|
jenkins run quality |
|
Your PR has finished running tests. The following contexts failed:
|
|
@robrap I need your help here. |
|
@schenedx: Happy to look on Monday with you. We can determine effort of fixing or commenting, or allow merge with it broken. |
schenedx
left a comment
There was a problem hiding this comment.
Upon review, I believe the code change here looks good. 👍
The xss-lint failures have nothing to do with this code change. We will merge this in as it is.
|
@schenedx Great, thanks! Please merge when you are ready to do so - OSPR contributors don't have permissions to merge. |
|
@dmitry-viskov 🎉 Your pull request was merged! Please take a moment to answer a two question survey so we can improve your experience in the future. |
|
EdX Release Notice: This PR has been deployed to the staging environment in preparation for a release to production on Tuesday, February 26, 2019. |
|
EdX Release Notice: This PR has been deployed to the production environment. |
Example:
Because the correct answer option (= 100 test) is a string that begins with the number, edX is treating the problem as though it requires a number answer, rather than a text string that can include letters and numbers. If the user enters an answer with text instead of just numbers, an error message that says "Error, couldn't parse formula" appears.