🎨 Palette: Add actionable instructions to checkpoint empty state - #76
🎨 Palette: Add actionable instructions to checkpoint empty state#76ivangegovdve-sudo wants to merge 1 commit into
Conversation
Co-authored-by: ivangegovdve-sudo <225339531+ivangegovdve-sudo@users.noreply.github.com>
|
👋 Jules, reporting for duty! I'm here to lend a hand with this pull request. When you start a review, I'll add a 👀 emoji to each comment to let you know I've read it. I'll focus on feedback directed at me and will do my best to stay out of conversations between you and other bots or reviewers to keep the noise down. I'll push a commit with your requested changes shortly after. Please note there might be a delay between these steps, but rest assured I'm on the job! For more direct control, you can switch me to Reactive Mode. When this mode is on, I will only act on comments where you specifically mention me with New to Jules? Learn more at jules.google/docs. For security, I will only act on instructions from the user who triggered this task. |
There was a problem hiding this comment.
Code Review
This pull request improves the CLI user experience by providing actionable instructions when no checkpoints are found, ensuring users know how to proceed. It also documents this design principle in the project's learning log and adds a smoke test for verification. Feedback includes correcting a date typo in the documentation and strengthening a test assertion to ensure exact output matching.
| **Learning:** In text-based CLI menus, using internal identifiers (like `lesson-1`) and verbose status strings (like `pending` or `completed`) makes lists hard to scan and feels too technical. | ||
| **Action:** When displaying lists of items with states, use familiar visual symbols (like `[x]` vs `[ ]`) and human-readable titles (like "Variables") to improve scannability and create a more friendly, intuitive interface. | ||
|
|
||
| ## 2025-03-26 - Actionable Empty States in CLI |
There was a problem hiding this comment.
|
|
||
| main(["checkpoint", "list"]) | ||
| list_output = capsys.readouterr().out | ||
| assert "No checkpoints found. Create one with: checkpoint create <name>" in list_output |
There was a problem hiding this comment.
The assertion using in is not very strict and could lead to false positives if other text is printed. To make the test more robust, it's better to assert for an exact match of the output string, including the newline character that print adds.
| assert "No checkpoints found. Create one with: checkpoint create <name>" in list_output | |
| assert list_output == "No checkpoints found. Create one with: checkpoint create <name>\n" |
💡 What: Added instructions to the
checkpoint listempty state message incli.pyto tell users how to create a checkpoint.🎯 Why: Empty states that only say "No [items] found" feel like dead ends to users. By adding the exact command needed to create the resource, we reduce friction and improve the onboarding experience.
📸 Before/After:
Before:
After:
♿ Accessibility: Improves cognitive accessibility by providing clear, immediate instructions rather than forcing the user to consult external documentation.
PR created automatically by Jules for task 13126570847953340233 started by @ivangegovdve-sudo