Skip to content

ambiguous error #59

@tanner0101

Description

@tanner0101

Code

try json.get("permissions") as [String]

Input

{
	"userId": "xxx"
}

Error

{
  "debugReason": "No value found at path '', expected 'String'",
  "error": true,
  "identifier": "Node.NodeError.unableToConvert",
  "possibleCauses": [
    "typo in key path",
    "underlying type is not convertible",
    "unexpected '.' being interpreted as path instead of key"
  ],
  "reason": "Internal Server Error",
  "suggestedFixes": [
    "called `get(...)` on a key or key path that does not exist in the data",
    "the data being parsed is missing required values or is incorrectly formatted",
    "found unconvertible data, e.g., got a string of letters when an integer is required",
    "if you have keys containing a '.' that shouldn't be interpreted as a path, use 'DotKey(\"actual.key\")'"
  ]
}

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions