Page MenuHomePhabricator

[Segmentation] Crash in Segmentation View when switching tasks in a Segmentation Task List
Closed, ResolvedPublic

Description

When accepting a task while a segmentation tool is still active, it stays active for the automatically loaded next task (which is wanted behavior).

However, when the segmentation of the new task doesn't have any labels yet (tool buttons are now disabled), and another task is then manually loaded with an existing label (like the previous one again), the tool manager finds itself in an edge case where it is trying to unregister a tool twice.

This is kind of fine, since we just want to make sure to unregister the tool, and the second attempt is handled gracefully (except for an explicitly thrown std::logic_error afterwards).

I suggest to silently swallow the exception in this case as it results in the very same outcome. Otherwise we would probably loose the feature for inter-task active tools, which is a well received and requested feature by our users of the Segmentation Task List.

Revisions and Commits

rMITK MITK
Restricted Differential Revision