maths / moodle-qtype_stack

Stack question type for Moodle
GNU General Public License v3.0
138 stars 147 forks source link

Yet another validation display bug: Fractions as factors #1183

Closed daniil-berg closed 1 month ago

daniil-berg commented 1 month ago

Similar to #1106. Since I have no insight into what causes this, I don't know if this has been resolved by e94139c4d777fb9692574c6b6784a08c8d04ec63. If so, I apologize for the duplicate and instead ask whether we can expect a release that includes this patch soon since it was committed back in early January.

Say we are for example dealing with complex numbers and the correct answer to a question would be (3/2)i. If you enter that or (3/2)*i or 3/2i, validation produces similar TeX gibberish to this:

if unknown then sconcat("\\left(",tex1(3/2),"\\right)") else (if atom(3/2) or is(length(args(a)) = 1) or safe_op(3/2) = "^" then tex1(3/2) else sconcat("\\left(",tex1(3/2),"\\right)"))\, \mathrm{i}

The answer still seems to be understood correctly. Just the validation output is nonsense.

If you want, I can send you the offending question as XML.

We are on Moodle 4.3.4 and STACK 4.5.0.

sangwinc commented 1 month ago

Yes, this is a duplicate report of an issue we have fixed. Sorry about this. Chris