title: PayPal Android SDK Errors "request failed with server response:shutdown" "SERVER_COMMUNICATION_ERROR"
body: <p>I am using the following SDK : <a href="https://github.com/paypal/PayPal-Android-SDK" rel="nofollow">https://github.com/paypal/PayPal-Android-SDK</a></p>
  
  <p>I have this in my AndroidManifext.xml : </p>
  
  <pre><code>    &lt;!-- PayPal Android SDK start --&gt;
  
      &lt;service android:name="com.paypal.android.sdk.payments.PayPalService"
          android:exported="false" /&gt;
  
      &lt;activity android:name="com.paypal.android.sdk.payments.PaymentActivity" /&gt;
      &lt;activity android:name="com.paypal.android.sdk.payments.LoginActivity" /&gt;
      &lt;activity android:name="com.paypal.android.sdk.payments.PaymentMethodActivity" /&gt;
      &lt;activity android:name="com.paypal.android.sdk.payments.PaymentConfirmActivity" /&gt;
      &lt;activity android:name="io.card.payment.CardIOActivity"
          android:configChanges="keyboardHidden|orientation" /&gt;
      &lt;activity android:name="io.card.payment.DataEntryActivity" /&gt;
  
      &lt;!-- PayPal Android SDK end --&gt;
  </code></pre>
  
  <p>In my fragment that I am initiating the purchasing from I have the following code (which was taken from the SDK tutorial):</p>
  
  <pre><code>private static PayPalConfiguration paypal_config = new PayPalConfiguration()
  
          // Start with mock environment.  When ready, switch to sandbox (ENVIRONMENT_SANDBOX)
          // or live (ENVIRONMENT_PRODUCTION)
          .environment(PayPalConfiguration.ENVIRONMENT_SANDBOX)
  
          .clientId("&lt;--ID--&gt;");
  
  
  public View onCreateView(LayoutInflater inflater, ViewGroup container,
                           Bundle savedInstanceState) {
  ...
      Intent intent = new Intent(getActivity(), PayPalService.class);
  
      intent.putExtra(PayPalService.EXTRA_PAYPAL_CONFIGURATION, paypal_config);
      getActivity().startService(intent);
  ...
      button.setOnClickListener(new View.OnClickListener() {
          @Override
          public void onClick(View v) {
              AlertDialog.Builder builder = new AlertDialog.Builder(getActivity(), R.style.AlertDialogTheme);
              LayoutInflater inflater = LayoutInflater.from(getActivity());
              View prompt = inflater.inflate(R.layout.purchase, null);
              Button cancel_btn = (Button) prompt.findViewById(R.id.cancel);
              Button purchase_btn = (Button) prompt.findViewById(R.id.purchase_button);
                      PayPalPayment payment = new PayPalPayment(new BigDecimal("1.75"), "USD", "sample item",
                              PayPalPayment.PAYMENT_INTENT_SALE);
  
                      Intent intent = new Intent(getActivity(), PaymentActivity.class);
  
                      // send the same configuration for restart resiliency
                      intent.putExtra(PayPalService.EXTRA_PAYPAL_CONFIGURATION, paypal_config);
  
                      intent.putExtra(PaymentActivity.EXTRA_PAYMENT, payment);
  
                      startActivityForResult(intent, 0);
                  }
              });
  </code></pre>
  
  <p>This was working for all of yesterday and most of today, yet today I am getting the errors stated in the title.  I went to the developer portal for paypal and there are no notices for my account, and my app/accounts/users are set up correctly (nothing has changed since before it was working.  It just stopped working during testing).</p>
  
  <p>Has anyone faced this issue and resolved it successfully?</p>
  
  <p>Edit:
  A little more info: When the paypal view pops up, it gives me an error popup Title: "Try Again" Message: "There was a problem communicating with the PayPal servers.  Please try again."  If it tap cancel, it goes back to my app's view.  Sometimes, when I tap 'Try Again' it will let me through to the payment and login buttons, but when I try to login it gives me a similar error with only "Ok" as an option.</p>
  
  <p>Edit 2: After hitting 'Try Again' several times I also get this error:</p>
  
  <pre><code>"E/paypal.sdk: request failed with server response:Socket is closed"
  </code></pre>
  
  <p>Edit 3: Also, right before these errors I am always getting this error:</p>
  
  <pre><code> "E/ViewRootImpl: sendUserActionEvent() mView == null" 
  </code></pre>
  
  <p>Anyone know if this is a cause of the problem?  Not really sure what this means as the view is actually loading fine, but there seems to be an issue with the server call afterwards.</p>
  
  <p>Edit 4: Seems to work fine with ENVIRONMENT_PRODUCTION set w/ Production clientId.  I tried deleting the app, using different accounts for the app, and even tried with another paypal account to no avail.  Unless there is something I am missing or PayPal is restricting my testing account, then there is something wrong with PayPal's server.  Hopefully someone more knowledgeable can come in and shed some light on this issue so others don't have to waste there time on this.</p>
  
  <p>Edit 5: Scratch that.  I am getting the error on production environment now... what gives?</p>