fix: add actionable assertion messages to itertools checks - #146
kamalesh404 wants to merge 6 commits into
Conversation
|
No actionable comments were generated in the recent review. 🎉 ℹ️ Recent review info⚙️ Run configurationConfiguration used: Organization UI Review profile: CHILL Plan: Advanced Run ID: 📒 Files selected for processing (6)
Included review availability: Your plan provides up to 1 included review per hour; 0 remain after this review. 📜 Recent review details🧰 Additional context used📓 Path-based instructions (3)Maintain Python 3.9 compatibility.📄 CodeRabbit inference engine (AGENTS.md) Files:
Preserve learner-edited exercises during workspace updates.📄 CodeRabbit inference engine (AGENTS.md) Files:
Checks must use bare assertions with actionable, beginner-facing messages.📄 CodeRabbit inference engine (AGENTS.md) Files:
🪛 Ruff (0.16.4)checks/itertools/itertools7.py[error] 1-1: Undefined name (F821) checks/itertools/itertools8.py[error] 1-1: Undefined name (F821) [error] 2-2: Undefined name (F821) checks/itertools/itertools4.py[error] 1-1: Undefined name (F821) checks/itertools/itertools3.py[error] 1-1: Undefined name (F821) checks/itertools/itertools5.py[error] 1-1: Undefined name (F821) checks/itertools/itertools6.py[error] 1-1: Undefined name (F821) 🔇 Additional comments (6)
📝 WalkthroughWalkthroughThe change adds failure messages to seven assertions in six itertools checks. Messages show expected values and available actual values. Assertion predicates remain unchanged. ChangesItinerables assertion messages
Priority: ⬇️ Low Estimated code review effort: 1 (Trivial) | ~5 minutes Change: Bug fix · Severity of issue fixed: Low Poem
Merge Risk: ⚪ Minimal · up to The six checks only gain clearer failure messages; their validation behavior and success paths remain unchanged, so there is no merge-blocking risk. 🚥 Pre-merge checks | ✅ 3 | ❌ 2❌ Failed checks (1 warning, 1 inconclusive)
✅ Passed checks (3 passed)
Full details: Linked Issues checkExplanation For [ Resolution Provide reviewable verification evidence for the required test commands, the AST audit showing zero bare assertions in the six files, and Python 3.9 compatibility. Provide a complete whole-PR diff or equivalent evidence if the verification evidence does not establish unchanged predicates, ordering, side effects, and success output.
✨ 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. A rabbit reads each line, Comment |
Fixes #100
Adds descriptive error messages to 7 bare assertions across 6 itertools check files. When a student's code fails, they now see what was expected vs what they produced, instead of a generic \AssertionError.
Changes:
All assertions now include f-string messages showing expected vs actual values.
Summary by CodeRabbit