22

my dependencies:

compile "com.android.support:appcompat-v7:20.+"
compile 'com.google.android.gms:play-services:5.2.08'
compile 'com.android.support:support-v4:21.0.+'

but still: Google Play services out of date. Requires 5208000 but found 5089036

how is this possible?

UPDATE this work:

compile 'com.google.android.gms:play-services:5.0.89'

or

compile 'com.google.android.gms:play-services:6.1.11'

or

compile 'com.google.android.gms:play-services:6.+'

Kamil Nękanowicz
  • 6,254
  • 7
  • 34
  • 51
  • Have you tried telling gradle to refresh dependencies? See: http://stackoverflow.com/questions/13565082/how-can-i-force-gradle-to-redownload-dependencies – pjco Aug 08 '14 at 12:42
  • possible duplicate of [Google Play Services version 5.2.08 too recent for my device](http://stackoverflow.com/questions/25198291/google-play-services-version-5-2-08-too-recent-for-my-device) – Brais Gabin Aug 10 '14 at 08:50
  • Your update works perfect – Shudy Sep 17 '14 at 15:29

6 Answers6

34

Change the Google Play Service version in your build.gradle to the version on your device or emulator.

compile 'com.google.android.gms:play-services:5.0.89' 
Jerome Campbell
  • 359
  • 2
  • 5
4

You need to update Google Play Services from Play store on you device, if you don't see any update wait until comes out

Play Store - Google Play Services

Alternatively search on Google and installed the new apk or use an older version like 5.0.77 or 5.0.89

Michele
  • 2,336
  • 1
  • 16
  • 10
  • with 5.0.89 work nice. the problem is a version of Google Play Services from Play store on the device? i have rooted nexus 7 4.4.3 i dont see any update in Google store – Kamil Nękanowicz Aug 08 '14 at 13:45
  • exactly, if you don't see updates on Google Play you need to wait for that or use precedent version in app – Michele Aug 08 '14 at 13:50
  • 8
    Google Play Services 5.2 aren't rolled out yet. You shouldn't use this version for development unless you are developing apps which use the preview of Google Fit. Use version 5.0.89 as suggested in the other answer. – cygery Aug 09 '14 at 18:33
4

The version you are looking for is 5.2.08.

Android Studio will automatically offer to upgrade it to the new version. However, due to a bug, it drops the leading zero in "08", which means it replaces the dependency with "5.2.8" instead of "5.2.08" which does not work. To fix this, edit the dependency to read "5.2.08" instead of "5.2.8"

This will work:

compile 'com.google.android.gms:play-services:5.2.08'

source: http://tools.android.com/knownissues

josacky
  • 136
  • 4
1

For people who suffer from this issue but are not able to make the other work - my issue was that I installed Google Play 5.2.08 in my gradle file (compile 'com.google.android.gms:play-services:5.2.08') because 5.0.77 wasn't working.

  1. I loaded the app onto my phone and it didn't work,

  2. I had the latest update (that I could get on my phone - Android 4.4.2) of google play so telling me to update didn't give me any options

  3. I ended up just needing to update my gradle file to the latest compatible googlePlay, in my case version 5.0.89.
    So find out what version

Jono
  • 3,393
  • 6
  • 33
  • 48
1

You can now use

compile 'com.google.android.gms:play-services:6.1.11'
friederbluemle
  • 33,549
  • 14
  • 108
  • 109