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

chore: add client suffix on debug builds [ACOL-144] #2678

Merged
merged 4 commits into from
Feb 9, 2024

Conversation

Garzas
Copy link
Contributor

@Garzas Garzas commented Feb 9, 2024

TopicACOL-144 Add BUILD_TYPE and FLAVOR to client model name for dev or private builds


PR Submission Checklist for internal contributors

  • The PR Title

    • conforms to the style of semantic commits messages¹ supported in Wire's Github Workflow²
    • contains a reference JIRA issue number like SQPIT-764
    • answers the question: If merged, this PR will: ... ³
  • The PR Description

    • is free of optional paragraphs and you have filled the relevant parts to the best of your ability

What's new in this PR?

Issues

When testing different app builds it's hard to know which device is prod build to not remove while adding new device

Solutions

In private builds add to device name flavor and build type

Preview

Dependencies

This PR depends on:

@Garzas Garzas self-assigned this Feb 9, 2024
@@ -209,7 +210,8 @@ class CreateAccountCodeViewModel @Inject constructor(
clientScopeProviderFactory.create(userId).clientScope.getOrRegister(
RegisterClientUseCase.RegisterClientParam(
password = password,
capabilities = null
capabilities = null,
modelPostfix = if(BuildConfig.PRIVATE_BUILD) " [${BuildConfig.FLAVOR}_${BuildConfig.BUILD_TYPE}]" else null
Copy link
Member

Choose a reason for hiding this comment

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

Is PrivateBuild the correct parameter? Won't clients with custom builds also have that?

Copy link
Member

Choose a reason for hiding this comment

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

Nevermind.

It seems we use PRIVATE_BUILD just for debug stuff. Only visible to us.

I guess we could name it better 🤔
Anyway. LGTM!

Copy link
Contributor

Choose a reason for hiding this comment

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

Just checked and as default we go with false, if not set (like the case of those custom builds)

/**
* Process feature flags and if the feature is not included in a product flavor,
* a default value of "false" or "deactivated" is used.
*
* @see "FeatureFlags.kt" file definition.
*/

@AndroidBob
Copy link
Collaborator

Build 3019 failed.

@vitorhugods vitorhugods changed the title chore: show device with flavor and build type [ACOL-144] chore: add device suffix on debug builds to better identify clients [ACOL-144] Feb 9, 2024
@vitorhugods vitorhugods changed the title chore: add device suffix on debug builds to better identify clients [ACOL-144] chore: add client suffix on debug builds [ACOL-144] Feb 9, 2024
@Garzas Garzas enabled auto-merge February 9, 2024 10:59
Copy link
Contributor

github-actions bot commented Feb 9, 2024

Test Results

816 tests  ±0   816 ✅ ±0   12m 45s ⏱️ -6s
114 suites ±0     0 💤 ±0 
114 files   ±0     0 ❌ ±0 

Results for commit a1ea781. ± Comparison against base commit 0f6bace.

♻️ This comment has been updated with latest results.

@AndroidBob
Copy link
Collaborator

Build 3030 failed.

@Garzas Garzas added this pull request to the merge queue Feb 9, 2024
Copy link

codecov bot commented Feb 9, 2024

Codecov Report

Attention: 9 lines in your changes are missing coverage. Please review.

Comparison is base (0f6bace) 42.88% compared to head (a1ea781) 42.97%.

Additional details and impacted files
@@             Coverage Diff             @@
##           develop    #2678      +/-   ##
===========================================
+ Coverage    42.88%   42.97%   +0.08%     
===========================================
  Files          405      405              
  Lines        13468    13473       +5     
  Branches      2377     2381       +4     
===========================================
+ Hits          5776     5790      +14     
+ Misses        7019     7001      -18     
- Partials       673      682       +9     
Files Coverage Δ
...tication/create/code/CreateAccountCodeViewModel.kt 0.00% <0.00%> (ø)
...cation/devices/register/RegisterDeviceViewModel.kt 67.34% <0.00%> (-1.41%) ⬇️
.../android/ui/authentication/login/LoginViewModel.kt 77.77% <50.00%> (-1.26%) ⬇️
...entication/devices/remove/RemoveDeviceViewModel.kt 0.00% <0.00%> (ø)

... and 3 files with indirect coverage changes


Continue to review full report in Codecov by Sentry.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update 0f6bace...a1ea781. Read the comment docs.

Copy link
Contributor

github-actions bot commented Feb 9, 2024

APKs built during tests are available here. Scroll down to Artifacts!

@AndroidBob
Copy link
Collaborator

Build 3031 succeeded.

The build produced the following APK's:

@github-merge-queue github-merge-queue bot removed this pull request from the merge queue due to no response for status checks Feb 9, 2024
@vitorhugods vitorhugods added this pull request to the merge queue Feb 9, 2024
Merged via the queue into develop with commit 60618af Feb 9, 2024
15 checks passed
@vitorhugods vitorhugods deleted the chore/device-flavor-and-build-type branch February 9, 2024 14:30
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

5 participants