-
Notifications
You must be signed in to change notification settings - Fork 24.4k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Update all the android related projects to target API level 27 #17741
Update all the android related projects to target API level 27 #17741
Conversation
Generated by 🚫 dangerJS |
ccb0ed6
to
cfd776f
Compare
@SandroMachado I tried to find reviewers for this pull request and wanted to ping them to take another look. However, based on the blame information for the files in this pull request I couldn't find any reviewers. This sometimes happens when the files in the pull request are new or don't exist on master anymore. Is this pull request still relevant? If yes could you please rebase? In case you know who has context on this code feel free to mention them in a comment (one person is fine). Thanks for reading and hope you will continue contributing to the project. |
@hramos can you please help me finding someone to review the PR? |
@SandroMachado can you look at the release.gradle conflicts, and make sure the |
I've fixed the conflicts. Next we'd need to update the Circle tests to ensure they're using an image with the correct build tools and Android SDK versions installed. People can still manually update their project to target API 27 so this is not considered as blocking people from mitigating the issue on their own projects. |
@hramos thanks and sorry for the delay fixing the conflicts 👍 |
@SandroMachado I tried to find reviewers for this pull request and wanted to ping them to take another look. However, based on the blame information for the files in this pull request I couldn't find any reviewers. This sometimes happens when the files in the pull request are new or don't exist on master anymore. Is this pull request still relevant? If yes could you please rebase? In case you know who has context on this code feel free to mention them in a comment (one person is fine). Thanks for reading and hope you will continue contributing to the project. |
@hramos so the main objective is move to API level 26, since this PR is pointing to 27 it will not be merged, at least for now. Right? I can easily fix the conflicts but I want to understand if the PR will be merged. |
@SandroMachado I have plan to bump SDK to 27, when ready. I and many developers experience issues when they use SDK 27, like aapt2. So we need some time to thoroughly test the SDK 27. That was my reason to choose SDK 26 over 27. |
@dulmandakh understood, thanks for the clarification. |
@SandroMachado you can close this PR if you are satisfied with the results/progress. |
Help needed #20026 |
* Using SDK Version variables from root project Instead of assuming the `compileSdkVersion`, `targetSdkVersion`, etc, read it from the root project. Default `compileSdkVersion` and `targetSdkVersion` to the latest versions. Android Target API Level 26 will be required in August 2018. https://android-developers.googleblog.com/2017/12/improving-app-security-and-performance.html And the React Native team is already working on this: facebook/react-native#17741 facebook/react-native#18095 * Renaming variables for consistency * Rename variables and use *Version for all settings
Instead of assuming the `compileSdkVersion `, `targetSdkVersion`, etc, we can make it dynamic by reading it from the root project. Android Target API Level 26 will be required in August 2018. https://android-developers.googleblog.com/2017/12/improving-app-security-and-performance.html Therefore I wrote target values of 26 instead of 23 And the React Native team is already working on this: facebook/react-native#18095 facebook/react-native#17741
just added a function which does acts like a ternary with fallback option. Hence, less cluttered "def" variables additionally, changes the SDK values from 23 to 26 as per new changes from react-native and Android Android Target API Level 26 will be required in August 2018. https://android-developers.googleblog.com/2017/12/improving-app-security-and-performance.html And the React Native team is already working on this: facebook/react-native#18095 facebook/react-native#17741
Instead of assuming the `compileSdkVersion `, `targetSdkVersion`, etc, we can make it dynamic by reading it from the root project. Android Target API Level 26 will be required in August 2018. https://android-developers.googleblog.com/2017/12/improving-app-security-and-performance.html Therefore I wrote target values of 26 instead of 23 And the React Native team is already working on this: facebook/react-native#18095 facebook/react-native#17741
just added a function which acts like a ternary with fallback option. Hence, less cluttered "def" variables additionally, changed the SDK values from 23 to 26 as per new changes from react-native and Android Android Target API Level 26 will be required in August 2018. https://android-developers.googleblog.com/2017/12/improving-app-security-and-performance.html And the React Native team is already working on this: facebook/react-native#18095 facebook/react-native#17741 PS: I am aware of this PR joltup#128 but first its still targeting old SDK values i.e 23 as fallback and secondly I am not sure of the use of `project` to get the value instead of proper way i.e `rootProject.ext` to get the property value.
just a little improved version rather then many explicit def for each value. hence, less cluttering. also made the react-native package to get the dynamic versions as well Android Target API Level 26 will be required in August 2018. https://android-developers.googleblog.com/2017/12/improving-app-security-and-performance.html I was going to write 26 but Since we are already using latest Gradle, Therefore I wrote target values of 27 instead of 25. And the React Native team is already working on this: facebook/react-native#18095 facebook/react-native#17741
closing this PR because SDK 27 is landed in master. |
Re-opening because the SDK 27 upgrade is being reverted. |
@hramos can you please give more details. Why is it being reverted? |
I left some comments in the commit themselves. The revert already landed, but I have a fix that should let us get back on 27. It's waiting for review and should land soon if no blockers show up. |
This is fixed now. |
Instead of assuming the `compileSdkVersion`, `targetSdkVersion`, etc, read it from the root project. Default `compileSdkVersion` and `targetSdkVersion` to the latest versions. Android Target API Level 26 will be required in August 2018. https://android-developers.googleblog.com/2017/12/improving-app-security-and-performance.html And the React Native team is already working on this: facebook/react-native#17741 facebook/react-native#18095
Instead of assuming the `compileSdkVersion`, `targetSdkVersion`, etc, read it from the root project. Default `compileSdkVersion` and `targetSdkVersion` to the latest versions. Android Target API Level 26 will be required in August 2018. https://android-developers.googleblog.com/2017/12/improving-app-security-and-performance.html And the React Native team is already working on this: facebook/react-native#17741 facebook/react-native#18095
Instead of assuming the `compileSdkVersion`, `targetSdkVersion`, etc, read it from the root project. Default `compileSdkVersion` and `targetSdkVersion` to the latest versions. Android Target API Level 26 will be required in August 2018. https://android-developers.googleblog.com/2017/12/improving-app-security-and-performance.html And the React Native team is already working on this: facebook/react-native#17741 facebook/react-native#18095
Instead of assuming the `compileSdkVersion`, `targetSdkVersion`, etc, read it from the root project. Default `compileSdkVersion` and `targetSdkVersion` to the latest versions. Android Target API Level 26 will be required in August 2018. https://android-developers.googleblog.com/2017/12/improving-app-security-and-performance.html And the React Native team is already working on this: facebook/react-native#17741 facebook/react-native#18095
Motivation
Google recently announced in a blog post called Improving app security and performance on Google Play for years to come that all the new apps submitted to the play store, after August 2018, will require to be targeting at least Android API level 26:
This PR updates all the Android related projects (ReactAndroid, RNTester and the HelloWorld template) to target the API level 27.
I did not find any issue doing this upgrade but since RN was targeting version API level 22, the developers need to be aware that targeting any API level greater that 22 will introduce the run time permissions feature. Since this is a breaking change it should be described in the
changelog
.This PR also closes #17287.
Test Plan
I tested the project and LGTM. I compiled and executed the RNTester and everything looks good.
Related PRs
(If this PR adds or changes functionality, please take some time to update the docs at https://github.com/facebook/react-native-website, and link to your PR here.)
Release Notes
[CLI] [FEATURE] [local-cli/generator/templates] - Generate the android app template targeting API level 27.
[ANDROID] [FEATURE] [BuildTools] - Updates the Android project to target API level 27.