Skip to content
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

Same peer explanation appears more than once #149

Closed
kitsook opened this issue Jun 13, 2018 · 0 comments · Fixed by #168
Closed

Same peer explanation appears more than once #149

kitsook opened this issue Jun 13, 2018 · 0 comments · Fixed by #168
Assignees
Milestone

Comments

@kitsook
Copy link
Contributor

kitsook commented Jun 13, 2018

When the "Answers Students See - Number Selected" options is set to be bigger than number of answers, same peer explanation may appear more than once in Step 2.

Need to check the answer pool logic.

Edit: it happens when the selection logic is Simple

ubcpi/ubcpi/answer_pool.py

Lines 252 to 260 in ff69bbb

i = 0
while (student == student_id or i > 100) and (str(option) + student) not in selected:
# retry until we got a different one or after 100 retries
# we are suppose to get a different student answer or a seeded one in a few tries
# as we have at least one seeded answer for each option in the algo. And it is not
# suppose to overflow i order to break the loop
student = random.choice(students.keys())
i += 1
selected.append(str(option)+student)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
1 participant