Skip to content
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 Android Version #717

Merged
merged 10 commits into from
Jul 23, 2024
Merged

Conversation

afischerdev
Copy link
Collaborator

Google wants us to change the Android version by the end of August.
So here it comes.

This gives you the opportunity to make some additional changes that are only relevant for development:

  • new versions for the libraries
  • some compiler params for better control
  • new gradle app name for compatibility with future gradle versions
  • replace printstacktrace with more robust logging

minSdkVersion 14
targetSdkVersion 33
minSdkVersion 21
targetSdkVersion 35
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Current target API level requirement is 34:
https://developer.android.com/google/play/requirements/target-sdk

35 will not be required until August 2025.

Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@devemux86
That is correct. But my Studio tells me 'not targeting the latest versions of Android' when I use API level 34.

Anyway the main problem I see is the minSdkVersion.
With using new libraries, level 21 is required.

When going back with e.g. androidx.appcompat:appcompat:1.6.1 we could go back to level 19. This will bring an error: Cannot fit requested classes in a single dex file for deprecated classes.
But setting minifyEnabled false for debug mode takes care of this. And should not bring to much trouble in development because we set all BRouter classes to keep in last update.

What do you think? Going back?

BTW: Is there still an IDEA problem with
classpath 'com.android.tools.build:gradle:8.3.1

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@afischerdev

The latest stable version is compile and target SDK 34.
Android 15 will be released the next months.

With using new libraries, level 21 is required.

This should be normal, we can update the dependencies and use min sdk 21.

Is there still an IDEA problem with

Unfortunately we still have to use version 8.2.2 for IDEA.

Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This should be normal, we can update the dependencies and use min sdk 21.

Well, I would prefer that. For me it is cleaner.

@ALL
Other comments for the min version API level 21?

Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

API 21 was released 10 years ago and is the latest version supported by Google Play Services. This shouldn't affect many devices so I think it's a good idea to increase the minSdkVersion. I think targetSdkVersion should be API 34 because API 35 is only released as preview.

Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I'll change the version back. I don't mind.
But no, there is no preview Android installed, it's a 35 rev. 1.

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Android 15 is currently on Beta 4.
https://developer.android.com/about/versions/15/overview

Also we need first to compile with sdk 35 and then advance the target to 35.
There is no need to hurry until August 2025.

The current requirement for August 2024 is just the target 34.

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

IDEA has been updated and now supports the latest Android Gradle plugin 8.5.1.

@afischerdev afischerdev merged commit e63cc98 into abrensch:master Jul 23, 2024
2 checks passed
@afischerdev afischerdev deleted the update-android branch July 23, 2024 08:18
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants