prompt-toolkit / prompt-toolkit/python-prompt-toolkit
Triggering Completer when calling CommandLineInterface.read_input()?
Nobody has claimed this yet.
- Dominant language
- Python
- Stars
- 10.6k
- Forks
- 815
- PR merge metrics
- No merged PRs in 30d
Description
I'm hacking up a little utility and was looking through the examples, but couldn't figure out if there was a simple way to automatically bring up my Completer when calling CommandLineInterface.read_input() (w/o digging through the guts of the lib)?
Also, is there a way to also assign autocompletion to different keys (ie, to the down key as well perhaps)?
Lastly, I'm doing a rather ugly hack (reading a global List) to be able to dynamically populate the Completer - the completers are generated anonymously on every keystroke it looks like? Just want to make sure I'm not missing anything there...
Contributor guide
No contributing guide indexed for this repository
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Start with the examples and the CommandLineInterface.read_input() and Completer APIs to determine how completion is currently connected. Clarify whether the desired outcome is automatic completion, additional key bindings, dynamic completer data, or all three; done would require an agreed API and documented behavior for each supported case.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- python
- Domain
- cli
- Issue type
- Feature
- Difficulty
- 4/5
- Estimated time
- 3-5 days
- Activity status
- Stale
- Clarity
- Needs clarification
- Newbie friendliness
- 25/100