Issue/4186/fix/mc options change feedback#4286
Conversation
📝 WalkthroughWalkthroughThis PR adjusts forecast completion validation for multiple choice questions to ignore removed options, updates email notification templates to use dynamic pluralization for affected options, simplifies email layouts by removing related questions sections, and revises user messaging from "probability was folded" to "predictions were moved." Changes
Estimated code review effort🎯 3 (Moderate) | ⏱️ ~25 minutes Possibly related PRs
Suggested reviewers
Poem
🚥 Pre-merge checks | ✅ 3 | ❌ 1❌ Failed checks (1 warning)
✅ Passed checks (3 passed)
✏️ Tip: You can configure your own custom pre-merge checks in the settings. ✨ Finishing touches
🧪 Generate unit tests (beta)
Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. Comment |
There was a problem hiding this comment.
Caution
Some comments are outside the diff and can’t be posted inline due to platform limitations.
⚠️ Outside diff range comments (1)
front_end/src/components/forecast_maker/forecast_maker_question/forecast_maker_multiple_choice.tsx (1)
402-402:⚠️ Potential issue | 🟡 MinorPre-existing bug:
!forecastsSum === nullis alwaysfalse.
!forecastsSumyields a boolean, so comparing it with=== nullis alwaysfalse. This means the null-check onforecastsSuminrescaleForecastsis effectively dead code. The intended guard was likelyforecastsSum === null.Not introduced in this PR, but worth fixing since you're touching adjacent logic.
Proposed fix
- if (!forecastHasValues || !forecastsSum === null) return; + if (!forecastHasValues || forecastsSum === null) return;
🧹 Nitpick comments (1)
questions/tasks.py (1)
294-296: Note:template.replace("Their", "Its", 1)on Line 296 is now a dead path for the default text.The new
default_textuses "Your predictions" instead of "Their probability", so this replacement will never match the default. It only applies if a customcomment_textcontaining "Their" is passed. Consider removing it for clarity, or keeping it for backward compatibility with custom text.
🧹 Preview Environment Cleaned UpThe preview environment for this PR has been destroyed.
Cleanup triggered by PR close at 2026-02-09T15:56:08Z |
closes #4186
fixes broken reaffirm button
email subject line includes name
pluralization of emails
removes related questions from emails
improves comment phrasing as requested
Summary by CodeRabbit
Bug Fixes
Improvements