App crashes when running maps activity











up vote
0
down vote

favorite












My projects Map activity is not working

I just pasted the api key in place google_maps_api.xml
and clicked run



Logcat:




E/AndroidRuntime: FATAL EXCEPTION: Thread-5
Process: com.example.appmy.lofind, PID: 10901
java.lang.NoClassDefFoundError: Failed resolution of: Lorg/apache/http/ProtocolVersion;
at el.b(:com.google.android.gms.dynamite_mapsdynamite@12848026@12.8.48 (040700-196123505):3)
at ek.a(:com.google.android.gms.dynamite_mapsdynamite@12848026@12.8.48 (040700-196123505):4)
at em.a(:com.google.android.gms.dynamite_mapsdynamite@12848026@12.8.48 (040700-196123505):51)
at com.google.maps.api.android.lib6.drd.ap.a(:com.google.android.gms.dynamite_mapsdynamite@12848026@12.8.48 (040700-196123505):11)
at dw.a(:com.google.android.gms.dynamite_mapsdynamite@12848026@12.8.48 (040700-196123505):16)
at dw.run(:com.google.android.gms.dynamite_mapsdynamite@12848026@12.8.48 (040700-196123505):61)
Caused by: java.lang.ClassNotFoundException: Didn't find class "org.apache.http.ProtocolVersion" on path: DexPathList[[zip file "/system/priv-app/PrebuiltGmsCore/app_chimera/m/MapsDynamite.apk"],nativeLibraryDirectories=[/data/user_de/0/com.google.android.gms/app_chimera/m/00000006/MapsDynamite.apk!/lib/x86, /system/lib]]
at dalvik.system.BaseDexClassLoader.findClass(BaseDexClassLoader.java:126)
at java.lang.ClassLoader.loadClass(ClassLoader.java:379)
at ad.loadClass(:com.google.android.gms.dynamite_dynamiteloader@12848026@12.8.48 (040700-196123505):25)
at java.lang.ClassLoader.loadClass(ClassLoader.java:312)
at el.b(:com.google.android.gms.dynamite_mapsdynamite@12848026@12.8.48 (040700-196123505):3) 
at ek.a(:com.google.android.gms.dynamite_mapsdynamite@12848026@12.8.48 (040700-196123505):4) 
at em.a(:com.google.android.gms.dynamite_mapsdynamite@12848026@12.8.48 (040700-196123505):51) 
at com.google.maps.api.android.lib6.drd.ap.a(:com.google.android.gms.dynamite_mapsdynamite@12848026@12.8.48 (040700-196123505):11) 
at dw.a(:com.google.android.gms.dynamite_mapsdynamite@12848026@12.8.48 (040700-196123505):16) 
at dw.run(:com.google.android.gms.dynamite_mapsdynamite@12848026@12.8.48 (040700-196123505):61) 
E/SchedPolicy: set_timerslack_ns write failed: Operation not permitted











