Skip to content

fix: correct command tab completion - #32

Merged
ryanbarlow97 merged 1 commit into
mainfrom
fix/command-tab-completion-20261015
Oct 15, 2026
Merged

ryanbarlow97 merged 1 commit into
mainfrom
fix/command-tab-completion-20261015

Conversation

@ryanbarlow97

Copy link
Copy Markdown
Contributor

Correct command suggestions to match the arguments accepted by Woodworking, including the current prefix and applicable permission or sender context.

  • WW-01: Only admins get command suggestions; console can complete reload, while project selection is player-only.

Validation: tfmc-mvn -o -B --no-transfer-progress clean verify passed (31 tests, zero failures, errors or skips), including command-completion regressions. git diff --check passed.

Documentation: TF-Minecraft/Docs#266.

@github-actions github-actions Bot added the size:XS 0-9 effective changed lines (tests excluded in mixed PRs). label Oct 15, 2026
@coderabbitai

coderabbitai Bot commented Oct 15, 2026 •

Copy link
Copy Markdown

Review in Change Stack →

No actionable comments were generated in the recent review. 🎉

ℹ️ Recent review info
⚙️ Run configuration
  • Configuration used: Organization UI
  • Review profile: CHILL
  • Plan: Advanced
  • Run ID: 04be3574-8ca0-4d8f-aa5d-5dd60e69a5d3
📥 Commits

Reviewing files that changed from the base of the PR and between 98ba080 and e379212.

📒 Files selected for processing: 2
  • src/main/java/net/tfminecraft/woodworking/command/CommandManager.java
  • src/test/java/net/tfminecraft/woodworking/LoadersCommandsTest.java

Included review availability: This review used your included allowance. Your plan provides up to 1 included review per hour; 0 remain after this review.

📝 Summary

Summary by CodeRabbit

  • Bug Fixes
    • Tab-completion suggestions for woodworking commands are now restricted to administrators.
    • The select command is no longer suggested to non-player senders, and project IDs are not suggested to them. Players with administrator permissions can still receive matching project suggestions, up to the existing limit.

Tab completion now filters suggestions based on sender permissions and whether the sender is a player. Tests cover command suggestions, project-ID suggestions, prefix matching, and the 40-project limit.

Changes: Tab completion

Layer / File(s) Summary
Sender-aware completion rules
src/main/java/net/tfminecraft/woodworking/command/CommandManager.java, src/test/java/net/tfminecraft/woodworking/LoadersCommandsTest.java
Non-admin senders receive no suggestions. Non-player senders do not receive select or project-ID suggestions. Tests cover sender-specific results, prefix matching, and the 40-project limit.

Priority: ⬇️ Low

Estimated code review effort: 2 (Simple) | ~10 minutes

Change: Bug fix

Merge Risk: ⚪ Minimal · up to e3792

Suggestions follow the command’s permission and sender-type rules: admins can complete reload, while select and project IDs are limited to players. No actionable merge-blocking risk remains.

- [ ] Autofix · Keep fixing CodeRabbit findings and required CI, and resolving merge conflicts

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.

@ryanbarlow97
ryanbarlow97 merged commit 6920177 into main Oct 15, 2026
4 checks passed
@ryanbarlow97
ryanbarlow97 deleted the fix/command-tab-completion-20261015 branch October 15, 2026 18:49
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

size:XS 0-9 effective changed lines (tests excluded in mixed PRs).

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant