Skip to content

List a shared answer once in the Match and Associate response pools - #6330

Open
rtibblesbot wants to merge 3 commits into
learningequality:unstablefrom
rtibblesbot:issue-6324-32b178
Open

rtibblesbot wants to merge 3 commits into
learningequality:unstablefrom
rtibblesbot:issue-6324-32b178

Conversation

@rtibblesbot

@rtibblesbot rtibblesbot commented Oct 23, 2026 •

Copy link
Copy Markdown
Contributor

Summary

  • Match and Associate response pools listed a shared answer once per use; the saved XML and Kolibri list it once.
  • Both pools now fold on the key their XML build folds on; blank answers and Match distractors keep one chip each.

References

Fixes #6324. First seen: #6168.

Reviewer guidance

Suggested review: Light-touch code review, then manual QA.

  • User-visible files changed: contentcuration/contentcuration/frontend/shared/views/QTIEditor/interactions/associate/Editor.vue, contentcuration/contentcuration/frontend/shared/views/QTIEditor/interactions/associate/parse.js, contentcuration/contentcuration/frontend/shared/views/QTIEditor/interactions/gapMatch/parse.js, contentcuration/contentcuration/frontend/shared/views/QTIEditor/interactions/match/Editor.vue, contentcuration/contentcuration/frontend/shared/views/QTIEditor/interactions/match/parse.js….
  • Open a saved Match question with two rows sharing one answer, and an Associate question reusing an option, in view mode with "show answers" on and off: confirm one chip each, and that the pool does not reorder unexpectedly after editing.
  • Gap Match isn't editable in Studio yet, so QA can't reach it.

QA setup: new exercise in an editable channel → New question; tick Show answers (correct chips green).

  1. Match, shared answer. Response type → Match. Rows "France" → "Europe", "Bulgaria" → "Europe". Close, reload: one green "Europe" chip.
  2. Match, edited answer. Change "Bulgaria" to "Asia": "Europe" and "Asia", both green. Change back to "Europe": one "Europe".
  3. Match, blanks and distractor. Rows "France" → bold "Europe", "Spain" → "Europe", two rows with no answer; distractor "Europe": one green "Europe", one grey "Europe", two empty grey chips.
  4. Match, image answer. Same image as answer in two rows: image once, green.
  5. Associate, reused option. Pairs "Cat"/"Mammal", "Dog"/"Mammal", "Sparrow"/"Bird": five green chips, "Mammal" once. Add an empty pair: two empty chips, not green. Change Pair 2 "Mammal" to "Reptile": green "Reptile" shows.

Look out for:

  • Items 2 and 5: pool order changes after each edit. Acceptable to an editor?

Evidence

Match: shared answer

Step Screenshot
One green "Europe" chip France and Bulgaria both → Europe: one green "Europe" chip

Match: edit a shared answer

Step Screenshot
Bulgaria → Asia: "Europe" and "Asia", both green Bulgaria changed to Asia: pool splits into "Europe" and "Asia", both green

Asia → Europe: folds to one chip:

s2-05-refold-asia-to-europe.webm

Match: blank rows, formatting and distractor

Step Screenshot
Bold and plain "Europe" fold to one green chip; distractor and blanks grey Bold and plain "Europe" answers fold to one green chip; distractor "Europe" and two blank chips stay grey

Match: image answer

Step Screenshot
One green image chip (image broken in sandbox) Same image in two rows: one green image chip

Associate: reused option

Step Screenshot
Mammal once, five green chips Mammal in two pairs: listed once, all five chips green

Associate: blank pair, distractor, unique option

Step Screenshot
Empty Pair 4: two blank chips, not green Empty Pair 4: two separate blank chips, not green
Pair 2 → Reptile: Mammal once, Reptile added Pair 2 changed to Reptile, distractor Mammal: Mammal once, Reptile added
More captures (18)
Step Screenshot
Match shared answer, answers hidden Match shared answer, answers hidden
Match shared answer after reopen Match shared answer after reopen
Pool before edit: one Europe Pool before edit: one Europe
Editing row 2 answer to Asia Editing row 2 answer to Asia
Split pool, answers hidden Split pool, answers hidden
Edit mode: both rows Europe again Edit mode: both rows Europe again
Refolded to one Europe, answers shown Refolded to one Europe, answers shown
After reload, edit mode: both rows Europe After reload, edit mode: both rows Europe
Edit mode: bold, padded, blank and distractor answers Edit mode: bold, padded, blank and distractor answers
One blank row, answers shown One blank row, answers shown
After reload, answers shown After reload, answers shown
After reload, edit mode After reload, edit mode
Image answer in two rows, edit mode Image answer in two rows, edit mode
Image pool after reload Image pool after reload
Associate reused option, answers hidden Associate reused option, answers hidden
Associate pairs after reopen Associate pairs after reopen
Gap Match not offered as a response type Gap Match not offered as a response type
Gap Match item in view mode Gap Match item in view mode

AI usage

Claude Code planned and implemented the fold and tests; verified with the QTIEditor Jest suite and pre-commit.


Written by rtibblesbot, an LLM-based coding agent.

@rtibblesbot

🟡 Waiting for feedback

Last updated: 2026-10-23 13:12 UTC

rtibblesbot and others added 3 commits October 23, 2026 11:42
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
@rtibblesbot
rtibblesbot marked this pull request as ready for review October 23, 2026 13:12
@rtibblesbot
rtibblesbot requested review from a team and leq-bot October 23, 2026 13:12
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

[QTI] Match question: Reused target options appear as duplicates in Studio response pool

1 participant