title: The exception was not handled due to missing onError handler in the subscribe() method call
body: <p>I am calling the request it self in a base class </p>
  
  <pre><code> @Override
  public Single&lt;BaseResponse&lt;D&gt;&gt; call() {
      Single&lt;BaseResponse&lt;D&gt;&gt; singleResponse =  Single.create(emitter -&gt; request().getAsOkHttpResponseAndParsed(typeToken(), new OkHttpResponseAndParsedRequestListener&lt;BaseData&lt;D&gt;&gt;() {
          @Override
          public void onResponse(Response okHttpResponse, BaseData&lt;D&gt; response) {
              try {
                  BaseResponse&lt;D&gt; r = new BaseResponse&lt;D&gt;(okHttpResponse) {
                  };
                  r.setData(response.getData());
                  r.setStatus(response.getStatus());
  
                  emitter.onSuccess(r);
              } catch (Throwable throwable) {
                  Log.e("error", "throwable");
                  emitter.onError(throwable);
              }
          }
  
          @Override
          public void onError(ANError anError) {
              Log.e("error", "error");
              emitter.onError(anError);
          }
      }));
  
      singleResponse.doOnSubscribe(__ -&gt;
              EspressoIdlingResource.countingIdlingResource.increment()).
              doFinally(EspressoIdlingResource.countingIdlingResource::decrement).subscribe();
      return singleResponse;
  }
  </code></pre>
  
  <p>then I have my single observer builder class</p>
  
  <pre><code>public class SingleObserverBuilder&lt;T&gt; extends BaseObserverBuilder&lt;T, SingleObserver&lt;T&gt;&gt; {
  
      private final Consumer&lt;Disposable&gt; disposableConsumer;
  
      public SingleObserverBuilder(@NonNull Consumer&lt;Disposable&gt; disposableConsumer) {
          this.disposableConsumer = disposableConsumer;
      }
  
      @Override
      public SingleObserver&lt;T&gt; build() {
          return new SingleObserver&lt;T&gt;() {
  
  
              @Override
              public void onSubscribe(Disposable d) {
                  disposableConsumer.accept(d);
              }
  
              @Override
              public void onSuccess(T t) {
                  if (onSuccessListeners() != null) {
                      for (Consumer&lt;T&gt; onSuccess : onSuccessListeners()) {
                          onSuccess.accept(t);
                      }
                  }
              }
  
              @Override
              public void onError(Throwable e) {
                  Log.e("error", "base error");
                  if (onFailureListeners() != null)
                      for (Consumer&lt;Throwable&gt; onFailure : onFailureListeners()) {
                          onFailure.accept(e);
                      }
              }
          };
      }
  }
  </code></pre>
  
  <p>and in my base observer fragment I access this single observer </p>
  
  <pre><code>public abstract class BaseObserverFragment extends Fragment {
  
      protected CompositeDisposable disposable = new CompositeDisposable();
  
      protected &lt;T&gt; SingleObserverBuilder&lt;T&gt; getDefaultSingleObserver(Object tag) {
          SingleObserverBuilder&lt;T&gt; builder = new SingleObserverBuilder&lt;&gt;(disposable -&gt; this.disposable.add(disposable));
          builder.tag(tag).onSuccess(object -&gt; {
              Logger.e(builder.tag().toString(), "onSuccess");
          }).onFailure(throwable -&gt; {
              Log.e("error", "base fragment");
  
              Logger.e(builder.tag().toString(), "onFailure");
              ErrorLogger.log(getContext(), builder.tag().toString(), throwable);
          });
          return builder;
      }
  
      @Override
      public void onDetach() {
          super.onDetach();
          if(!disposable.isDisposed()) {
              Log.e("error", "detach");
              disposable.clear();
              disposable.dispose();
          }
      }
  }
  </code></pre>
  
  <p>then in the fragment itself that's how I call api request </p>
  
  <pre><code> viewModel.setAvailabilityStatus(isAvailable)
              .subscribeOn(Schedulers.io())
              .observeOn(AndroidSchedulers.mainThread())
              .subscribe(this.&lt;BaseResponse&lt;ChangeSpAvailabilityResponse&gt;&gt;getDefaultSingleObserver(OperationTag.CHANGE_AVAILABILITY)
              .onSuccess(response -&gt; {
  
              })
              .onFailure( throwable -&gt; {
                  Log.e("error", "last");
                  if (throwable instanceof ANError) {
                      Log.e("error", "throwable");
                      if (((ANError) throwable).getErrorCode() == 400) {
                          ((ANError) throwable).getErrorBody();
                          handleChangeAvailabilityResponse(((ANError) throwable).getErrorAsObject(ChangeSpAvailabilityResponse.class));
                      }
                  }
              }).build());
  }
  </code></pre>
  
  <p>in that api request I wanna handle failure request body and it all work fine, but sometimes I get this error : </p>
  
  <blockquote>
    <p>The exception was not handled due to missing onError handler in the
    subscribe() method call. Further reading:
    <a href="https://github.com/ReactiveX/RxJava/wiki/Error-Handling" rel="nofollow noreferrer">https://github.com/ReactiveX/RxJava/wiki/Error-Handling</a> |
    com.androidnetworking.error.ANError</p>
  </blockquote>
  
  <p>and I don't know why or what should I do to handle error</p>
  
  <p>also I have this line </p>
  
  <pre><code>RxJavaPlugins.setErrorHandler(throwable -&gt; {
      Log.e("error", throwable.getMessage());
  });
  </code></pre>
  
  <p>in my application class</p>