Skip to content

[CLI] Improve hive dev errors #8017

@n1ru4l

Description

@n1ru4l

The error for the hive dev and hive introspect commands can be misleading.

Both commands partially rely on introspecting federation subgraphs (via the Query._service field) or normal GraphQ introspection (via the GraphQL introspection query).

There is many error cases that could occur:

  • GraphQL introspection is disabled
  • The target is expected to be a federation subgraph but is not (Query._service is missing)
  • Network errors etc.

We need to revise the whole flow and errors and need to make sure it is obvious whether an error originates from HTTP calls/responses to the subgraph or our API (in case of the dev command).

Right now we have mixed logic and error classes and it can happen that something that an error originating from a subgraph is displayed as a Hive Console API error which is misleading.

In order to solve this technically, we first need to analyze which things can go wrong for each flow and define all the errors for those flows.

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