code: func IsUnexpectedServerError(err error) bool {
  	switch t := err.(type) {
  	case APIStatus:
  		if d := t.Status().Details; d != nil {
  			for _, cause := range d.Causes {
  				if cause.Type == metav1.CauseTypeUnexpectedServerResponse {
  					return true
  				}
  			}
  		}
  	}
  	return false
  }
docs: // IsUnexpectedServerError returns true if the server response was not in the expected API format,
  // and may be the result of another HTTP actor.