CDRH / api

Codenamed "Apium": An API to access all public Center for Digital Research in the Humanities resources
https://cdrhdev1.unl.edu/api_frontend
MIT License
3 stars 1 forks source link

can't facet by date_display #122

Open karindalziel opened 2 years ago

karindalziel commented 2 years ago

If I try to facet by date_display I get an error

https://cdrhdev1.unl.edu/api/v1/collection/stories_humanity/items?num=0&facet[]=date_display

 "res": {
    "code": 500,
    "message": "Something went wrong",
    "info": {
      "documentation": "TODO",
      "error": {
        "error": {
          "root_cause": [
            {
              "type": "illegal_argument_exception",
              "reason": "Field [date_display] of type [keyword] does not support custom formats"
            }
          ],
          "type": "search_phase_execution_exception",
          "reason": "all shards failed",
          "phase": "query",
          "grouped": true,
          "failed_shards": [
            {
              "shard": 0,
              "index": "cdrhapidev-v1.2",
              "node": "GfGYxyE8QlCry-BboNpfyw",
              "reason": {
                "type": "illegal_argument_exception",
                "reason": "Field [date_display] of type [keyword] does not support custom formats"
              }
            }
          ],
          "caused_by": {
            "type": "illegal_argument_exception",
            "reason": "Field [date_display] of type [keyword] does not support custom formats",
            "caused_by": {
              "type": "illegal_argument_exception",
              "reason": "Field [date_display] of type [keyword] does not support custom formats"
            }
          }
        },
        "status": 400
      },
      "suggestion": "TODO"
    }
  }
wkdewey commented 2 years ago

One relevant post for the error: https://discuss.elastic.co/t/es-7-4-field-start-time-of-type-keyword-does-not-support-custom-formats/241554

wkdewey commented 2 years ago

Is faceting by date_display useful in projects?