Method used to build prompts under the hood does not allow for full format customization · Issue #2875 · pallets/click · GitHub
More Web Proxy on the site http://driver.im/
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
Currently method _build_prompt is implemented in very opinionated way regarding formatting how to display choices or default value. Considering how good of a job the rest of the features do in regards to potential extensions and customizations, I am surprised that the best way I found to customize this method is to overwrite it before use, for example as follows:
Even though it is "technically" possible to override, I'd argue the fact that in order to find it I had to dig deep into codebase and find the details of implementation feels "hacky" and "not intended" - and for sure error prone and not future-proof.
I am very happy to contribute and implement the solution, but I'd rather hear some opinions from the library owners beforehand whether this is something they'd find valuable.
The text was updated successfully, but these errors were encountered:
In general, I am open to new community sourced ideas, and I appreciate the effort you put into this. However, Click is so widely used, that I would like to have more comprehensive docs and better test coverage before anything major is added, unless there is very clear community support. I will continue to keep an eye on this to see if it gathers community support.
Currently method
_build_prompt
is implemented in very opinionated way regarding formatting how to display choices or default value. Considering how good of a job the rest of the features do in regards to potential extensions and customizations, I am surprised that the best way I found to customize this method is to overwrite it before use, for example as follows:Even though it is "technically" possible to override, I'd argue the fact that in order to find it I had to dig deep into codebase and find the details of implementation feels "hacky" and "not intended" - and for sure error prone and not future-proof.
I am very happy to contribute and implement the solution, but I'd rather hear some opinions from the library owners beforehand whether this is something they'd find valuable.
The text was updated successfully, but these errors were encountered: