I would use a combination of
http://docs.fabfile.org/en/1.12/usage/env.html#abort-on-prompts and
http://docs.fabfile.org/en/1.12/usage/env.html#abort-exception to have
Fabric throw a custom exception when it has to prompt, which I would
subsequently catch and handle myself based on context.

On Mon, Dec 5, 2016 at 1:12 AM Prasant J <[email protected]> wrote:

> Hi,
>
> I'm writing a python GUI that uses fabric as library and performs
> operations on the remote host.
>
> When the user supplies wrong password, then fabric asks for user to
> provide password on the command line. The control drops to the command
> line and the prompt is expecting user to input the password and this
> does not go well with my GUI application.
>
> How can I prevent this? How can fabric return exception or error when
> password supplied is wrong. Basically fabric should give up on the
> first attempt when password is incorrect.
>
> Is there any way around this?
>
> Any inputs will be of help!
>
>
> Regards, Pj
>
> _______________________________________________
> Fab-user mailing list
> [email protected]
> https://lists.nongnu.org/mailman/listinfo/fab-user
>
_______________________________________________
Fab-user mailing list
[email protected]
https://lists.nongnu.org/mailman/listinfo/fab-user

Reply via email to