Skip to content

Filter Error/Warning Reporting #1091

@dj-bauer

Description

@dj-bauer

Currently a filter can report an error with their configuration (at best called when they're refreshed) through AddErrorMessage(title, message).

I suggest more generic approach with different Message severity.

  • Info (green)
  • Warning (yellow)
  • Error (red)

Perhaps the UI could expose a switch what minimum severity to display.
I suppose a forth lowest option "Debug" (blue) could also be an option.

That change would require the following adjustment.

  1. Creation of a FlowGraphNodeMessage struct containing the attributes title, message, severity
  2. Removing the current m_errorLog and m_errorTitle members in FlowGraphNode.
  3. Adding a m_messages of type std::vector<FlowGraphNodeMessage> I don't see many messages in one single node requiring a more sophisticated data structure
  4. Remove GetErrorLog and GetErrorTitle and instead implement GetMostUrgentMessage(), which goes through the messages and returns the most urgent one
  5. Propably another Helper for GetHighestMessageSeverity(), which acts on the severity of GetMostUrgentMessage. Can be used for the drawing code in FilterGraphEditor.
  6. A Base method for AddMessage to the FlowGraphNode, which takes a created FlowGraphNodeMessage and then respective specializations for each severity, which only require a title and message following the current implementation of AddErrorMessage
  7. Modify the FilterGraphEditor ngscopeclient drawing to take the highest severity message and simply adjust the color.
  8. Modify the Errors-Pane in ngscopeclient to the new API

Further work would then include extending the Errors-Pane in ngscopeclient to include a column severity and the option to sort by that.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type
    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions