Skip to content

Example play to FSM#3402

Merged
williamckha merged 37 commits into
UBC-Thunderbots:masterfrom
someone2060:exampleplay-to-fsm
May 15, 2025
Merged

Example play to FSM#3402
williamckha merged 37 commits into
UBC-Thunderbots:masterfrom
someone2060:exampleplay-to-fsm

Conversation

@someone2060

Copy link
Copy Markdown
Contributor

Please fill out the following before requesting review on this PR

Description

Converts the Example Play from a co-routine to an FSM.

The example play was moved to its own folder, with appropriate BUILD files modified. This was done to maintain consistency with other FSMs.

Testing Done

example_play_test.cpp successfully passed, and Example Play successfully ran on Thunderscope.

Resolved Issues

resolves #3298

Length Justification and Key Files to Review

  • example_play.cpp and corresponding .h file
  • example_play_fsm.cpp and corresponding .h file
  • example/BUILD

Review Checklist

It is the reviewers responsibility to also make sure every item here has been covered

  • Function & Class comments: All function definitions (usually in the .h file) should have a javadoc style comment at the start of them. For examples, see the functions defined in thunderbots/software/geom. Similarly, all classes should have an associated Javadoc comment explaining the purpose of the class.
  • Remove all commented out code
  • Remove extra print statements: for example, those just used for testing
  • Resolve all TODO's: All TODO (or similar) statements should either be completed or associated with a github issue

someone2060 and others added 20 commits September 28, 2024 11:58
Remove Qt dependency from ER Force Simulator (UBC-Thunderbots#3311)
Merge main project to own branch
…cessary

Files still need to be refactored, which will be done in the next commit
… `halt_tactic.h`, renaming variables and strings where necessary

Variables and strings renamed for consistency and to allow tests to successfully run
`example_play_fsm.cpp` and associated files have not been implemented; planned to be implemented next commit
Still giving errors, as `example_play_fsm.cpp` has not been implemented
…play-to-fsm

# Conflicts:
#	src/software/ai/hl/stp/play/example/example_play_fsm.h
Debugging still necessary, as the `example_play_test.cpp` is not passing
test case works now yippee
@someone2060 someone2060 requested review from a team, GrayHoang and axiev1 and removed request for a team October 28, 2024 21:05

@williamckha williamckha left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Great work! The FSM looks good to me, just two comments

Comment thread src/software/ai/hl/stp/play/example/example_play_fsm.cpp Outdated
Comment thread src/software/ai/hl/stp/play/example/example_play_fsm.h Outdated
@williamckha williamckha removed the Stale Inactive pull requests label Jan 25, 2025
Comment thread src/software/ai/hl/stp/play/BUILD Outdated
cc_library(
name = "all_plays",
deps = [
<<<<<<< HEAD

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

looks like you've got merge conflict markers in here. Needs merge conflict fixing

from proto.ssl_gc_common_pb2 import Team


# TODO issue #2599 - Remove Duration parameter from test

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

this issue does not seem to exist. we may not need it

Comment on lines +73 to +79
[RobotSpeedEventuallyBelowThreshold(1e-3)]
],
ag_always_validation_sequence_set=[[]],
ag_eventually_validation_sequence_set=[
[RobotSpeedEventuallyBelowThreshold(1e-3)]
],
test_timeout_s=10,

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

instead, I think you should assert that the robots come within a 1 m radius of the ball

@itsarune itsarune left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

looks like you have a bad merge that you need to fix

@github-actions

Copy link
Copy Markdown
Contributor

This PR is stale because it has been open for 30 days with no activity. Remove stale label or comment or this will be closed in 5 days.

@github-actions github-actions Bot added the Stale Inactive pull requests label Mar 20, 2025
@GrayHoang GrayHoang removed the Stale Inactive pull requests label Mar 22, 2025
@github-actions

Copy link
Copy Markdown
Contributor

This PR is stale because it has been open for 30 days with no activity. Remove stale label or comment or this will be closed in 5 days.

@github-actions github-actions Bot added the Stale Inactive pull requests label Apr 22, 2025
@GrayHoang GrayHoang removed the Stale Inactive pull requests label Apr 25, 2025
williamckha
williamckha previously approved these changes May 15, 2025
@williamckha williamckha requested a review from GrayHoang May 15, 2025 19:49

@GrayHoang GrayHoang left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Previous approval carries forward

@williamckha williamckha merged commit d9b2017 into UBC-Thunderbots:master May 15, 2025
6 checks passed
@someone2060 someone2060 deleted the exampleplay-to-fsm branch August 24, 2025 03:25
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Convert ExamplePlay into an FSM play

4 participants