Skip to content

Conversation

@avazirna
Copy link
Contributor

@avazirna avazirna commented Mar 13, 2025

Product Description

This PR makes the necessary changes to ensure compatibility with Android 15 Edge-to-edge mode. This consisted mainly of assessing the window insets and then adjust the padding of the system content view. The impact to the UI is:

Android 14 and lower Android 15+
image-20250902-121244

Safety Assurance

Safety story

These changes will have to go through regression testing.

Labels and Review

  • Do we need to enhance the manual QA test coverage ? If yes, the "QA Note" label is set correctly
  • Does the PR introduce any major changes worth communicating ? If yes, the "Release Note" label is set and a "Release Note" is specified in PR description.
  • Risk label is set correctly
  • The set of people pinged as reviewers is appropriate for the level of risk of the change

@coderabbitai
Copy link

coderabbitai bot commented Mar 13, 2025

📝 Walkthrough

Walkthrough

This pull request updates the targetSdkVersion in two separate build.gradle files. Specifically, in both the app/build.gradle and commcare-support-library/build.gradle files, the targetSdkVersion within the defaultConfig block has been incremented from 34 to 35. All other configuration settings in these files remain unchanged.

Possibly related PRs

  • Remove directly bundled libraries #2981: This PR also involves modifications to the targetSdkVersion in the defaultConfig section of a build.gradle file, indicating a closely related change at the code level.

Suggested labels

skip-integration-tests, QA Note

Suggested reviewers

  • shubham1g5
  • OrangeAndGreen

Tip

⚡🧪 Multi-step agentic review comment chat (experimental)
  • We're introducing multi-step agentic chat in review comments. This experimental feature enhances review discussions with the CodeRabbit agentic chat by enabling advanced interactions, including the ability to create pull requests directly from comments.
    - To enable this feature, set early_access to true under in the settings.

📜 Recent review details

Configuration used: CodeRabbit UI
Review profile: CHILL
Plan: Pro

📥 Commits

Reviewing files that changed from the base of the PR and between 475f469 and 48f247e.

📒 Files selected for processing (2)
  • app/build.gradle (1 hunks)
  • commcare-support-library/build.gradle (1 hunks)
⏰ Context from checks skipped due to timeout of 90000ms (1)
  • GitHub Check: Lint Code Base
🔇 Additional comments (2)
app/build.gradle (1)

254-256: Update of targetSdkVersion to 35

This change updates the targetSdkVersion from 34 to 35 to align the app with Android 15. Please ensure that the app’s behavior, permissions, and UI elements are thoroughly tested on Android 15 devices or emulators to catch any compatibility issues.

commcare-support-library/build.gradle (1)

44-48: Update of targetSdkVersion to 35 in Library Module

The targetSdkVersion in the defaultConfig block has been updated to 35, keeping it consistent with the main app. Ensure that the library functions as expected under Android 15 conditions and that none of the library’s dependencies are adversely affected by the update.


Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share
🪧 Tips

Chat

There are 3 ways to chat with CodeRabbit:

  • Review comments: Directly reply to a review comment made by CodeRabbit. Example:
    • I pushed a fix in commit <commit_id>, please review it.
    • Generate unit testing code for this file.
    • Open a follow-up GitHub issue for this discussion.
  • Files and specific lines of code (under the "Files changed" tab): Tag @coderabbitai in a new review comment at the desired location with your query. Examples:
    • @coderabbitai generate unit testing code for this file.
    • @coderabbitai modularize this function.
  • PR comments: Tag @coderabbitai in a new PR comment to ask questions about the PR branch. For the best results, please provide a very specific query, as very limited context is provided in this mode. Examples:
    • @coderabbitai gather interesting stats about this repository and render them as a table. Additionally, render a pie chart showing the language distribution in the codebase.
    • @coderabbitai read src/utils.ts and generate unit testing code.
    • @coderabbitai read the files in the src/scheduler package and generate a class diagram using mermaid and a README in the markdown format.
    • @coderabbitai help me debug CodeRabbit configuration file.

Note: Be mindful of the bot's finite context window. It's strongly recommended to break down tasks such as reading entire modules into smaller chunks. For a focused discussion, use review comments to chat about specific files and their changes, instead of using the PR comments.

CodeRabbit Commands (Invoked using PR comments)

  • @coderabbitai pause to pause the reviews on a PR.
  • @coderabbitai resume to resume the paused reviews.
  • @coderabbitai review to trigger an incremental review. This is useful when automatic reviews are disabled for the repository.
  • @coderabbitai full review to do a full review from scratch and review all the files again.
  • @coderabbitai summary to regenerate the summary of the PR.
  • @coderabbitai generate docstrings to generate docstrings for this PR.
  • @coderabbitai resolve resolve all the CodeRabbit review comments.
  • @coderabbitai configuration to show the current CodeRabbit configuration for the repository.
  • @coderabbitai help to get help.

Other keywords and placeholders

  • Add @coderabbitai ignore anywhere in the PR description to prevent this PR from being reviewed.
  • Add @coderabbitai summary to generate the high-level summary at a specific location in the PR description.
  • Add @coderabbitai anywhere in the PR title to generate the title automatically.

CodeRabbit Configuration File (.coderabbit.yaml)

  • You can programmatically configure CodeRabbit by adding a .coderabbit.yaml file to the root of your repository.
  • Please see the configuration documentation for more information.
  • If your editor has YAML language server enabled, you can add the path at the top of this file to enable auto-completion and validation: # yaml-language-server: $schema=https://coderabbit.ai/integrations/schema.v2.json

Documentation and Community

  • Visit our Documentation for detailed information on how to use CodeRabbit.
  • Join our Discord Community to get help, request features, and share feedback.
  • Follow us on X/Twitter for updates and announcements.

@avazirna avazirna force-pushed the android-15-update branch from 48f247e to 3976022 Compare July 15, 2025 16:04
@avazirna avazirna changed the title [Test] Android 15 update Android 15 update Aug 6, 2025
@avazirna avazirna changed the title Android 15 update Android 15 compatibility changes Aug 6, 2025
@avazirna avazirna added this to the 2.59 milestone Aug 6, 2025
@avazirna avazirna added Release Note QA Note High Risk If the PR introduce high risk changes that has high probability of introducing breaking changes and removed don't pull labels Aug 6, 2025
@avazirna avazirna requested a review from shubham1g5 August 6, 2025 23:09
@shubham1g5
Copy link
Contributor

shubham1g5 commented Aug 7, 2025

@avazirna I think it will be cruicial for you to test this on various layouts for this PR to be merged. I am concerned how this behaves on for example list or scrolling layouts, fragments with their own view etc.

Also seems like there are a bunch of other considerations in https://developer.android.com/develop/ui/views/layout/edge-to-edge that we need to account and test for ?

@avazirna
Copy link
Contributor Author

avazirna commented Aug 7, 2025

@avazirna I think it will be cruicial for you to test this on various layouts for this PR to be merged. I am concerned how this behaves on for example list or scrolling layouts, fragments with their own view etc.

Yes, @shubham1g5, I spent a great deal of time testing this, but there can be aspects to polish. I will add some screenshots to make this more clear.

@shubham1g5
Copy link
Contributor

Thanks for confirming @avazirna . Can you add a QA note to this PR along with a list of things that QA should test for this change as well and devices they should use. I think it's important for QA to know of this upcoming change beforehand as it's not in the QA's plans currently and might affect the timelines on the release signifcantly.

}
}

public int getRootViewId() {
Copy link
Contributor

Choose a reason for hiding this comment

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

  1. this should be an abstract method as activities must implement this.
  2. On Connect, a single activity host multiple fragments with their own views. Is there no generalised way to get a root view of the current screen instead of assigning IDs to the xml layouts ?

Copy link
Contributor Author

Choose a reason for hiding this comment

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

@shubham1g5 I switched to content view

@avazirna avazirna changed the title Android 15 compatibility changes Android 15 Edge to Edge Aug 7, 2025
@avazirna avazirna changed the title Android 15 Edge to Edge Android 15 Edge to Edge support Aug 7, 2025
@avazirna avazirna changed the base branch from master to android-15-update-optoout-edge-to-edge August 7, 2025 10:28
@avazirna avazirna marked this pull request as draft August 7, 2025 10:55
Base automatically changed from android-15-update-optoout-edge-to-edge to master August 7, 2025 12:20
@avazirna avazirna modified the milestones: 2.59, 2.60 Aug 10, 2025
@avazirna
Copy link
Contributor Author

avazirna commented Sep 2, 2025

@damagatchi retest this please

@avazirna avazirna marked this pull request as ready for review September 2, 2025 17:18
@avazirna avazirna requested a review from shubham1g5 September 3, 2025 08:30
import androidx.appcompat.app.AppCompatActivity;
import androidx.core.view.WindowInsetsControllerCompat;

public class NoCommCareActivity extends AppCompatActivity {
Copy link
Contributor

Choose a reason for hiding this comment

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

Think we should have CommCareActivity also extend from this so that we only put this logic in one place, also might make sense to name it CommonBaseActivity if we do that.

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Yeah, it's a cleaner option - Refactor

shubham1g5
shubham1g5 previously approved these changes Sep 9, 2025
Copy link
Contributor

@shubham1g5 shubham1g5 left a comment

Choose a reason for hiding this comment

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

Left a suggestion but nothing blocking.

@avazirna avazirna merged commit 88a6c64 into master Sep 19, 2025
6 of 10 checks passed
@avazirna avazirna deleted the android-15-update branch September 19, 2025 14:35
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

High Risk If the PR introduce high risk changes that has high probability of introducing breaking changes QA Note Release Note

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants