beanlab / quest_framework

A Python framework for fault-tolerant workflows
1 stars 0 forks source link

Upgrade `main.py` to use numGuessGame and multiple workflows #26

Open ABCambridge opened 8 months ago

ABCambridge commented 8 months ago

Improve main.py to use the number guessing game. As part of this, you'll want to have multiple games (workflows) started and display how they can all be interacted with through the same WorkflowManager and the manager can exit, be resumed, and all three workflows are ready and waiting at the same spot. See Professor Bean's description here:

Now that we are using workflow manager, the demo really should show multiple workflows running concurrently—i.e. something like:

  • two workflows are started at the same time
  • one is advanced, but the other one isn't
  • a third workflow is started and advanced twice
  • the context exits
  • the context enters and the three workflows are all at their expected states
  • each workflow is now run to completion
ABCambridge commented 8 months ago

I will be developing this on my andrew/sigint-handling branch so that I have the functionality of using ctrl-C when writing the new files.

ABCambridge commented 8 months ago

As of 03/16/2024 the main.py file using multiple workflows, with multiple async with contexts for the WorkflowManager. It successfully executes, suspends, resumes, completes, and replays the workflows. However, there are no assertion statements yet.

ABCambridge commented 8 months ago

This task has been completed for a few days as of 03/22/2024, but is waiting for the completion of the sigint handling branch because I developed this task on top of the sigint handling branch so I could use Ctrl+C when testing things.

ABCambridge commented 8 months ago

This is not yet merged because it is blocked by the sigint handling branch, but it is fully working of course and Dr. Bean didn't requested any changes, so I am marking it s complete.