memphis-iis / mofacts

8 stars 1 forks source link

skipstudy not working #1366

Closed imrryr closed 10 months ago

imrryr commented 10 months ago

this wasn't working.... no option showed, enter and space bar did not move forward.

"unit": [ { "unitinstructions": "Unit 1 Prequiz.", "buttonorder": "random", "deliveryparams": { "drill": "12000000", "purestudy": "16000", "skipstudy": "true", "reviewstudy": "12000000", "correctprompt": "5000", "fontsize": "4", "correctscore": "0", "incorrectscore": "0" },

JRustyHaner commented 10 months ago

@imrryr for which lesson?

JRustyHaner commented 10 months ago

@imrryr also, skipstudy only skips study stimuli. Tests, or drills, which all multiple choice units are categorized as, are considered assessments, not studies.

imrryr commented 10 months ago

The primary function of skip study was originally to skip the study portion of drills. But logically it should also skip studies alone, like you say, but that is not what its main goal was. A drill includes an assessment, but when it is a failure it also becomes a study.

imrryr commented 10 months ago

I assume the problem is for all cases, but this is the tdf not working. unit1.zip

JRustyHaner commented 10 months ago

@imrryr This has been deployed to staging server as branch iss1366. When merged, staging branch will be redeployed to staging server

imrryr commented 10 months ago

@JRustyHaner It is now showing the "skipstudy" during the test portion. This was only for the study portion of the drill, this is a bug now. Also, on the study screen (where the button is supposed to appear) it does not do anything, and appears to be not active. So there are essentially 2 bugs.

JRustyHaner commented 10 months ago

@imrryr in that particular tdf, Unit 1, the only unit is considered a drill by the engine. There are no study questions in that tdf. All of them return type 'd' for drill. We can have the skip button appear by testtype.

The types are labeled 'd', 'm','n', 'i', 's', 'f', and 't'. According to the code, study types are 's' and 'f'. The button appeared previously for type s and type f.

imrryr commented 10 months ago

I'm not sure how I am being unclear. We need to not have the skip button appear during the test portion of the drill.... drills have two halves when you get it incorrect; the button only occurs in the second half when incorrect, which is a review study. FYI f was the old code for a forward drill. I believe this is how it worked (only on the study half), but regardless, it may have always been wrong and just never tested. Please can we make it right, which is to only have the button when the drill has been gotten incorrect and the review study is being presented. I think of the review study as a subtype of study, so it makes sense to me to have skip study work for both cases (drill review study and pure study).

JRustyHaner commented 10 months ago

@imrryr You aren;t being unclear... the code is. That actually helped. The code wasn't actually well documented there, and theres still some cleanup.

imrryr commented 10 months ago

The purpose of the skip study button is to make sure that the unit allows people to skip past all passive practice (study trials). So we only want it when there is passive practice on the screen. @JRustyHaner

Currently, in the prequiz, I just want to allow them to look at the review as long as they want if they get drills wrong. So I set the reviewstudy to a very high value, which means they need the skip study button to move forward.

JRustyHaner commented 10 months ago

@imrryr I understand and have a solution. There wasn't really a way to differentiate if a user was in the drill or study potion of those questions. It seems like this wasn't implemented well.

imrryr commented 10 months ago

Yes, communication is much better now. We can improve the code as we have time. You could make issues for problem spots.

JRustyHaner commented 10 months ago

@imrryr I am building now. In the original implementation, the skipstudy button simulated a wrong answer for a drill's question. I'm sure that's not what you intended. It now will have the user answer as [skip] like the timeout returns [timeout] as the answer. This answer is still considered incorrect, by the way, and the feedback timeout was still occurring. In this solution the feedback still occurs, but the timer is 1 millisecond, so it shouldn't even render. I'm sure there's a better way to handle it.

JRustyHaner commented 10 months ago

@imrryr the comment immediately above doesnt effect your unit 1 tdf,by the way. I just thought it was odd. The feedback is now skippable when skipstudy is enabled in drills.

imrryr commented 10 months ago

"It now will have the user answer as [skip] like the timeout returns [timeout] as the answer. This answer is still considered incorrect, by the way, and the feedback timeout was still occurring."

I don't understand this at all unfortunately. The drill behavior (depending on the drill timer) should not be changed. It should still say timeout as normal, since the skip study is not relevant to that part of the trial.... The skip study ONLY effects the trial after the response has been given AND it is incorrect. It should not effect the initial portion of drills or the correct feedback.

Can we talk on the phone?

imrryr commented 10 months ago

Now I get a button for the correct result, which shouldn't use the skipstudy, since there isn't a "study" per se

Also, it seems to be using the "reviewstudy" timer for the "correctprompt" event

MoFaCTS - Google Chrome 1_17_2024 1_23_59 PM

JRustyHaner commented 10 months ago

@imrryr the last deploy should have fixed the skip button appearing on correct answers. Although with the timeout that high, it might become a problem where correct responses cannot continue because of timeout and no continue button.

imrryr commented 10 months ago

You seem to have noticed the problem, but you ignored the second bug. I did say --> "Also, it seems to be using the "reviewstudy" timer for the "correctprompt" event".

@JRustyHaner Somehow, you switched the timer for the correctprompt timer to be the reviewstudy timer, that was a new bug. I reported it yesterday. The whole system is non-functional with the timer set to the wrong value, since the correctprompt timer is always much shorter for normal operations.

JRustyHaner commented 10 months ago

@imrryr that is an unrelated problem. The review timeout is being set to 0.001 when feedback is skipped to get it moving along. However, if it is correct, the review timeout is being set to 100000 when the correct response is given. This is no change from previous code that was written in June 2021 by Andrew.

imrryr commented 10 months ago

Well, so you say skipstudy is breaking the mechanism for correctprompt timing? Due to some hack that was introduced in June2021? So you understand how to fix it? Correctprompt should not be affected by skipstudy, which only affects the study portion of the drill. @JRustyHaner

JRustyHaner commented 10 months ago

@imrryr The function to get the timeout duration for reviews is called twice for some reason. The first time the isCorrect value is true or false, the second time it is undefined. The second time, with isCorrect being undefined, returns the duration for incorrect answers, regardless if the answer was correct.

imrryr commented 10 months ago

Huh, that's messed up. Thanks for coping with it. If it would help you, I'd be happy to meet on Zoom and have you talk more about it. It's up to you. @JRustyHaner

JRustyHaner commented 10 months ago

@imrryr Well... I have that fixed. That function was being passed through several other functions with .bind() which makes sense, but it takes a while to debug. It's like peeling an onion. The duration of the reviews is accurate when i tested them locally. 5 seconds for correct, and a long time for incorrect.