这是indexloc提供的服务,不要输入任何密码
Skip to content

Actions causing introspection to break #5166

@tirumaraiselvan

Description

@tirumaraiselvan

Hasura: v1.3.0-beta.2 (possibly before as well)

Reported in: https://app.intercom.com/a/apps/rucirpb3/inbox/inbox/mentions/conversations/61371600000816

Suppose I have two actions and my hasura metadata is:

{
  "version": 2,
  "tables": [],
  "actions": [
    {
      "name": "actionName",
      "definition": {
        "handler": "http://localhost:3000",
        "output_type": "SampleOutput",
        "arguments": [
          {
            "name": "text",
            "type": "jsonb!"
          },
          {
            "name": "attributes",
            "type": "String!"
          }
        ],
        "type": "mutation",
        "kind": "synchronous"
      }
    },
    {
      "name": "actionName2",
      "definition": {
        "handler": "http://localhost:3000",
        "output_type": "SampleOutput2",
        "arguments": [
          {
            "name": "a",
            "type": "ID!"
          },
          {
            "name": "b",
            "type": "ID!"
          }
        ],
        "type": "mutation",
        "kind": "synchronous"
      }
    }
  ],
  "custom_types": {
    "input_objects": [
      {
        "name": "SampleInput",
        "fields": [
          {
            "name": "username",
            "type": "String!"
          },
          {
            "name": "password",
            "type": "String!"
          }
        ]
      }
    ],
    "objects": [
      {
        "name": "SampleOutput",
        "fields": [
          {
            "name": "id",
            "type": "String!"
          }
        ]
      },
      {
        "name": "SampleOutput2",
        "fields": [
          {
            "name": "id",
            "type": "String!"
          }
        ]
      }
    ]
  }
}

This breaks introspection with error: {"errors":[{"extensions":{"path":"$","code":"unexpected"},"message":"type info not found for: 'jsonb'"}]}

Metadata

Metadata

Assignees

Labels

c/serverRelated to serverk/bugSomething isn't working

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions