Page MenuHomePhabricator

Organizer can edit selection of participant questions
Closed, ResolvedPublic3 Estimated Story Points

Description

As an organizer, I want to be able to edit the selection of my Participant Questions, so that I can correct mistakes that I made when configuring Event Registration or so that I can adapt to changes in my data collection preferences (such as learning that my event participants or organizing partners do not feel comfortable with collecting certain data or learning that my organizing partners actually do want to collect data that we previously opted out of collecting).

Background: In the current implementation of the Participant Questions feature of Event Registration, all questions are displayed when the participant registers for the event (though it is optional for them to answer them). We are changing this implementation so that organizers can choose which questions are included in their Event Registration form, and we will allow organizers to edit/change which questions are in the Event Registration form, as long as the event has not ended.

We have decided to handle data aggregation in the following way: We always aggregate the answers of the participants, even if the organizer has removed a question. When we do the final aggregation (when the event is over), we check if there is any aggregated data associated with questions that were removed. If there is aggregated data for removed questions, we delete this data and exclude it from the final aggregation. We will also not allow organizers to edit their selection of questions if the event has ended.

Acceptance Criteria:

  • If an organizer has selected any Participant Questions when configuring registration,
    • And if event registration has not yet closed,
      • Organizers of the event should be able to remove any Participant Questions
        • And all new participants will see no longer see the removed Participant Questions when they register
          • And organizers will no longer see the data collected from before the change in the Participants and Response Statistics tabs
            • And all data from deleted participant questions will be deleted as per the retention period guidelines
            • And all data from deleted participant questions will be aggregated
          • And registered participants who answered a Participant Question prior to having the question removed can still view and edit their response before the event ends, but they will no longer see the question if they blank their former response or if they unregister and then re-register for the event
            • And there is a final aggregation that occurs when the event is over
              • And if there is any data associated with questions that were removed,
                • We should remove this data from the final aggregation
  • If an organizer has not selected any of the Participant Questions when configuring registration,
    • And if event registration has not yet closed,
      • Organizers of the event should be able to add any Participant Questions
        • And all new participants will see the newly added Participant Questions when they register
        • And responses to the newly added Participant Questions from those who registered before the questions were added will be recorded as No Answer
          • Note that we can perhaps later distinguish between No Answer due to the question not being available vs. the participant explicitly choosing to not answer the question, but this is not required for MVP
        • And registered participants who answered a Participant Question prior to having the question added can see the new question(s) with No response when they edit their selection, and they will have option to answer the newly added Participant Questions when editing their registration
  • If an organizer has removed a question and then re-added the question,
    • And if event registration has not yet closed,
      • Organizers of the event should be able to see previous responses to the re-added participant question
  • If an event ends,
    • Organizers will not be able to edit their selection of Participant Questions

Event Timeline

ifried renamed this task from Organizer can edit selection of participant questions [placeholder] to Organizer can edit selection of participant questions.Feb 8 2024, 5:53 PM
ifried updated the task description. (Show Details)

This task is currently being reviewed internally, and once the review is complete, it will be ready for estimation.

And registered participants who answered a Participant Question prior to having the question removed can still view and edit their response before the event ends, but they will no longer see the question if they unregister and then re-register for the event

What if they did answer that question, then the question is removed, and the participant blanks out their answer? I assume they should no longer be able to see the field, right?

Yes, if the participant has blanked their response to a removed question, then they should no longer see the field.

Change 1007446 had a related patch set uploaded (by Daimona Eaytoy; author: Daimona Eaytoy):

[mediawiki/extensions/CampaignEvents@master] Always show answered questions when a user register for an event

https://gerrit.wikimedia.org/r/1007446

Change 1007450 had a related patch set uploaded (by Daimona Eaytoy; author: Daimona Eaytoy):

[mediawiki/extensions/CampaignEvents@master] Do not aggregate answers to participant questions that have been removed

https://gerrit.wikimedia.org/r/1007450

Change 1007452 had a related patch set uploaded (by Daimona Eaytoy; author: Daimona Eaytoy):

[mediawiki/extensions/CampaignEvents@master] Allow organizers to edit what questions are enabled for an event

https://gerrit.wikimedia.org/r/1007452

@ifried The following two scenario have been brought up in code review and would require further thought:

Scenario 1

  • On day X, 20 people answer all PII questions.
  • On day X + 80, the organizer removes all PII questions from the event (potentially by mistake, but we can't know that)
  • On day X + 90, the initial 20 answers get deleted, but not aggregated because the questions are no longer enabled
  • On day X + 92, the organizer enables PII questions again

The way it currently works in the proposed patch is that the organizer will not see aggregated data for the initial 20 answers. Should this be the case?

Scenario 2

  • On day X, 20 people answer all PII questions.
  • On day X + 90, the initial 20 answers get aggregated
  • On day X + 100, the organizer removes all PII questions from the event

When the event ends, the organizer would still be able to see aggregated data for the initial 20 answers, even if the question is no longer enabled. However, the aggregated data would not include any answers given after day X + 10 (i.e., answers that haven't been aggregated by the time the organizer removes PII questions).


We aren't sure what to do in these scenarios, as it's ultimately a product question, and I'd like to hear your opinions on these.

@ifried The following two scenario have been brought up in code review and would require further thought:

Scenario 1

  • On day X, 20 people answer all PII questions.
  • On day X + 80, the organizer removes all PII questions from the event (potentially by mistake, but we can't know that)
  • On day X + 90, the initial 20 answers get deleted, but not aggregated because the questions are no longer enabled
  • On day X + 92, the organizer enables PII questions again

The way it currently works in the proposed patch is that the organizer will not see aggregated data for the initial 20 answers. Should this be the case?

Scenario 2

  • On day X, 20 people answer all PII questions.
  • On day X + 90, the initial 20 answers get aggregated
  • On day X + 100, the organizer removes all PII questions from the event

When the event ends, the organizer would still be able to see aggregated data for the initial 20 answers, even if the question is no longer enabled. However, the aggregated data would not include any answers given after day X + 10 (i.e., answers that haven't been aggregated by the time the organizer removes PII questions).


We aren't sure what to do in these scenarios, as it's ultimately a product question, and I'd like to hear your opinions on these.

One option to solve both scenarios could be:

  • If the aggregation is running because 90 days is past then we normally aggregate the answers even if the questions were removed by the organizer, and when the event is over and the aggregation is running again, we delete all aggregates that belong to removed questions.

Just a side note not directly related to the above comments; We would inform organizers of the consequence of removing a question after people have registered. Perhaps when they go to the Edit Enable Registration form and they try to unselect a question they get a dialog informing them of the consequence and to confirm their action cc @ifried

One option to solve both scenarios could be:

  • If the aggregation is running because 90 days is past then we normally aggregate the answers even if the questions were removed by the organizer, and when the event is over and the aggregation is running again, we delete all aggregates that belong to removed questions.

Agreed; two things to consider if we do that though: 1) what happens if the organizer edits the questions after the event ends, and 2) we currently only run aggregation for events that have non-aggregated questions; to implement this option, we would need to always run aggregation for all events indiscriminately. Other options to consider:

  • What's currently implemented (described in T354880#9620217): always delete answers without aggregation if the question has been removed (this would be done after 90 days, or when the event ends)
  • We always aggregate everything, even if the questions have been removed. Then, when the organizer goes to the stats tab, they only see data for the questions that are currently enabled.

Awaiting feedback on how to handle the scenarios described above, so this is blocked until we confirm the correct behavior.

ifried updated the task description. (Show Details)
ifried updated the task description. (Show Details)

@ifried @gonyeahialam Should there be additional messaging in the interface that explains why organizers can't edit questions once the event has ended?

Change #1014149 had a related patch set uploaded (by Daimona Eaytoy; author: Daimona Eaytoy):

[mediawiki/extensions/CampaignEvents@master] AggregateParticipantAnswers: prune old aggregates

https://gerrit.wikimedia.org/r/1014149

Change #1007450 abandoned by Daimona Eaytoy:

[mediawiki/extensions/CampaignEvents@master] Do not aggregate answers to participant questions that have been removed

Reason:

Superseded by I6b485099d259ec0a6376934fca18337afa5d2f5a, which uses a different strategy for pruning old aggregates.

https://gerrit.wikimedia.org/r/1007450

@Daimona we could disable the checkboxes and communicate to the organizer using a tooltip as shown below

Screen Recording 2024-03-26 at 11.24.27 AM.gif (683×960 px, 84 KB)

Just a side note not directly related to the above comments; We would inform organizers of the consequence of removing a question after people have registered. Perhaps when they go to the Edit Enable Registration form and they try to unselect a question they get a dialog informing them of the consequence and to confirm their action cc @ifried

I explored some design ideas for this.

Idea 1: Show a tooltip when the organizer unselects a question

Screenshot 2024-03-26 at 11.59.33 AM.png (1×2 px, 286 KB)

Idea 2: Show a modal when an organizer unselects a question

Screen Recording 2024-03-26 at 12.01.24 PM.gif (636×960 px, 113 KB)

Idea 3: Show a warning message when the organizer unselects a question

Screenshot 2024-03-26 at 12.02.29 PM.png (1×2 px, 292 KB)

Idea 4: Show a dialog with a message when the organizer submits the form after removing some participants questions

Screen Recording 2024-03-26 at 12.01.50 PM.gif (636×960 px, 152 KB)

Idea 4 seems to be the best flow among all of them.

cc @Daimona @ifried

As an update, I have created 2 tickets to deal with the questions discussed above; see T361019 & T361020. We will discuss both tickets in the design + engineering meeting tomorrow.

Change #1007446 merged by jenkins-bot:

[mediawiki/extensions/CampaignEvents@master] Always show answered questions when a user registers for an event

https://gerrit.wikimedia.org/r/1007446

Change #1014149 merged by jenkins-bot:

[mediawiki/extensions/CampaignEvents@master] AggregateParticipantAnswers: prune old aggregates

https://gerrit.wikimedia.org/r/1014149

Change #1007452 merged by jenkins-bot:

[mediawiki/extensions/CampaignEvents@master] Allow organizers to edit what questions are enabled for an event

https://gerrit.wikimedia.org/r/1007452

Acceptance Criteria:

  • If an organizer has selected any Participant Questions when configuring registration,
    • And if event registration has not yet closed,
      • ✅ Organizers of the event should be able to remove any Participant Questions
        • Screen Recording 2024-04-19 at 2.33.35 PM.gif (1×1 px, 508 KB)
        • ✅ And all new participants will see no longer see the removed Participant Questions when they register
          • Screen Recording 2024-04-19 at 2.47.52 PM.gif (1×3 px, 1 MB)
          • ✅ And organizers will no longer see the data collected from before the change in the Participants and Response Statistics tabs
            • ✅ And all data from deleted participant questions will be deleted as per the retention period guidelines
            • ✅ And all data from deleted participant questions will be aggregated
              • aggregated and deleted.gif (1×2 px, 1018 KB)
            • ( note that T363200 has been filed to address the This participant's responses have been aggregated and deleted copy remaining after participant questions have been removed)
          • ✅ And registered participants who answered a Participant Question prior to having the question removed can still view and edit their response before the event ends, but they will no longer see the question if they blank their former response or if they unregister and then re-register for the event
            • ✅ And there is a final aggregation that occurs when the event is over
              • And if there is any data associated with questions that were removed,
                • ✅ We should remove this data from the final aggregation
                  • ❓ Data is removed from aggregation, but there is a notice that Participants' responses will be aggregated and made available here shortly.
                  • Screenshot 2024-04-23 at 1.59.13 PM.png (742×1 px, 77 KB)
                  • Created followup task for this T363211
  • If an organizer has not selected any of the Participant Questions when configuring registration,
    • And if event registration has not yet closed,
      • ✅ Organizers of the event should be able to add any Participant Questions
          • Screen Recording 2024-04-23 at 12.22.49 PM.gif (1×3 px, 2 MB)
        • ✅ And all new participants will see the newly added Participant Questions when they register
          • Screen Recording 2024-04-23 at 12.22.49 PM.gif (1×3 px, 2 MB)
        • ✅ And responses to the newly added Participant Questions from those who registered before the questions were added will be recorded as No Answer
          • Note that we can perhaps later distinguish between No Answer due to the question not being available vs. the participant explicitly choosing to not answer the question, but this is not required for MVP
          • Screen Recording 2024-04-23 at 12.22.49 PM.gif (1×3 px, 1 MB)
        • ✅ And registered participants who answered a Participant Question prior to having the question added can see the new question(s) with No response when they edit their selection, and they will have option to answer the newly added Participant Questions when editing their registration
          • Screen Recording 2024-04-23 at 12.40.59 PM.gif (1×3 px, 2 MB)
  • If an organizer has removed a question and then re-added the question,
    • And if event registration has not yet closed,
      • ✅ Organizers of the event should be able to see previous responses to the re-added participant question
        • Screen Recording 2024-04-23 at 1.09.16 PM.gif (1×2 px, 2 MB)
  • If an event ends,
    • ✅ Organizers will not be able to edit their selection of Participant Questions
      • Screenshot 2024-04-19 at 2.26.23 PM.png (1×1 px, 370 KB)

@Daimona I have created follow up tickets T363200 and T363211 to address a couple of things in this task.

Because T363193, T363200 and T363211 have been created to fix issues found in this ticket and everything else is working as described in the AC, I am sending this to design sign off.

This feature has been released, so I am marking this as Done.