-
Notifications
You must be signed in to change notification settings - Fork 34
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
Replace intermediate states with conditional transitions #689
base: main
Are you sure you want to change the base?
Conversation
"dest": self.monitor_state, | ||
"conditions": self._start_task, | ||
}, | ||
{ |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This transition is basically the "else" which is run if the conditional above returns false. In this case, if it fails to continue the mission (for instance if there are no more tasks) it will go to the idle state and run the "_full_mission_finished" cleanup function.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The same is true for the transition from idle to idle. This is for when we fail to start a mission.
return False | ||
return True | ||
|
||
def _try_start_mission(self) -> bool: |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This contains the functionality that used to the in the initiate and intialisation states
d804d72
to
e2c9adb
Compare
424c1fe
to
c86e736
Compare
c86e736
to
6f1c904
Compare
Closes #687
Ready for review checklist: