[Bug]: Poll voter loses their "You voted" state as soon as someone else votes
メンテナーはふだん 1 日以内に返信
評価
- 難易度
- 3/5
- 見積もり時間
- 1〜2日
- 初心者へのやさしさ
- 74/100
- issue の種類
- バグ
- 明瞭さ
- 明確に書かれている
- 活発さ
- 活発
- 技術スタック
- react, typescript
調査の方向性
Start by tracing sanitizePoll in apps/ws-server/src/utils/pollManager.ts and the poll:updated/poll:ended broadcasts in apps/ws-server/src/utils/handleMessages.ts; then follow the poll update handler in apps/frontend/src/screens/LiveQuiz.tsx and how ActivePollOverlay.tsx uses votedOptionId. Add coverage for a player voting followed by another player's update, and check that the vote selection and results remain visible through poll updates and ending.
索引モデルが issue の本文から書いたものです。
説明
What happens
I vote in a live poll and see "You voted" with the results. When the next person votes, my screen goes back to the unvoted view with the Vote buttons, and the results are hidden again. Tapping an option then sends a second vote, which the server refuses with ALREADY_VOTED, and the screen does not show anything. In a room with many players this happens on almost every vote. The "Your Vote" mark is also lost when the poll ends.
Why
apps/ws-server/src/utils/pollManager.ts:76:sanitizePollsetsvotedOptionId: nullwhen it is called without a participant id.apps/ws-server/src/utils/handleMessages.ts:733-735:poll:updatedis broadcast to the whole session without a participant id (same forpoll:ended).apps/frontend/src/screens/LiveQuiz.tsx:407-414: the client does{ ...prev, ...payload.poll }, so thatnulloverwrites the voter's saved choice.ActivePollOverlay.tsxusesvotedOptionIdto decide whether to show results.
Steps to reproduce
- Host a quiz, join with two players, launch a poll.
- Player A votes. A sees "You voted".
- Player B votes. A is back to the Vote buttons.
I reproduced both sides with a throwaway vitest test (Redis and Prisma faked on the server, fake WebSocket on the frontend). Messages A receives are poll:updated (null), poll:voted (option), poll:updated (null), and after the last one the screen shows "Tap an option above to submit your vote!".
Expected
A player's own choice stays selected until a new poll starts.
Suggested fix
Leave votedOptionId out of broadcast payloads (only include it when a participant id is passed), or keep prev.votedOptionId in the client when the poll id is the same. Add a test for vote, then someone else's update.
I can fix this one if you assign it to me.
- 主要言語
- TypeScript
- スター
- 21
- フォーク
- 7
- 平均マージ
- 11時間 14分
- マージ済み PR(30日)
- 30
環境構築
- Dockerfile または Docker Compose ファイルあり
- プルリクエストのテンプレートあり
- コントリビューションガイドを読む
はじめの一歩
- issue を最後まで読み、次にプロジェクトのコントリビューションガイドを読みます。
- 着手することを issue にコメントします — 二人が同じ作業をするのを防げます。
- リポジトリをフォークし、ブランチを切って変更します。
- issue 番号を参照したプルリクエストを送ります。
TheCodeHeist-Coder/Rexial のほかの issue
-
bug level3 nsoc26
難易度 2/5 1〜3時間 初心者へのやさしさ 86/100
TheCodeHeist-Coder/Rexial#251 · コメント 1 件 ·
メンテナーはふだん 1 日以内に返信
-
Lint does not block a merge, and the same test step runs twice対応中かも @spikedeeev が 7 日前に担当しました。 オープンBackend first issue bug good first issue help wanted level1 nsoc26
難易度 2/5 1〜3時間 初心者へのやさしさ 82/100
TheCodeHeist-Coder/Rexial#243 · コメント 2 件 · 担当者 1 名 ·
メンテナーはふだん 1 日以内に返信
-
Add CodeQL and dependency scanning so a malicious or vulnerable dependency is caught対応中かも @divyanshAgarwal123 が 9 日前に担当しました。 オープンBackend first issue enhancement help wanted level3 nsoc26
難易度 2/5 半日 初心者へのやさしさ 62/100
TheCodeHeist-Coder/Rexial#242 · コメント 3 件 · 担当者 1 名 ·
メンテナーはふだん 1 日以内に返信
-
fix: validate types for login email and password (500 on non-string or missing body)再び着手できるかも @spikedeeev が 16 日前に担当しましたが、オープン中のプルリクエストはありません。 オープン
難易度 2/5 1〜3時間 初心者へのやさしさ 82/100
TheCodeHeist-Coder/Rexial#235 · コメント 2 件 ·
メンテナーはふだん 1 日以内に返信
-
security: remediate the dependency baseline before enforcing the audit gate対応中かも @divyanshAgarwal123 が 6 日前に担当しました。 オープンlevel2 nsoc26
難易度 5/5 1週間以上 初心者へのやさしさ 25/100
TheCodeHeist-Coder/Rexial#266 · コメント 2 件 · 担当者 1 名 ·
メンテナーはふだん 1 日以内に返信
TheCodeHeist-Coder/Rexial の issue をすべて見る
似ている issue
-
clawsweeper:intake:bug clawsweeper:intake:needs-environment
難易度 2/5 1〜3時間 初心者へのやさしさ 82/100
openclaw/openclaw#212827 · コメント 1 件 · リアクション 1 件 ·
メンテナーはふだん 1 日以内に返信
-
KT-2245 e2e specs that call the backend directly fall back to the developer's own Kronn on :3140オープン
難易度 2/5 1〜3時間 初心者へのやさしさ 78/100
メンテナーはふだん 1 日以内に返信
-
Use one constant for the 10,000-character input limit対応中かも @NginxL が今日担当しました。 オープンgood first issue refactor
難易度 2/5 1〜3時間 初心者へのやさしさ 78/100
aniru-dh21/snap-validate#51 ·
メンテナーはふだん 1 日以内に返信
-
dependencies effort: small good first issue priority: low
難易度 1/5 1〜3時間 初心者へのやさしさ 88/100
TMHSDigital/screencast-mcp#509 ·
メンテナーはふだん 1 日以内に返信
-
from-review tech-debt testing
難易度 2/5 1〜3時間 初心者へのやさしさ 82/100
blamechris/chroxy#9520 ·
メンテナーはふだん 1 日以内に返信