share|improve this question




























    up vote
    0
    down vote

    favorite












    My projects Map activity is not working

    I just pasted the api key in place google_maps_api.xml
    and clicked run



    Logcat:




    E/AndroidRuntime: FATAL EXCEPTION: Thread-5
    Process: com.example.appmy.lofind, PID: 10901
    java.lang.NoClassDefFoundError: Failed resolution of: Lorg/apache/http/ProtocolVersion;
    at el.b(:com.google.android.gms.dynamite_mapsdynamite@12848026@12.8.48 (040700-196123505):3)
    at ek.a(:com.google.android.gms.dynamite_mapsdynamite@12848026@12.8.48 (040700-196123505):4)
    at em.a(:com.google.android.gms.dynamite_mapsdynamite@12848026@12.8.48 (040700-196123505):51)
    at com.google.maps.api.android.lib6.drd.ap.a(:com.google.android.gms.dynamite_mapsdynamite@12848026@12.8.48 (040700-196123505):11)
    at dw.a(:com.google.android.gms.dynamite_mapsdynamite@12848026@12.8.48 (040700-196123505):16)
    at dw.run(:com.google.android.gms.dynamite_mapsdynamite@12848026@12.8.48 (040700-196123505):61)
    Caused by: java.lang.ClassNotFoundException: Didn't find class "org.apache.http.ProtocolVersion" on path: DexPathList[[zip file "/system/priv-app/PrebuiltGmsCore/app_chimera/m/MapsDynamite.apk"],nativeLibraryDirectories=[/data/user_de/0/com.google.android.gms/app_chimera/m/00000006/MapsDynamite.apk!/lib/x86, /system/lib]]
    at dalvik.system.BaseDexClassLoader.findClass(BaseDexClassLoader.java:126)
    at java.lang.ClassLoader.loadClass(ClassLoader.java:379)
    at ad.loadClass(:com.google.android.gms.dynamite_dynamiteloader@12848026@12.8.48 (040700-196123505):25)
    at java.lang.ClassLoader.loadClass(ClassLoader.java:312)
    at el.b(:com.google.android.gms.dynamite_mapsdynamite@12848026@12.8.48 (040700-196123505):3) 
    at ek.a(:com.google.android.gms.dynamite_mapsdynamite@12848026@12.8.48 (040700-196123505):4) 
    at em.a(:com.google.android.gms.dynamite_mapsdynamite@12848026@12.8.48 (040700-196123505):51) 
    at com.google.maps.api.android.lib6.drd.ap.a(:com.google.android.gms.dynamite_mapsdynamite@12848026@12.8.48 (040700-196123505):11) 
    at dw.a(:com.google.android.gms.dynamite_mapsdynamite@12848026@12.8.48 (040700-196123505):16) 
    at dw.run(:com.google.android.gms.dynamite_mapsdynamite@12848026@12.8.48 (040700-196123505):61) 
    E/SchedPolicy: set_timerslack_ns write failed: Operation not permitted











    share|improve this question


























      up vote
      0
      down vote

      favorite









      up vote
      0
      down vote

      favorite











      My projects Map activity is not working

      I just pasted the api key in place google_maps_api.xml
      and clicked run



      Logcat:




      E/AndroidRuntime: FATAL EXCEPTION: Thread-5
      Process: com.example.appmy.lofind, PID: 10901
      java.lang.NoClassDefFoundError: Failed resolution of: Lorg/apache/http/ProtocolVersion;
      at el.b(:com.google.android.gms.dynamite_mapsdynamite@12848026@12.8.48 (040700-196123505):3)
      at ek.a(:com.google.android.gms.dynamite_mapsdynamite@12848026@12.8.48 (040700-196123505):4)
      at em.a(:com.google.android.gms.dynamite_mapsdynamite@12848026@12.8.48 (040700-196123505):51)
      at com.google.maps.api.android.lib6.drd.ap.a(:com.google.android.gms.dynamite_mapsdynamite@12848026@12.8.48 (040700-196123505):11)
      at dw.a(:com.google.android.gms.dynamite_mapsdynamite@12848026@12.8.48 (040700-196123505):16)
      at dw.run(:com.google.android.gms.dynamite_mapsdynamite@12848026@12.8.48 (040700-196123505):61)
      Caused by: java.lang.ClassNotFoundException: Didn't find class "org.apache.http.ProtocolVersion" on path: DexPathList[[zip file "/system/priv-app/PrebuiltGmsCore/app_chimera/m/MapsDynamite.apk"],nativeLibraryDirectories=[/data/user_de/0/com.google.android.gms/app_chimera/m/00000006/MapsDynamite.apk!/lib/x86, /system/lib]]
      at dalvik.system.BaseDexClassLoader.findClass(BaseDexClassLoader.java:126)
      at java.lang.ClassLoader.loadClass(ClassLoader.java:379)
      at ad.loadClass(:com.google.android.gms.dynamite_dynamiteloader@12848026@12.8.48 (040700-196123505):25)
      at java.lang.ClassLoader.loadClass(ClassLoader.java:312)
      at el.b(:com.google.android.gms.dynamite_mapsdynamite@12848026@12.8.48 (040700-196123505):3) 
      at ek.a(:com.google.android.gms.dynamite_mapsdynamite@12848026@12.8.48 (040700-196123505):4) 
      at em.a(:com.google.android.gms.dynamite_mapsdynamite@12848026@12.8.48 (040700-196123505):51) 
      at com.google.maps.api.android.lib6.drd.ap.a(:com.google.android.gms.dynamite_mapsdynamite@12848026@12.8.48 (040700-196123505):11) 
      at dw.a(:com.google.android.gms.dynamite_mapsdynamite@12848026@12.8.48 (040700-196123505):16) 
      at dw.run(:com.google.android.gms.dynamite_mapsdynamite@12848026@12.8.48 (040700-196123505):61) 
      E/SchedPolicy: set_timerslack_ns write failed: Operation not permitted











      share|improve this question















      My projects Map activity is not working

      I just pasted the api key in place google_maps_api.xml
      and clicked run



      Logcat:




      E/AndroidRuntime: FATAL EXCEPTION: Thread-5
      Process: com.example.appmy.lofind, PID: 10901
      java.lang.NoClassDefFoundError: Failed resolution of: Lorg/apache/http/ProtocolVersion;
      at el.b(:com.google.android.gms.dynamite_mapsdynamite@12848026@12.8.48 (040700-196123505):3)
      at ek.a(:com.google.android.gms.dynamite_mapsdynamite@12848026@12.8.48 (040700-196123505):4)
      at em.a(:com.google.android.gms.dynamite_mapsdynamite@12848026@12.8.48 (040700-196123505):51)
      at com.google.maps.api.android.lib6.drd.ap.a(:com.google.android.gms.dynamite_mapsdynamite@12848026@12.8.48 (040700-196123505):11)
      at dw.a(:com.google.android.gms.dynamite_mapsdynamite@12848026@12.8.48 (040700-196123505):16)
      at dw.run(:com.google.android.gms.dynamite_mapsdynamite@12848026@12.8.48 (040700-196123505):61)
      Caused by: java.lang.ClassNotFoundException: Didn't find class "org.apache.http.ProtocolVersion" on path: DexPathList[[zip file "/system/priv-app/PrebuiltGmsCore/app_chimera/m/MapsDynamite.apk"],nativeLibraryDirectories=[/data/user_de/0/com.google.android.gms/app_chimera/m/00000006/MapsDynamite.apk!/lib/x86, /system/lib]]
      at dalvik.system.BaseDexClassLoader.findClass(BaseDexClassLoader.java:126)
      at java.lang.ClassLoader.loadClass(ClassLoader.java:379)
      at ad.loadClass(:com.google.android.gms.dynamite_dynamiteloader@12848026@12.8.48 (040700-196123505):25)
      at java.lang.ClassLoader.loadClass(ClassLoader.java:312)
      at el.b(:com.google.android.gms.dynamite_mapsdynamite@12848026@12.8.48 (040700-196123505):3) 
      at ek.a(:com.google.android.gms.dynamite_mapsdynamite@12848026@12.8.48 (040700-196123505):4) 
      at em.a(:com.google.android.gms.dynamite_mapsdynamite@12848026@12.8.48 (040700-196123505):51) 
      at com.google.maps.api.android.lib6.drd.ap.a(:com.google.android.gms.dynamite_mapsdynamite@12848026@12.8.48 (040700-196123505):11) 
      at dw.a(:com.google.android.gms.dynamite_mapsdynamite@12848026@12.8.48 (040700-196123505):16) 
      at dw.run(:com.google.android.gms.dynamite_mapsdynamite@12848026@12.8.48 (040700-196123505):61) 
      E/SchedPolicy: set_timerslack_ns write failed: Operation not permitted








      android performance kotlin






      share|improve this question















      share|improve this question













      share|improve this question




      share|improve this question








      edited Jun 18 at 7:37









      MrUpsidown

      14.6k74893




      14.6k74893










      asked Jun 17 at 13:19









      MajdNaji

      813




      813
























          2 Answers
          2






          active

          oldest

          votes

















          up vote
          3
          down vote



          accepted










          The same problem here when using target SDK 28. Reverting to SDK 27 solved the problem.





          Don't revert your target SDK.



          Better use this solution https://stackoverflow.com/a/50944537/5710605






          share|improve this answer























          • it worked!!! Many thanks
            – MajdNaji
            Jun 22 at 12:11










          • @MajdNaji check Eduard's other answer. I think that's a better solution than downgrading.
            – wsgeorge
            Nov 14 at 10:32










          • Reverting to SDK 27 is not a solution, don't add broken windows to your house. "Pragmatic programmer"
            – Mahdi Javaheri
            Nov 18 at 6:54


















          up vote
          10
          down vote













          I've found another solution at
          Android Google maps java.lang.NoClassDefFoundError: Failed resolution of: Lorg/apache/http/ProtocolVersion



          Just add this in your manifest:



          <uses-library android:name="org.apache.http.legacy" android:required="false"/>





          share|improve this answer























          • Thanks. I prefer this to the accepted answer. I read somewhere else on SO to include <uses-library android:name="com.google.android.maps" /> instead. It didn't work in my case, but thoughts on it?
            – wsgeorge
            Nov 14 at 10:31











          Your Answer






          StackExchange.ifUsing("editor", function () {
          StackExchange.using("externalEditor", function () {
          StackExchange.using("snippets", function () {
          StackExchange.snippets.init();
          });
          });
          }, "code-snippets");

          StackExchange.ready(function() {
          var channelOptions = {
          tags: "".split(" "),
          id: "1"
          };
          initTagRenderer("".split(" "), "".split(" "), channelOptions);

          StackExchange.using("externalEditor", function() {
          // Have to fire editor after snippets, if snippets enabled
          if (StackExchange.settings.snippets.snippetsEnabled) {
          StackExchange.using("snippets", function() {
          createEditor();
          });
          }
          else {
          createEditor();
          }
          });

          function createEditor() {
          StackExchange.prepareEditor({
          heartbeatType: 'answer',
          convertImagesToLinks: true,
          noModals: true,
          showLowRepImageUploadWarning: true,
          reputationToPostImages: 10,
          bindNavPrevention: true,
          postfix: "",
          imageUploader: {
          brandingHtml: "Powered by u003ca class="icon-imgur-white" href="https://imgur.com/"u003eu003c/au003e",
          contentPolicyHtml: "User contributions licensed under u003ca href="https://creativecommons.org/licenses/by-sa/3.0/"u003ecc by-sa 3.0 with attribution requiredu003c/au003e u003ca href="https://stackoverflow.com/legal/content-policy"u003e(content policy)u003c/au003e",
          allowUrls: true
          },
          onDemand: true,
          discardSelector: ".discard-answer"
          ,immediatelyShowMarkdownHelp:true
          });


          }
          });














          draft saved

          draft discarded


















          StackExchange.ready(
          function () {
          StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2fstackoverflow.com%2fquestions%2f50897054%2fapp-crashes-when-running-maps-activity%23new-answer', 'question_page');
          }
          );

          Post as a guest















          Required, but never shown

























          2 Answers
          2






          active

          oldest

          votes








          2 Answers
          2






          active

          oldest

          votes









          active

          oldest

          votes






          active

          oldest

          votes








          up vote
          3
          down vote



          accepted










          The same problem here when using target SDK 28. Reverting to SDK 27 solved the problem.





          Don't revert your target SDK.



          Better use this solution https://stackoverflow.com/a/50944537/5710605






          share|improve this answer























          • it worked!!! Many thanks
            – MajdNaji
            Jun 22 at 12:11










          • @MajdNaji check Eduard's other answer. I think that's a better solution than downgrading.
            – wsgeorge
            Nov 14 at 10:32










          • Reverting to SDK 27 is not a solution, don't add broken windows to your house. "Pragmatic programmer"
            – Mahdi Javaheri
            Nov 18 at 6:54















          up vote
          3
          down vote



          accepted










          The same problem here when using target SDK 28. Reverting to SDK 27 solved the problem.





          Don't revert your target SDK.



          Better use this solution https://stackoverflow.com/a/50944537/5710605






          share|improve this answer























          • it worked!!! Many thanks
            – MajdNaji
            Jun 22 at 12:11










          • @MajdNaji check Eduard's other answer. I think that's a better solution than downgrading.
            – wsgeorge
            Nov 14 at 10:32










          • Reverting to SDK 27 is not a solution, don't add broken windows to your house. "Pragmatic programmer"
            – Mahdi Javaheri
            Nov 18 at 6:54













          up vote
          3
          down vote



          accepted







          up vote
          3
          down vote



          accepted






          The same problem here when using target SDK 28. Reverting to SDK 27 solved the problem.





          Don't revert your target SDK.



          Better use this solution https://stackoverflow.com/a/50944537/5710605






          share|improve this answer














          The same problem here when using target SDK 28. Reverting to SDK 27 solved the problem.





          Don't revert your target SDK.



          Better use this solution https://stackoverflow.com/a/50944537/5710605







          share|improve this answer














          share|improve this answer



          share|improve this answer








          edited Nov 19 at 13:28

























          answered Jun 20 at 8:13









          Eduard Bosch Bertran

          1518




          1518












          • it worked!!! Many thanks
            – MajdNaji
            Jun 22 at 12:11










          • @MajdNaji check Eduard's other answer. I think that's a better solution than downgrading.
            – wsgeorge
            Nov 14 at 10:32










          • Reverting to SDK 27 is not a solution, don't add broken windows to your house. "Pragmatic programmer"
            – Mahdi Javaheri
            Nov 18 at 6:54


















          • it worked!!! Many thanks
            – MajdNaji
            Jun 22 at 12:11










          • @MajdNaji check Eduard's other answer. I think that's a better solution than downgrading.
            – wsgeorge
            Nov 14 at 10:32










          • Reverting to SDK 27 is not a solution, don't add broken windows to your house. "Pragmatic programmer"
            – Mahdi Javaheri
            Nov 18 at 6:54
















          it worked!!! Many thanks
          – MajdNaji
          Jun 22 at 12:11




          it worked!!! Many thanks
          – MajdNaji
          Jun 22 at 12:11












          @MajdNaji check Eduard's other answer. I think that's a better solution than downgrading.
          – wsgeorge
          Nov 14 at 10:32




          @MajdNaji check Eduard's other answer. I think that's a better solution than downgrading.
          – wsgeorge
          Nov 14 at 10:32












          Reverting to SDK 27 is not a solution, don't add broken windows to your house. "Pragmatic programmer"
          – Mahdi Javaheri
          Nov 18 at 6:54




          Reverting to SDK 27 is not a solution, don't add broken windows to your house. "Pragmatic programmer"
          – Mahdi Javaheri
          Nov 18 at 6:54












          up vote
          10
          down vote













          I've found another solution at
          Android Google maps java.lang.NoClassDefFoundError: Failed resolution of: Lorg/apache/http/ProtocolVersion



          Just add this in your manifest:



          <uses-library android:name="org.apache.http.legacy" android:required="false"/>





          share|improve this answer























          • Thanks. I prefer this to the accepted answer. I read somewhere else on SO to include <uses-library android:name="com.google.android.maps" /> instead. It didn't work in my case, but thoughts on it?
            – wsgeorge
            Nov 14 at 10:31















          up vote
          10
          down vote













          I've found another solution at
          Android Google maps java.lang.NoClassDefFoundError: Failed resolution of: Lorg/apache/http/ProtocolVersion



          Just add this in your manifest:



          <uses-library android:name="org.apache.http.legacy" android:required="false"/>





          share|improve this answer























          • Thanks. I prefer this to the accepted answer. I read somewhere else on SO to include <uses-library android:name="com.google.android.maps" /> instead. It didn't work in my case, but thoughts on it?
            – wsgeorge
            Nov 14 at 10:31













          up vote
          10
          down vote










          up vote
          10
          down vote









          I've found another solution at
          Android Google maps java.lang.NoClassDefFoundError: Failed resolution of: Lorg/apache/http/ProtocolVersion



          Just add this in your manifest:



          <uses-library android:name="org.apache.http.legacy" android:required="false"/>





          share|improve this answer














          I've found another solution at
          Android Google maps java.lang.NoClassDefFoundError: Failed resolution of: Lorg/apache/http/ProtocolVersion



          Just add this in your manifest:



          <uses-library android:name="org.apache.http.legacy" android:required="false"/>






          share|improve this answer














          share|improve this answer



          share|improve this answer








          edited Nov 16 at 16:50

























          answered Jun 20 at 9:14









          Eduard Bosch Bertran

          1518




          1518












          • Thanks. I prefer this to the accepted answer. I read somewhere else on SO to include <uses-library android:name="com.google.android.maps" /> instead. It didn't work in my case, but thoughts on it?
            – wsgeorge
            Nov 14 at 10:31


















          • Thanks. I prefer this to the accepted answer. I read somewhere else on SO to include <uses-library android:name="com.google.android.maps" /> instead. It didn't work in my case, but thoughts on it?
            – wsgeorge
            Nov 14 at 10:31
















          Thanks. I prefer this to the accepted answer. I read somewhere else on SO to include <uses-library android:name="com.google.android.maps" /> instead. It didn't work in my case, but thoughts on it?
          – wsgeorge
          Nov 14 at 10:31




          Thanks. I prefer this to the accepted answer. I read somewhere else on SO to include <uses-library android:name="com.google.android.maps" /> instead. It didn't work in my case, but thoughts on it?
          – wsgeorge
          Nov 14 at 10:31


















          draft saved

          draft discarded




















































          Thanks for contributing an answer to Stack Overflow!


          • Please be sure to answer the question. Provide details and share your research!

          But avoid



          • Asking for help, clarification, or responding to other answers.

          • Making statements based on opinion; back them up with references or personal experience.


          To learn more, see our tips on writing great answers.





          Some of your past answers have not been well-received, and you're in danger of being blocked from answering.


          Please pay close attention to the following guidance:


          • Please be sure to answer the question. Provide details and share your research!

          But avoid



          • Asking for help, clarification, or responding to other answers.

          • Making statements based on opinion; back them up with references or personal experience.


          To learn more, see our tips on writing great answers.




          draft saved


          draft discarded














          StackExchange.ready(
          function () {
          StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2fstackoverflow.com%2fquestions%2f50897054%2fapp-crashes-when-running-maps-activity%23new-answer', 'question_page');
          }
          );

          Post as a guest















          Required, but never shown





















































          Required, but never shown














          Required, but never shown












          Required, but never shown







          Required, but never shown

































          Required, but never shown














          Required, but never shown












          Required, but never shown







          Required, but never shown







          Popular posts from this blog

          Costa Masnaga

          Fotorealismo

          Sidney Franklin