Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[proposal] Implement the FileType API and improve its documentation #779

Open
nberlette opened this issue Jan 1, 2025 · 0 comments
Open

Comments

@nberlette
Copy link

Hi,

I wanted to bring up an issue with the FileType API. Despite its name and documentation suggesting it supports file handling, the implementation is currently just an alias for StringType and doesn’t handle completions for actual files.

This behavior can be confusing, especially for newcomers, given the conflicting documentation references. For example, the doc comment on the FileType class currently states that it deals with integers, which appears to be a copy-paste error and only adds to the confusion.

I’m also curious whether file completions, if implemented, are intended to be relative to the command’s working directory.

I’m currently working on a project that needs this feature and have already started prototyping an implementation. If there’s interest, I’d be happy to polish it further with unit tests and submit a PR for review.

Thanks for your time!

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

No branches or pull requests

1 participant