Uploaded image for project: 'Couchbase Go SDK'
  1. Couchbase Go SDK
  2. GOCBC-1095

View error contents parsed incorrectly

    XMLWordPrintable

Details

    • Bug
    • Resolution: Fixed
    • Major
    • core-10.0.0, core-9.1.5
    • None
    • None
    • None
    • 1

    Description

      		if err := json.Unmarshal(respBody, &errsArr); err != nil {
      			errorDescs = make([]ViewQueryErrorDesc, len(errsArr))
      			for errIdx, errMessage := range errsArr {
      				errorDescs[errIdx] = ViewQueryErrorDesc{
      					SourceNode: "",
      					Message:    errMessage,
      				}
      			}
      		} else if err := json.Unmarshal(respBody, &errsMap); err != nil {
      			for errNode, errMessage := range errsMap {
      				errorDescs = append(errorDescs, ViewQueryErrorDesc{
      					SourceNode: errNode,
      					Message:    errMessage,
      				})
      			}
      		}
      

      These checks should both be `err == nil`

      Attachments

        Issue Links

          Activity

            People

              charles.dixon Charles Dixon
              charles.dixon Charles Dixon
              Votes:
              0 Vote for this issue
              Watchers:
              1 Start watching this issue

              Dates

                Created:
                Updated:
                Resolved:

                PagerDuty