Skip to content

How to show an option to stop the progress after the progress has started #132

@shirishpandharikar

Description

@shirishpandharikar

We have a requirement where we monitor the progress of background tasks via events. The progress bar works just fine. We have a requirement where in we also need to show the user an option to stop the background task. For this we want to show the user a prompt on the console E.g. Press X to exit: after the progress is displayed. How can this be achieved? The progress bar seems to take over and the user is not able to input anything. Below is how we expect it

0% [>                                  ]    243/100000  (0:00:12 / 1:23:51)
Press X to exit: 

If the user inputs X and presses enter the program will stop the background task and exit. Any help here would be really appreciated.

Metadata

Metadata

Assignees

No one assigned

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions