Skip to content

Groot2 1.9.0: Switch2 built-in model contains duplicate case_1 input port #103

Description

@soohwan-justin

Description

In Groot2 1.9.0, the built-in Switch2 model displays four input ports:

  • case_1
  • case_2
  • case_1 (duplicate)
  • variable
Image

The duplicate is present in Groot2's embedded builtin_nodes_v4.xml, rather than in the user's project model.

Steps to reproduce

  1. Start Groot2 1.9.0 in Editor mode.
  2. Find or insert the built-in Switch2 control node.
  3. Inspect its input ports.

Actual embedded model

<Control ID="Switch2">
    <input_port name="case_1" type="std::string"/>
    <input_port name="case_2" type="std::string"/>
    <input_port name="case_1" type="std::string"/>
    <input_port name="variable" type="std::string"/>
</Control>

Expected model

<Control ID="Switch2">
    <input_port name="case_1" type="std::string"/>
    <input_port name="case_2" type="std::string"/>
    <input_port name="variable" type="std::string"/>
</Control>

BehaviorTree.CPP's SwitchNode<2>::providedPorts() and the output of bt4_nodes_model --include-builtin both contain the expected three distinct ports, so the issue appears isolated to Groot2's bundled v4 node-model resource. The bundled definitions for Switch3 through Switch6 are also correct.

Suggested fix

Remove the second duplicated line:

<input_port name="case_1" type="std::string"/>

from the Switch2 entry in builtin_nodes_v4.xml.

Environment

  • Groot2: 1.9.0
  • OS: Ubuntu 20.04.6 LTS
  • Architecture: x86_64

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