-
Notifications
You must be signed in to change notification settings - Fork 147
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
Coding error detected, it must be fixed by a programmer: Inconsistent placeholders. Possibly due to multi-lang filtter not being active. #939
Comments
Sorry you're having problems. This error is generated here: Given you say the question is big, you might have exceeded the practical system limits. You won't be the first person to write truly huge questions which can't be evaluated, but I think the problem is more likely to be authoring problems with your tags. I'm 99% confident this error is caused by a question authoring problem. This forum is really for bugs in the software itself, so until we can identify a clear bug in the STACK code (not your use of STACK) I'm proposing to close this issue. Chris |
Hmm, @sangwinc usually I would totally agree with anyone who said that there's a mistake in the code as I'm not an accomplished coder by any means. But in this case, something else might seems to be going on. Might still be very much my mistake, but it's not the code in the question. I imported it onto the demo server and it's fine there. In short, on my live server, it is not rendering, but on the demo server it is. |
Well... Yelling help helps no one without some context. Did anything happen during the hours when things stopped working? Did someone update your Moodle, your STACK or something else related to them? And you really need to specify what, if anything, you are doing with languages when the error message is pointing towards multi-lang. Is that filter active or not (maybe someone turned it off), and are there language things present in the question? Were those things present before things broke and now missing due to some editing errors? Were these questions authored in the system where they do not work, does that system have the same version of STACK etc... Did you move the questions between courses or other contexts that might have different filter settings? Do note that the "code" you posted is worthless here, as it is in no way related to the error. That error comes from the text content and happens typically when one has multiple copies of the same placeholder present due to duplicates not being eliminated through conditional rendering or language variant elimination when duplicates are seen it is indeed a coding error or maybe someone messed up the filters doing that elimination. Are there multiple copies of To figure anything out the whole question with all the bits is necessary, and if you can upload those questions into that "ed.ac.uk" Moodle, then Chris can probably see those questions, but you need to help people helping you by at least giving links to the questions and giving some context. If STACK has not been updated, you did not edit the questions between the time they worked and stopped working, and there are languages in play, I would bet on someone messing up with the Moodle filters. That or some editing mistakes with a tidying editor that has broken the multi-lang tags, or maybe some tidying filter above multi-lang... |
Sorry for the yelling. I'm not a programmer, somewhere between a user and a noob. When my questions stop working in the middle of a course for no apparent reason, I cry. I was trying to figure out how to share the code/question more effectively, but couldn't see how. |
Do note that filter settings are tunable at course/context level, so if you are able to create quizzes, you should also be able to tune filters. Although not their order which is one of the things that a site admin can mess up. But first, try to talk to your local systems people as questions do not simply fail without the system changing and it seems odd that anyone would update systems "in the middle of a course". Did something change, with version updates, filter settings, or Maxima installations? Also did someone transfer those questions around as files and if so does that person know how to work with those files and not open and save them with random tools? |
Ok. So assuming that this is the same issue we have just diagnosed, this was indeed a filter issue but not an issue related to languages in any way. Those filters managed to change the placeholders, and STACK became quite confused when it saw that the set of placeholders after filtering was inconsistent with what was just detected before it. For those that may see that error in their own operations, this is what happened this time:
Now, how to deal with this:
Naturally, we will try to find a way to become immune to this effect, but it may be quite difficult as we do like to support filters in general and targeting this or any others is not that easy. |
Some of my questions just broke with the warning: "Coding error detected, it must be fixed by a programmer: Inconsistent placeholders. Possibly due to multi-lang filtter not being active." I can save it fine, but it wont generate variants anymore.
I wasn't using another language but weirder to me is that the questions worked fine a few hours ago. They are BIG but since I'm not quite ready yet for being responsible for variant-sharing across questions, I had to bang a whole Z-test into one question.
There could be coding errors, but I played around with it loads a few hours and go and it was generating test variants quite happily.
Here is the code for what it's worth. I've played around with decreasing the randomisation, but no luck. Played around with the drop down menues (ta1/2), nothing changed.
nr: rand(100)+50000;
min_weight: 55 + rand(4);
sig_lev: rand([0.01,0.05,0.1]);
samp_mean: min_weight-(2+rand(20))*0.1;
std_dev: rand(9)*0.1+4;
samp_size: rand(10)+60;
std_err: std_dev / sqrt(samp_size);
p_value: cdf_normal(samp_mean,min_weight,std_err);
tal1: [[a,false],[b,true],[c,false],[d,false]];
ta1:b;
tal1b: [[a,false],[b,false],[c,true],[d,false]];
ta1b:c;
ta2: sig_lev;
ta3: samp_mean;
ta4: std_dev;
ta5: samp_size;
ta6: dispdp(std_err,5)
ta7: dispdp(p_value,5);
if sig_lev > p_value then (ss:1) else (ss:2);
tal8:["reject", "not reject"];
ta8: tal8[ss];
tal9:["yes","no"];
ta9: tal9[ss];
The text was updated successfully, but these errors were encountered: