Skip to content

Feat: Add search to category view & bulk delete in manage imports#21

Merged
MnemOnicE merged 2 commits into
mainfrom
jules-18382313160809785483-6a213c73
Jun 9, 2026
Merged

Feat: Add search to category view & bulk delete in manage imports#21
MnemOnicE merged 2 commits into
mainfrom
jules-18382313160809785483-6a213c73

Conversation

@MnemOnicE

Copy link
Copy Markdown
Owner

Implements two UI enhancements in the dashboard:

  1. Adds a prompt to search for commands directly from the category exploration view, reducing friction and menu navigation.
  2. Updates the manage imports view to support deleting multiple custom imports via a comma-separated list, or clearing all imports with the 'all' command.

PR created automatically by Jules for task 18382313160809785483 started by @MnemOnicE

Implements two UI enhancements in the dashboard:
1. Adds a prompt to search for commands directly from the category exploration view, reducing friction and menu navigation.
2. Updates the manage imports view to support deleting multiple custom imports via a comma-separated list, or clearing all imports with the 'all' command.

Co-authored-by: MnemOnicE <170563909+MnemOnicE@users.noreply.github.com>
@google-labs-jules

Copy link
Copy Markdown
Contributor

👋 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 @jules. You can find this option in the Pull Request section of your global Jules UI settings. You can always switch back!

New to Jules? Learn more at jules.google/docs.


For security, I will only act on instructions from the user who triggered this task.

@coderabbitai

coderabbitai Bot commented Jun 9, 2026

Copy link
Copy Markdown

Review Change Stack

Warning

Review limit reached

@MnemOnicE, we couldn't start this review because you've reached your PR review rate limit.

More reviews will be available in 54 minutes and 18 seconds. Learn how PR review limits work.

Your organization has run out of usage credits. Purchase more in the billing tab.

⌛ How to resolve this issue?

After more reviews become available, a review can be triggered using the @coderabbitai review command as a PR comment. Alternatively, push new commits to this PR.

We recommend that you space out your commits to avoid hitting the rate limit.

🚦 How do rate limits work?

CodeRabbit enforces hourly rate limits for each developer per organization.

Our paid plans include higher PR review limits than trial, open-source, and free plans. In all cases, reviews become available again over time. During sustained high-volume PR review activity, CodeRabbit may temporarily slow when the next review becomes available.

Please see our Fair Usage Limits Policy for further information.

ℹ️ Review info
⚙️ Run configuration

Configuration used: Organization UI

Review profile: ASSERTIVE

Plan: Pro Plus

Run ID: d0297e0b-760a-493f-9fc7-308ecf039a7d

📥 Commits

Reviewing files that changed from the base of the PR and between b49c223 and a87be75.

📒 Files selected for processing (1)
  • commando/ui/dashboard.py
📝 Walkthrough

Walkthrough

Dashboard module enhances category exploration by threading a search callback function through the flow, enabling users to search after browsing categories. Custom import deletion expands from single-command removal to batch operations via comma-separated lists or bulk all deletion with confirmation, updating and persisting the custom guide.

Changes

Dashboard UI Flow Improvements

Layer / File(s) Summary
explore_category signature and integration
commando/ui/dashboard.py
explore_category function signature updated to accept search_command_fn parameter. main_loop option "2" refactored to pass search_command_fn into the updated function call.
Category display with search prompt
commando/ui/dashboard.py
After listing commands in selected category, UI prompts for optional search input; if provided, invokes search_command_fn with the first token, otherwise returns to main menu.
Expanded imports deletion workflow
commando/ui/dashboard.py
manage_imports deletion logic now accepts comma-separated command names or all keyword (with confirmation), updates custom_guide, persists via save_json, and reports deleted and not-found entries.

Estimated code review effort

🎯 2 (Simple) | ⏱️ ~12 minutes

Poem

Yo, yo, yo—dashboard droppin' heat, search completion's clean,
Comma-separated killers, deletion flow unseen,
Category navigation now's got that callback swing,
Batch ops on imports, custom guide's the king! 🎙️✨

🚥 Pre-merge checks | ✅ 4 | ❌ 1

❌ Failed checks (1 warning)

Check name Status Explanation Resolution
Docstring Coverage ⚠️ Warning Docstring coverage is 0.00% which is insufficient. The required threshold is 80.00%. Write docstrings for the functions missing them to satisfy the coverage threshold.
✅ Passed checks (4 passed)
Check name Status Explanation
Title check ✅ Passed The title accurately summarizes the main changes: adding search functionality to category view and bulk delete to manage imports.
Description check ✅ Passed The description clearly relates to the changeset, detailing both UI enhancements with specific functionality for search and bulk deletion.
Linked Issues check ✅ Passed Check skipped because no linked issues were found for this pull request.
Out of Scope Changes check ✅ Passed Check skipped because no linked issues were found for this pull request.

✏️ Tip: You can configure your own custom pre-merge checks in the settings.

✨ Finishing Touches
🧪 Generate unit tests (beta)
  • Create PR with unit tests
  • Commit unit tests in branch jules-18382313160809785483-6a213c73

Warning

Review ran into problems

🔥 Problems

Stopped waiting for pipeline failures after 30000ms. One of your pipelines takes longer than our 30000ms fetch window to run, so review may not consider pipeline-failure results for inline comments if any failures occurred after the fetch window. Increase the timeout if you want to wait longer or run a @coderabbit review after the pipeline has finished.


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.

❤️ Share

Comment @coderabbitai help to get the list of available commands and usage tips.

@gemini-code-assist gemini-code-assist Bot left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Code Review

This pull request enhances the dashboard UI by allowing users to search for commands directly from the category exploration view and enabling bulk deletion (including a 'delete all' option) of custom imports. The feedback recommends addressing a redundant pause and case-sensitivity issue in the search functionality, as well as improving encapsulation and duplicate handling during bulk deletion.

Important

The consumer version of Gemini Code Assist on GitHub is being sunset. Starting June 18, 2026, new organization installations will be blocked, and all code review activity will officially cease on July 17, 2026.
For more details on the timeline and next steps, please review the Help Documentation.

Comment thread commando/ui/dashboard.py Outdated
Comment on lines +171 to +175
search_choice = input(f"\n{GREEN}➜ {RESET}").strip()
if search_choice:
search_command_fn(search_choice.split()[0])
else:
pause()

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

medium

There are two issues here:

  1. Redundant Pause: When the user presses Enter to return to the menu, they are forced to press Enter again due to the pause() call. Removing the else block allows them to return to the menu immediately as expected.
  2. Case Sensitivity: The search input is not lowercased, which can cause searches to fail if the user types uppercase letters (unlike the main loop which lowercases the input). We should lowercase the command name before passing it to search_command_fn.
            search_choice = input(f"\\n{GREEN}{RESET}").strip()\n            if search_choice:\n                search_command_fn(search_choice.split()[0].lower())

Comment thread commando/ui/dashboard.py
Comment on lines 204 to 227
choice = input(f"\n{GREEN}➜ {RESET}").strip().lower()
if choice in custom_guide:
del custom_guide[choice]
save_json(CUSTOM_DICT_FILE, custom_guide)
print(f"{YELLOW}Successfully deleted '{choice}'.{RESET}")
if choice == "all":
confirm = input(f"{RED}Are you sure you want to delete ALL custom imports? (y/n): {RESET}").strip().lower()
if confirm == 'y':
custom_guide.clear()
save_json(CUSTOM_DICT_FILE, custom_guide)
print(f"{YELLOW}Successfully deleted all custom imports.{RESET}")
pause()
elif choice:
print(f"{RED}Command not found in custom imports.{RESET}")
deleted = []
not_found = []
for cmd in [c.strip() for c in choice.split(",") if c.strip()]:
if cmd in custom_guide:
del custom_guide[cmd]
deleted.append(cmd)
else:
not_found.append(cmd)

if deleted:
save_json(CUSTOM_DICT_FILE, custom_guide)
print(f"{YELLOW}Successfully deleted: {', '.join(deleted)}{RESET}")
if not_found:
print(f"{RED}Not found in custom imports: {', '.join(not_found)}{RESET}")
pause()

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

medium

There are two improvement opportunities here:

  1. Encapsulation: Instead of calling save_json(CUSTOM_DICT_FILE, custom_guide) directly, we should use the state_manager.save_custom() method to respect the encapsulation of the StateManager class.
  2. Duplicate Handling: If the user inputs duplicate commands in the comma-separated list (e.g., ls, ls), the second occurrence will trigger the not_found block and display a confusing message. We can use dict.fromkeys to deduplicate the input list while preserving the user's input order.
    choice = input(f"\\n{GREEN}{RESET}").strip().lower()\n    if choice == "all":\n        confirm = input(f"{RED}Are you sure you want to delete ALL custom imports? (y/n): {RESET}").strip().lower()\n        if confirm == 'y':\n            custom_guide.clear()\n            state_manager.save_custom()\n            print(f"{YELLOW}Successfully deleted all custom imports.{RESET}")\n        pause()\n    elif choice:\n        deleted = []\n        not_found = []\n        for cmd in dict.fromkeys(c.strip() for c in choice.split(\",\") if c.strip()):\n            if cmd in custom_guide:\n                del custom_guide[cmd]\n                deleted.append(cmd)\n            else:\n                not_found.append(cmd)\n\n        if deleted:\n            state_manager.save_custom()\n            print(f"{YELLOW}Successfully deleted: {', '.join(deleted)}{RESET}")\n        if not_found:\n            print(f"{RED}Not found in custom imports: {', '.join(not_found)}{RESET}")\n        pause()

@MnemOnicE

Copy link
Copy Markdown
Owner Author

@jules commando/ui/dashboard.py
Comment on lines +171 to +175
search_choice = input(f"\n{GREEN}➜ {RESET}").strip()
if search_choice:
search_command_fn(search_choice.split()[0])
else:
pause()

gemini-code-assist Bot
1 minute ago
Contributor
medium

There are two issues here:

Redundant Pause: When the user presses Enter to return to the menu, they are forced to press Enter again due to the pause() call. Removing the else block allows them to return to the menu immediately as expected.
Case Sensitivity: The search input is not lowercased, which can cause searches to fail if the user types uppercase letters (unlike the main loop which lowercases the input). We should lowercase the command name before passing it to search_command_fn.
search_choice = input(f"\n{GREEN}➜ {RESET}").strip()\n if search_choice:\n search_command_fn(search_choice.split()[0].lower())
@MnemOnicE Reply...
commando/ui/dashboard.py
Comment on lines 204 to 227
choice = input(f"\n{GREEN}➜ {RESET}").strip().lower()
if choice in custom_guide:
del custom_guide[choice]
save_json(CUSTOM_DICT_FILE, custom_guide)
print(f"{YELLOW}Successfully deleted '{choice}'.{RESET}")
if choice == "all":
confirm = input(f"{RED}Are you sure you want to delete ALL custom imports? (y/n): {RESET}").strip().lower()
if confirm == 'y':
custom_guide.clear()
save_json(CUSTOM_DICT_FILE, custom_guide)
print(f"{YELLOW}Successfully deleted all custom imports.{RESET}")
pause()
elif choice:
print(f"{RED}Command not found in custom imports.{RESET}")
deleted = []
not_found = []
for cmd in [c.strip() for c in choice.split(",") if c.strip()]:
if cmd in custom_guide:
del custom_guide[cmd]
deleted.append(cmd)
else:
not_found.append(cmd)

    if deleted:
        save_json(CUSTOM_DICT_FILE, custom_guide)
        print(f"{YELLOW}Successfully deleted: {', '.join(deleted)}{RESET}")
    if not_found:
        print(f"{RED}Not found in custom imports: {', '.join(not_found)}{RESET}")
    pause()

gemini-code-assist Bot
1 minute ago
Contributor
medium

There are two improvement opportunities here:

Encapsulation: Instead of calling save_json(CUSTOM_DICT_FILE, custom_guide) directly, we should use the state_manager.save_custom() method to respect the encapsulation of the StateManager class.
Duplicate Handling: If the user inputs duplicate commands in the comma-separated list (e.g., ls, ls), the second occurrence will trigger the not_found block and display a confusing message. We can use dict.fromkeys to deduplicate the input list while preserving the user's input order.
choice = input(f"\n{GREEN}➜ {RESET}").strip().lower()\n if choice == "all":\n confirm = input(f"{RED}Are you sure you want to delete ALL custom imports? (y/n): {RESET}").strip().lower()\n if confirm == 'y':\n custom_guide.clear()\n state_manager.save_custom()\n print(f"{YELLOW}Successfully deleted all custom imports.{RESET}")\n pause()\n elif choice:\n deleted = []\n not_found = []\n for cmd in dict.fromkeys(c.strip() for c in choice.split(",") if c.strip()):\n if cmd in custom_guide:\n del custom_guide[cmd]\n deleted.append(cmd)\n else:\n not_found.append(cmd)\n\n if deleted:\n state_manager.save_custom()\n print(f"{YELLOW}Successfully deleted: {', '.join(deleted)}{RESET}")\n if not_found:\n print(f"{RED}Not found in custom imports: {', '.join(not_found)}{RESET}")\n pause()

@google-labs-jules

Copy link
Copy Markdown
Contributor

@jules commando/ui/dashboard.py
Comment on lines +171 to +175
search_choice = input(f"\n{GREEN}➜ {RESET}").strip()
if search_choice:
search_command_fn(search_choice.split()[0])
else:
pause()

gemini-code-assist Bot
1 minute ago
Contributor
medium

There are two issues here:

Redundant Pause: When the user presses Enter to return to the menu, they are forced to press Enter again due to the pause() call. Removing the else block allows them to return to the menu immediately as expected.
Case Sensitivity: The search input is not lowercased, which can cause searches to fail if the user types uppercase letters (unlike the main loop which lowercases the input). We should lowercase the command name before passing it to search_command_fn.
search_choice = input(f"\n{GREEN}➜ {RESET}").strip()\n if search_choice:\n search_command_fn(search_choice.split()[0].lower())
@MnemOnicE Reply...
commando/ui/dashboard.py
Comment on lines 204 to 227
choice = input(f"\n{GREEN}➜ {RESET}").strip().lower()
if choice in custom_guide:
del custom_guide[choice]
save_json(CUSTOM_DICT_FILE, custom_guide)
print(f"{YELLOW}Successfully deleted '{choice}'.{RESET}")
if choice == "all":
confirm = input(f"{RED}Are you sure you want to delete ALL custom imports? (y/n): {RESET}").strip().lower()
if confirm == 'y':
custom_guide.clear()
save_json(CUSTOM_DICT_FILE, custom_guide)
print(f"{YELLOW}Successfully deleted all custom imports.{RESET}")
pause()
elif choice:
print(f"{RED}Command not found in custom imports.{RESET}")
deleted = []
not_found = []
for cmd in [c.strip() for c in choice.split(",") if c.strip()]:
if cmd in custom_guide:
del custom_guide[cmd]
deleted.append(cmd)
else:
not_found.append(cmd)

    if deleted:
        save_json(CUSTOM_DICT_FILE, custom_guide)
        print(f"{YELLOW}Successfully deleted: {', '.join(deleted)}{RESET}")
    if not_found:
        print(f"{RED}Not found in custom imports: {', '.join(not_found)}{RESET}")
    pause()

gemini-code-assist Bot
1 minute ago
Contributor
medium

There are two improvement opportunities here:

Encapsulation: Instead of calling save_json(CUSTOM_DICT_FILE, custom_guide) directly, we should use the state_manager.save_custom() method to respect the encapsulation of the StateManager class.
Duplicate Handling: If the user inputs duplicate commands in the comma-separated list (e.g., ls, ls), the second occurrence will trigger the not_found block and display a confusing message. We can use dict.fromkeys to deduplicate the input list while preserving the user's input order.
choice = input(f"\n{GREEN}➜ {RESET}").strip().lower()\n if choice == "all":\n confirm = input(f"{RED}Are you sure you want to delete ALL custom imports? (y/n): {RESET}").strip().lower()\n if confirm == 'y':\n custom_guide.clear()\n state_manager.save_custom()\n print(f"{YELLOW}Successfully deleted all custom imports.{RESET}")\n pause()\n elif choice:\n deleted = []\n not_found = []\n for cmd in dict.fromkeys(c.strip() for c in choice.split(",") if c.strip()):\n if cmd in custom_guide:\n del custom_guide[cmd]\n deleted.append(cmd)\n else:\n not_found.append(cmd)\n\n if deleted:\n state_manager.save_custom()\n print(f"{YELLOW}Successfully deleted: {', '.join(deleted)}{RESET}")\n if not_found:\n print(f"{RED}Not found in custom imports: {', '.join(not_found)}{RESET}")\n pause()

Addressed both issues. Removed the redundant pause() which removes the extra step, and added .lower() to the search choice to correctly match known commands.

- Remove redundant pause() in explore_category and lowercase search string
- Use state_manager.save_custom() for encapsulation in manage_imports
- Deduplicate user input list to prevent duplicate 'not found' errors

Co-authored-by: MnemOnicE <170563909+MnemOnicE@users.noreply.github.com>
@MnemOnicE MnemOnicE merged commit 65c0ef6 into main Jun 9, 2026
7 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant