Search code examples
androidtravis-ciandroid-lint

Travis build fails because of lint saying that SDK platform-tools version is too old


Hi I have an android app I build on Travis CI. Unfortunately the build fails, because lint says that the platform sdk tools are too old:

The SDK platform-tools version (23.0.1) is too old to check APIs compiled with API 25; please update

The build tools I use (in build.gradle file) is 25.0.1 and I compile with API 25. On my local machine my app compiles fine from command line without any lint errors.

My .travis.yml file looks like this:

language: android
android:
  components:
  - tools
  - build-tools-25.0.1
  - extra-android-m2repository
  - android-25
jdk:
- oraclejdk8
licenses:
- android-sdk-license-.+
- android-sdk-license-c81a61d9

Any idea what could be wrong with my travis settings?


Solution

  • You should add platform-tools to your components: block. I have it listed first in my .travis.yml:

    android:
        components:
            - platform-tools
            - tools
            - build-tools-25.0.1
            - android-25
            - extra-android-m2repository
            - extra-android-support
            - extra-google-m2repository
            - extra-google-google_play_services