Skip to content

"database query error" when fetching block height #65

@merc1er

Description

@merc1er

When fetching the block height with:

curl -X POST \
  -H "Content-Type: application/json" \
  -d '{"query": "query GetBlockheight($node: String!) { block(limit: 1, order_by: { height: desc }, where: { accepted_by: { node: { name: { _like: $node } } } }) { height } }", "variables": { "node": "%testnet" }}' \
  https://demo.chaingraph.cash/v1/graphql

the following response is returned:

{
  "errors": [
    {
      "extensions": {
        "code": "unexpected",
        "path": "$"
      },
      "message": "database query error"
    }
  ]
}

Note that the returned status code is 200 "OK". Also note that the same query works with mainnet.

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