Skip to content

Improve error message when submitting a process #41

Description

@sphuber

Currently when submitting a process and the inputs are incorrect (for example label is missing, which shouldn't really even be required), the error message is not very useful.
We simply get a

422 Unprocessable Entity
{'detail': [{'loc': ['body', 'label'], 'msg': 'field required', 'type': 'value_error.missing'}]}

It should ideally tell what data is missing.

Activity

  1. sphuber commented on Nov 14, 2022

    @sphuber
    ContributorAuthor

    Turns out that the information is in the response, just hidden. In the example mentioned above, the label was missing. But maybe we can extract this from response['detail'][0]['loc'][-1] but not sure how fixed the format of this response is.

  2. ltalirz commented on Nov 14, 2022

    @ltalirz
    Member

    maybe a more generic printing of the detail field could do the trick?

  3. edan-bainglass commented on Jul 30, 2026

    @edan-bainglass
    Member

    Covered by #158, but may be improved further in a later PR

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    graphQLRelated to graphQL API

    Type

    No type

    Fields

    Priority

    None yet

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions