Skip to content

Error message provides insufficient context #110

Description

@nikku

Describe the Bug

Our validation reports errors that are hard to impossible to comprehend by a user. For example, given the following template what is broken is that feel is not compatible to type=Dropdown. What is reported is that (without context) type=String|Text are the only compatible options, rather than highlighting that feel is not supported for Dropdown:

{
  "$schema": "https://unpkg.com/browse/@camunda/zeebe-element-templates-json-schema/resources/schema.json",
  "name": "Connector Name",
  "id": "connector-id",
  "appliesTo": ["bpmn:Task"],
  "properties": [
    {
      "label": "Some label",
      "type": "Dropdown",
      "feel": "optional",
      "binding": {
          "type": "zeebe:input",
          "name": "variableName",
          "key": "asd"
      },
      "choices": [],
      "value": "=default expression"
    }
  ]
}

Steps to Reproduce

  1. Open above template
  2. See that validation marks property.type=Dropdown as invalid

Expected Behavior

We validate feel instead; it is not compatible with property.type=Dropdown.

Environment

  • Host (Browser/Node version), if applicable: Any
  • OS: Any
  • Library version: v0.12.0

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Fields

    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