Skip to content

Sendable Chooser returns default option despite correct option selected #775

@VincentZhao12

Description

@VincentZhao12

Note this is all from memory as our team hasn't been back in the lab since this issue occurred

We set up our SendableChooser as WPILib does in their CommandBased Choosing an Autonomous Program tutorial. Throughout our competition, we've been able to properly select autonomous routines this way, except for two matches. During those matches, the robot ran the default option of the SendableChooser rather than the selected path. When tested in pits, the SendableChooser appeared with a checkmark next to it however it still ran the default path rather than the selected one. No code was changed between matches before issue occurred. Returning the command we wanted directly from where we said autonSelector.getSelected() solved the issue, however we don't want to have to resort to using that and switching out between every match.

WPILib Java, Version 2023.4.2
Roborio Version 2023_v3.2

Shuffleboard Log files from around the time that the issue occurred.

shuffleboard.2023-03-19-15.39.47.log
shuffleboard.2023-03-19-15.39.18.log

Match Videos from about when the issue occurred:
First Occurrence
Second Occurrence

Match Video of expected behavior, one match before the issue occurred:
Video

Match Video of just returning the command rather than the result of the SendableChooser:
Video

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions