mirror of
https://github.com/NousResearch/hermes-agent.git
synced 2026-04-25 00:51:20 +00:00
fix: remove @staticmethod from _context_completions — crashes on @ mention
PR #9467 added a call to self._fuzzy_file_completions() inside _context_completions(), but the method was still decorated with @staticmethod and didn't receive self. Every @ mention in the input triggers 'name self is not defined' from prompt_toolkit's async completer, spamming the error on every keystroke. Fix: remove @staticmethod, add self parameter. The method already uses self._fuzzy_file_completions() and self._get_project_files() via that call chain, so it was never meant to stay static after the fuzzy search feature was added.
This commit is contained in:
parent
4610551d74
commit
677f1227c3
1 changed files with 1 additions and 2 deletions
|
|
@ -844,8 +844,7 @@ class SlashCommandCompleter(Completer):
|
||||||
return None
|
return None
|
||||||
return word
|
return word
|
||||||
|
|
||||||
@staticmethod
|
def _context_completions(self, word: str, limit: int = 30):
|
||||||
def _context_completions(word: str, limit: int = 30):
|
|
||||||
"""Yield Claude Code-style @ context completions.
|
"""Yield Claude Code-style @ context completions.
|
||||||
|
|
||||||
Bare ``@`` or ``@partial`` shows static references and matching
|
Bare ``@`` or ``@partial`` shows static references and matching
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue