Skip to content

Search response unmarshal issues #436

@candiduslynx

Description

@candiduslynx

Description

There are several issues with SearchResponse unmarshaling:

  1. These lines are always defaulting to in.Interface() path per v55 being nil interface
  2. There's no way to properly unmarshal uint64 value (in.Interface() -> in.Float64() that loses precision)

Expected behavior

  1. SearchResponse.Hits unmarshaling should be addressed
  2. It should be possible to unmarshal even the largest uint64 value (math.MaxUint64)

Current behavior

  1. SearchResponse.Hits always goes with in.Interface() path
  2. math.MaxUint64 value will lose precision per unmarshaling as float64

Screenshots or Logs

Stored value: uint64(18446744073709551615)
Scanned value: float64(9223372036854775808)

Environment (please complete the following information):

  • OS: Linux
  • Meilisearch version: v1.1.0
  • meilisearch-go version: v0.24.0

Metadata

Metadata

Assignees

No one assigned

    Labels

    bugSomething isn't working

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions