Skip to content

Feature request: A way to determine which node may have thrown an exception during tick #990

@EzraBrooks

Description

@EzraBrooks

Is your feature request related to a problem? Please describe.

Our product utilizes BehaviorTree.CPP as our behavior tree runtime, and we've had multiple customers run into issues either in our product or their own customizations of it where a behavior throws an exception for whatever reason. The tree fails, but it's not clear which behavior did it. As far as I've been able to tell, there's no clear way to determine which node(s) may have been the culprit when an exception is thrown during .tickOnce().

Describe the solution you'd like

A way to know which behavior was ticked last in the tree, which is at least a way we can suggest to a consumer "this behavior might be the culprit". Does this already exist and I'm just missing it?

Describe alternatives you've considered

If I were solving this problem green-field, I would probably make the Node base classes catch and re-throw exceptions with some annotation in their message saying which behavior it came from. But that might be too invasive for an existing project with existing conventions.

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