Skip to content

Update of build target to Android Nougat, with multiwindow - #1771

Merged
davivel merged 13 commits into
masterfrom
ChangesForAndroidN
Aug 18, 2016
Merged

davivel merged 13 commits into
masterfrom
ChangesForAndroidN

Conversation

@davivel

@davivel davivel commented Aug 17, 2016

Copy link
Copy Markdown
Contributor

Replaces #1744, after rebase and update of reference to library

@mention-bot

Copy link
Copy Markdown

@davivel, thanks for your PR! By analyzing the annotation information on this pull request, we identified @AndyScherzinger, @przybylski and @MMMarcy to be potential reviewers

@davivel

davivel commented Aug 17, 2016 •

Copy link
Copy Markdown
Contributor Author

OK, license/cla test now passes because @GurpreetSK95 already signed in owncloud/android-library#126 .

👍 ; please, note I'm not approving my own code, I just rebased code by @GurpreetSK95 from #1744 .

@jesmrec , this is basically a technical PR, but if maybe you want to test multi-window mode a big. Shouldn't be a big deal, I don't think it requires a test plan; it's a feature of the OS, besides, not of the app.

@AndyScherzinger

Copy link
Copy Markdown
Contributor

@davivel this PR isn't working for travis! In order to get this working it needs to:

  • target v24 but run the tests on v23
  • not use JACK since that seems to break the travis builds too

@davivel

davivel commented Aug 17, 2016

Copy link
Copy Markdown
Contributor Author

Thanks, @AndyScherzinger . I forgot to commit the update of the reference to the library, that's why appear v23 builds.

Let's see if that's enough. What problems do you know about JACK in Travis?

@AndyScherzinger

Copy link
Copy Markdown
Contributor

I never got that working (yet), for some reasons the builds keep failing. But lets see if it works now :)

@davivel

davivel commented Aug 17, 2016

Copy link
Copy Markdown
Contributor Author

There it goes, our beloved workaround app...

@davivel

davivel commented Aug 17, 2016

Copy link
Copy Markdown
Contributor Author

@AndyScherzinger , you were right, something is not working between Jack & Travis.

Disabled Jack -> back to Java 7

@AndyScherzinger

Copy link
Copy Markdown
Contributor

Pushed a fix, let's see if travis is happy with it :)

@davivel

davivel commented Aug 17, 2016

Copy link
Copy Markdown
Contributor Author

The idea is reduce dependencies -> get rid of android-23

@AndyScherzinger

AndyScherzinger commented Aug 17, 2016 •

Copy link
Copy Markdown
Contributor

@davivel I know, but when I was playing around with travis lately builds kept failing using the emulator with a v24 image...

@AndyScherzinger

Copy link
Copy Markdown
Contributor

both builds are running. Let's see who wins 😉

@davivel

davivel commented Aug 17, 2016

Copy link
Copy Markdown
Contributor Author

:D

@davivel

davivel commented Aug 17, 2016

Copy link
Copy Markdown
Contributor Author

You did it

test(AVD) - 7.0' for 'android:debug': Unknown API Level

stupid emulator...

@AndyScherzinger

Copy link
Copy Markdown
Contributor

I missed updating the android-lib submodule... so my build broke due to the 24.0.0 build tool version from the old submodule link :(

@AndyScherzinger

Copy link
Copy Markdown
Contributor

I'll try another push...

@davivel

davivel commented Aug 17, 2016

Copy link
Copy Markdown
Contributor Author

Let's see.

Anyway, the problem of the emulator is installing the APK. The tests in the library are working fine.

Might be a timeout problem (something like http://stackoverflow.com/questions/32952413/gradle-commands-fail-on-api-23-google-api-emulator-image-armeabi-v7a). In that case, might be prevented installing without gradle.

@AndyScherzinger

Copy link
Copy Markdown
Contributor

The timeout could be fixed like this I guess: googlemaps/android-maps-utils@807f515
- ADB_INSTALL_TIMEOUT=20 # minutes (2 minutes by default)

@davivel

davivel commented Aug 17, 2016

Copy link
Copy Markdown
Contributor Author

Forget it, doesn't make sense. That job took just 31.429 secs to fail. Can't be that.

We'll have to go with the android-23 emulator for the moment.

@AndyScherzinger

Copy link
Copy Markdown
Contributor

@davivel build works 😃

@davivel

davivel commented Aug 17, 2016

Copy link
Copy Markdown
Contributor Author

OK, I'll have a look locally to the issue of the emulator. If I don't find out something in a while, let's just move on with this.

👍 for you, @AndyScherzinger :)

@jesmrec

jesmrec commented Aug 17, 2016

Copy link
Copy Markdown
Member

I have checked the multiWindow in emulator and real device with Android N and works properly. The apk is also correctly built in this branch ;)

Approved.

cc @davivel @AndyScherzinger

@davivel

davivel commented Aug 18, 2016

Copy link
Copy Markdown
Contributor Author

This should make the trick to work with emulator of Android 24. I think the problem is this other timeout: https://android.googlesource.com/platform/tools/base/+/master/ddmlib/src/main/java/com/android/ddmlib/Device.java#90

That is not configurable. Seems the installDebug task can't get the API level of the emulator fast enough because it's the first task working with adb and the call to get the API level finishes before is completely up with wrong value. That would explain the test(AVD) - 7.0' for 'android:debug': Unknown API Level message.

@AndyScherzinger

Copy link
Copy Markdown
Contributor

@davivel test(AVD) - 7.0' for 'android:debug': Unknown API Level issue remains :( Maybe we still need to add the the - ADB_INSTALL_TIMEOUT=20 # minutes (2 minutes by default) or something similar as some kind of a "wait"?

@davivel

davivel commented Aug 18, 2016

Copy link
Copy Markdown
Contributor Author

Dammit. It worked perfectly in the test branch.

I'll make a last try with - ADB_INSTALL_TIMEOUT=20 and moving the adb devices earlier. If that fails, let's go with android-23 emulator.

@davivel
davivel force-pushed the ChangesForAndroidN branch from 553d107 to fade8d2 Compare August 18, 2016 07:59
@davivel

davivel commented Aug 18, 2016

Copy link
Copy Markdown
Contributor Author

Enough. It's not stable, and even when it works, the next test fails.

Rolling back to your proposal.

@davivel
davivel force-pushed the ChangesForAndroidN branch from fade8d2 to 2ced0f9 Compare August 18, 2016 08:33
@davivel

davivel commented Aug 18, 2016

Copy link
Copy Markdown
Contributor Author

Great. So, the source of the problem is not the version of the emulator itself. Probably the upgrade of gradle tools or the build tools. Thinking...

@davivel
davivel force-pushed the ChangesForAndroidN branch from b996b37 to 2ced0f9 Compare August 18, 2016 10:24
@davivel

davivel commented Aug 18, 2016

Copy link
Copy Markdown
Contributor Author

Seems that adbOptions in build.gradle helped; or maybe it's just a coincidence, but two greens in a row is much better than what we had before. Let's go with this, and if breaks again, will disable instrumented tests until Google or Travis improve this mess.

@davivel

davivel commented Aug 18, 2016

Copy link
Copy Markdown
Contributor Author

Come on, rebase on master :S

@davivel
davivel force-pushed the ChangesForAndroidN branch from 8921710 to 5a4b212 Compare August 18, 2016 12:11
@AndyScherzinger

AndyScherzinger commented Aug 18, 2016 •

Copy link
Copy Markdown
Contributor

Downside is now that the CI burns 25 minutes to do this :(

@davivel

davivel commented Aug 18, 2016

Copy link
Copy Markdown
Contributor Author

Well, CI it's not supposed to be fast... but yes, I share the feeling.

@AndyScherzinger

Copy link
Copy Markdown
Contributor

@davivel

davivel commented Aug 18, 2016

Copy link
Copy Markdown
Contributor Author

Disabling.

@davivel

davivel commented Aug 18, 2016

Copy link
Copy Markdown
Contributor Author

@AndyScherzinger , are you fine with this?

@AndyScherzinger

Copy link
Copy Markdown
Contributor

@davivel absolutely! 👍

@davivel

davivel commented Aug 18, 2016

Copy link
Copy Markdown
Contributor Author

Then all in.

Thanks both @GurpreetSK95 and @AndyScherzinger for your work here.

@davivel
davivel merged commit dc69b14 into master Aug 18, 2016
@davivel
davivel deleted the ChangesForAndroidN branch August 18, 2016 14:20
@davivel davivel modified the milestones: 2.1.1, 2.2.0 Aug 29, 2016
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

5 participants