Skip to content

JSON String mutations are now type inferred #2735

@billylindeman

Description

@billylindeman
  • What version of Dgraph are you using?
    1.0.10

  • Have you tried reproducing the issue with latest release?
    was not present before 1.0.10

  • What is the hardware spec (RAM, OS)?
    macbook pro 2016

  • Expected behaviour and actual result.
    When saving a predicate with JSON, the JSON type should be respected.

In #2627 , this code block is added
https://github.com/dgraph-io/dgraph/pull/2627/files#diff-5c560e7723a3bc51e26d863bfa4257bdR136

It seems that this alters the default behavior for parsing json string predicates. In the past strings would be stored as string type predicates, and now it seems that some type guessing is applied on the first mutation.

The comment in that block seem to indicate that this is not the expected behavior for JSON strings.

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