You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Correct command suggestions to match accepted DenarEconomy arguments, sender permissions and the current token.
DECO-01: Replace give target placeholder with sorted online active-character account names and remove literal amount placeholders; keep coin types and bank/pouch options with permission and prefix matching.
DECO-02: Complete staff history targets, cached character names/UUIDs, known ledger IDs, and unclaimed legacy owner IDs followed by their own character IDs. Only eligible account/move/legacy argument completions request a coalesced next-task refresh of cold, dirty or 100-tick-old snapshots. Saved-player UUID discovery runs once on first demand; join events retain later owners even if they disconnect before a refresh. History remains online-only, and multiword names return only the replacement suffix.
Ledger/directory snapshots are lazy, coalesced and refreshed on demand after a 100-tick TTL or relevant changes. Startup and idle ticks perform no completion discovery. A one-time saved-owner index plus join UUID tracking preserves offline candidates without repeated saved-player enumeration. Tab handling queries neither ledger nor saved-player profiles.
Validation: tfmc-mvn -o -B --no-transfer-progress clean verify passed (273 tests, zero failures/errors/skips); 56 focused tests passed. Existing 100% line/branch/instruction gates and git diff --check passed. Regression proofs cover cold/warm/idle behavior, join/logout between refreshes, legacy ownership, permissions and multiword suffixes.
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
New Features
Added context-aware command suggestions for character names and IDs, ledger accounts, and unclaimed legacy accounts.
Suggestions now refresh after player joins and successful account operations, with case-insensitive matching.
Empty or unmatched completion requests now return no suggestions instead of placeholders.
Command completion now suggests eligible players, characters, ledger accounts and unclaimed legacy accounts. Candidate snapshots refresh on demand and after specified events or successful operations.
Changes: Command Completion
Layer / File(s)
Summary
Build and refresh completion snapshots src/main/java/net/tfminecraft/denareconomy/DenarEconomy.java, src/main/java/net/tfminecraft/denareconomy/managers/CommandManager.java, src/test/java/net/tfminecraft/denareconomy/managers/CommandManagerTest.java
Startup registers the completion listener. CommandManager schedules snapshot builds and marks the cache dirty after player joins and successful give, legacy claim and move operations. Tests cover deferred discovery and refresh behaviour.
Provide command suggestions src/main/java/net/tfminecraft/denareconomy/managers/CommandManager.java, src/test/java/net/tfminecraft/denareconomy/managers/CommandManagerTest.java
Completion now returns matching player, character, account and unclaimed-owner suggestions. Tests cover filtering, eligibility, permissions and refreshed suggestions.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
size:L100-499 effective changed lines (tests excluded in mixed PRs).
1 participant
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Correct command suggestions to match accepted DenarEconomy arguments, sender permissions and the current token.
DECO-01: Replace give target placeholder with sorted online active-character account names and remove literal amount placeholders; keep coin types and bank/pouch options with permission and prefix matching.DECO-02: Complete staff history targets, cached character names/UUIDs, known ledger IDs, and unclaimed legacy owner IDs followed by their own character IDs. Only eligible account/move/legacy argument completions request a coalesced next-task refresh of cold, dirty or 100-tick-old snapshots. Saved-player UUID discovery runs once on first demand; join events retain later owners even if they disconnect before a refresh. History remains online-only, and multiword names return only the replacement suffix.DECO-03: Return explicit empty pouch completion, suppressing Paper/Bukkit online-player fallback.Ledger/directory snapshots are lazy, coalesced and refreshed on demand after a 100-tick TTL or relevant changes. Startup and idle ticks perform no completion discovery. A one-time saved-owner index plus join UUID tracking preserves offline candidates without repeated saved-player enumeration. Tab handling queries neither ledger nor saved-player profiles.
Validation:
tfmc-mvn -o -B --no-transfer-progress clean verifypassed (273 tests, zero failures/errors/skips); 56 focused tests passed. Existing 100% line/branch/instruction gates andgit diff --checkpassed. Regression proofs cover cold/warm/idle behavior, join/logout between refreshes, legacy ownership, permissions and multiword suffixes.Documentation: TF-Minecraft/Docs#266.