hasura / hasura/graphql-engine

[Data Connectors] Invlaid OpenAPI null value

Open
#9,339 0 comments 1 reaction 0 assignees View on GitHub
k/bug t/data-connectors
Dominant language
TypeScript
Stars
32.1k
Forks
3k
PR merge metrics
PR metrics pending

Description

### Version Information

### Environment

Hasura 2.16.1

### What is the current behaviour?
When trying to generate OpenAPI server from data-connector [schema](https://github.com/hasura/graphql-engine/blob/master/dc-agents/dc-api-types/src/agent.openapi.json), this error throws:
```
Structural error at components.schemas.NullColumnFieldValue.type
should be equal to one of the allowed values
allowedValues: array, boolean, integer, number, object, string
```

### What is the expected behaviour?

Data connector schema should comply with OAS 3.0 spec

### How to reproduce the issue?

1. Open https://editor.swagger.io/
2. Insert agent.openapi.json contents
3. Accept conversion from JSON to YAML
4. See errors and warnings

### Keywords

dc, data-connector, openapi

Contributor guide

Open the contributing guide

Research direction

Start with dc-agents/dc-api-types/src/agent.openapi.json, then reproduce the validation error in Swagger Editor using the linked schema. Inspect the NullColumnFieldValue.type definition and verify the schema complies with the OAS 3.0 allowed type values; revalidate the complete document to confirm the error is gone.

Written by the indexing model from the issue text.

Assessment

Tech stack
openapi
Domain
api
Issue type
Bug
Difficulty
2/5
Estimated time
1-3 hours
Activity status
Stale
Clarity
Clearly specified
Newbie friendliness
55/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.