Page MenuHomePhabricator

Votes with newlines in comment are removed when the next person votes
Closed, ResolvedPublic2 Estimated Story PointsBUG REPORT

Description

What is the problem?

When voting on a wish or focus area, I can add a comment. The comment field supports multi-line input. However, if my comment does have a newline, when someone else votes on the wish afterwards, my vote is removed.

Also, the Wish page does not seem to recognise that I have voted. I still see the "Support wish" button and I don't see the "Edit comment" or "Remove support" buttons. Doing "Support vote" again will replace my current vote.

Steps to reproduce problem
  1. Login to https://meta.wikimedia.beta.wmcloud.org
  2. Find a wish (e.g. https://meta.wikimedia.beta.wmcloud.org/wiki/Community_Wishlist/W10)
  3. Click "Support wish"
  4. In the "Optional comment" input, enter several lines of text and submit
  5. Notice that the "Support wish" button is still there
  6. Login as another user and vote on the same wish
  7. Notice that the vote from your first user is removed
Environment

Wiki(s): https://meta.wikimedia.beta.wmcloud.org CommunityRequests – (cf41c7d) 03:16, 14 October 2025.

Event Timeline

Change #1196185 had a related patch set uploaded (by MusikAnimal; author: MusikAnimal):

[mediawiki/extensions/CommunityRequests@master] VoteStore: use regular expression to split votes rather than a newline

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

MusikAnimal set the point value for this task to 2.Oct 14 2025, 10:00 PM

Thanks for catching this, Dom!

MusikAnimal changed the task status from Open to In Progress.Oct 14 2025, 10:10 PM
HMonroy changed the task status from In Progress to Open.Oct 15 2025, 12:57 AM

Change #1196185 merged by jenkins-bot:

[mediawiki/extensions/CommunityRequests@master] VoteStore: use regular expression to split votes rather than a newline

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

I cannot reproduce this bug anymore on beta.