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

Add feature flag and LinkConsumerIncentive struct #9605

Merged
merged 8 commits into from
Nov 20, 2024

Conversation

tillh-stripe
Copy link
Collaborator

@tillh-stripe tillh-stripe commented Nov 12, 2024

Summary

This pull request adds a feature flag for Instant Bank Payments Incentives, and adds the LinkConsumerIncentive struct in ElementsSession.

Motivation

CONSUMERBANK-561

Testing

  • Added tests
  • Modified tests
  • Manually verified

Screenshots

Before After
before screenshot after screenshot

Changelog

Copy link
Contributor

github-actions bot commented Nov 12, 2024

Diffuse output:

OLD: paymentsheet-example-release-master.apk (signature: V1, V2)
NEW: paymentsheet-example-release-pr.apk (signature: V1, V2)

          │           compressed           │          uncompressed          
          ├───────────┬───────────┬────────┼──────────┬──────────┬──────────
 APK      │ old       │ new       │ diff   │ old      │ new      │ diff     
──────────┼───────────┼───────────┼────────┼──────────┼──────────┼──────────
      dex │   3.9 MiB │   3.9 MiB │ +778 B │  8.5 MiB │  8.5 MiB │ +1.6 KiB 
     arsc │   2.3 MiB │   2.3 MiB │    0 B │  2.3 MiB │  2.3 MiB │      0 B 
 manifest │     5 KiB │     5 KiB │    0 B │ 24.9 KiB │ 24.9 KiB │      0 B 
      res │ 904.1 KiB │ 904.1 KiB │    0 B │  1.4 MiB │  1.4 MiB │      0 B 
   native │   2.6 MiB │   2.6 MiB │    0 B │    6 MiB │    6 MiB │      0 B 
    asset │   1.6 MiB │   1.6 MiB │  -21 B │  1.6 MiB │  1.6 MiB │    -21 B 
    other │   1.4 MiB │   1.4 MiB │   +1 B │  1.6 MiB │  1.6 MiB │      0 B 
──────────┼───────────┼───────────┼────────┼──────────┼──────────┼──────────
    total │  12.6 MiB │  12.6 MiB │ +758 B │ 21.5 MiB │ 21.5 MiB │ +1.6 KiB 

 DEX     │ old   │ new   │ diff            
─────────┼───────┼───────┼─────────────────
   files │     1 │     1 │   0             
 strings │ 40336 │ 40346 │ +10 (+45 -35)   
   types │ 13905 │ 13909 │  +4 (+38 -34)   
 classes │ 11596 │ 11598 │  +2 (+7 -5)     
 methods │ 59236 │ 59250 │ +14 (+941 -927) 
  fields │ 39512 │ 39519 │  +7 (+914 -907) 

 ARSC    │ old  │ new  │ diff 
─────────┼──────┼──────┼──────
 configs │  243 │  243 │  0   
 entries │ 6194 │ 6194 │  0
APK
    compressed     │     uncompressed     │                                
──────────┬────────┼───────────┬──────────┤                                
 size     │ diff   │ size      │ diff     │ path                           
──────────┼────────┼───────────┼──────────┼────────────────────────────────
  3.9 MiB │ +778 B │   8.5 MiB │ +1.6 KiB │ ∆ classes.dex                  
  7.8 KiB │  -23 B │   7.7 KiB │    -23 B │ ∆ assets/dexopt/baseline.prof  
  1,011 B │   +2 B │     879 B │     +2 B │ ∆ assets/dexopt/baseline.profm 
 53.3 KiB │   -2 B │ 118.1 KiB │      0 B │ ∆ META-INF/CERT.SF             
  1.2 KiB │   +2 B │   1.2 KiB │      0 B │ ∆ META-INF/CERT.RSA            
   50 KiB │   +1 B │   118 KiB │      0 B │ ∆ META-INF/MANIFEST.MF         
──────────┼────────┼───────────┼──────────┼────────────────────────────────
    4 MiB │ +758 B │   8.7 MiB │ +1.6 KiB │ (total)
DEX
STRINGS:

   old   │ new   │ diff          
  ───────┼───────┼───────────────
   40336 │ 40346 │ +10 (+45 -35) 
  
  + , incentiveDisplayText=
  + , linkConsumerIncentive=
  + IncentiveParams(paymentMethod=
  + Instant Bank Payments Incentives
  + LK6/j3;
  + LK6/k3;
  + LM6/j;
  + LS6/c;
  + Lg8/m;
  + LinkConsumerIncentive(incentiveParams=
  + Lm2/d;
  + Lo3/d;
  + [LK6/K0;
  + [LK6/P0;
  + [LK6/P2;
  + [LK6/R1;
  + [LK6/U0;
  + [LK6/U1;
  + [LK6/U2;
  + [LK6/X1;
  + [LK6/Y0;
  + [LK6/Z2;
  + [LK6/a3;
  + [LK6/g1;
  + [LK6/j3;
  + [LK6/k3;
  + [LK6/m1;
  + [LK6/s1;
  + [LK6/z2;
  + [LM6/i;
  + [LS6/c;
  + [LT2/A;
  + [LT2/p;
  + [LX5/G1;
  + [LX5/O1;
  + [LX5/h;
  + [LX5/l;
  + [LZ6/j;
  + [Ld6/G;
  + [Lf8/y;
  + [Lg8/m;
  + [Lh3/d;
  + [Ln3/t;
  + incentiveParams
  + ~~R8{"backend":"dex","compilation-mode":"release","has-checksums":false,"min-api":21,"pg-map-id":"5188776","r8-mode":"full","version":"8.7.14"}
  
  - LO2/a;
  - LT2/H;
  - Lh3/k;
  - Ln3/v;
  - Lq3/i;
  - [LK6/B2;
  - [LK6/M0;
  - [LK6/R0;
  - [LK6/R2;
  - [LK6/T1;
  - [LK6/W0;
  - [LK6/W1;
  - [LK6/W2;
  - [LK6/Z1;
  - [LK6/a1;
  - [LK6/d3;
  - [LK6/e3;
  - [LK6/h1;
  - [LK6/o1;
  - [LK6/u1;
  - [LM6/f;
  - [LS6/b;
  - [LT2/B;
  - [LT2/r;
  - [LX5/F1;
  - [LX5/N1;
  - [LX5/g;
  - [LX5/k;
  - [LZ6/i;
  - [Ld6/E;
  - [Lf8/w;
  - [Lg8/j;
  - [Lh3/g;
  - [Ln3/v;
  - ~~R8{"backend":"dex","compilation-mode":"release","has-checksums":false,"min-api":21,"pg-map-id":"8d66e65","r8-mode":"full","version":"8.7.14"}
  

TYPES:

   old   │ new   │ diff         
  ───────┼───────┼──────────────
   13905 │ 13909 │ +4 (+38 -34) 
  
  + LK6/j3;
  + LK6/k3;
  + LM6/j;
  + LS6/c;
  + Lg8/m;
  + Lm2/d;
  + Lo3/d;
  + [LK6/K0;
  + [LK6/P0;
  + [LK6/P2;
  + [LK6/R1;
  + [LK6/U0;
  + [LK6/U1;
  + [LK6/U2;
  + [LK6/X1;
  + [LK6/Y0;
  + [LK6/Z2;
  + [LK6/a3;
  + [LK6/g1;
  + [LK6/j3;
  + [LK6/k3;
  + [LK6/m1;
  + [LK6/s1;
  + [LK6/z2;
  + [LM6/i;
  + [LS6/c;
  + [LT2/A;
  + [LT2/p;
  + [LX5/G1;
  + [LX5/O1;
  + [LX5/h;
  + [LX5/l;
  + [LZ6/j;
  + [Ld6/G;
  + [Lf8/y;
  + [Lg8/m;
  + [Lh3/d;
  + [Ln3/t;
  
  - LO2/a;
  - LT2/H;
  - Lh3/k;
  - Ln3/v;
  - Lq3/i;
  - [LK6/B2;
  - [LK6/M0;
  - [LK6/R0;
  - [LK6/R2;
  - [LK6/T1;
  - [LK6/W0;
  - [LK6/W1;
  - [LK6/W2;
  - [LK6/Z1;
  - [LK6/a1;
  - [LK6/d3;
  - [LK6/e3;
  - [LK6/h1;
  - [LK6/o1;
  - [LK6/u1;
  - [LM6/f;
  - [LS6/b;
  - [LT2/B;
  - [LT2/r;
  - [LX5/F1;
  - [LX5/N1;
  - [LX5/g;
  - [LX5/k;
  - [LZ6/i;
  - [Ld6/E;
  - [Lf8/w;
  - [Lg8/j;
  - [Lh3/g;
  - [Ln3/v;
  

METHODS:

   old   │ new   │ diff            
  ───────┼───────┼─────────────────
   59236 │ 59250 │ +14 (+941 -927) 
  
  + B7.j <init>(v, v1, boolean, d)
  + C0.c a(boolean, boolean, c, h2, O1, p, int, int)
  + C0.c b(c, h2, O1, p, int)
  + C0.c g0(q, boolean, g) → X0
  + C7.l <init>(v, v1, boolean, d)
  + D1.f <init>(u, E, c, K1, L1)
  + D5.X d0(String, q, c3, boolean) → boolean
  + D5.X i0(JSONObject) → z2
  + D5.X j0(JSONObject) → b3
  + D5.b <init>(boolean, boolean, c, h2, O1, int, int)
  + D8.u <init>(v1, l, p, v, q)
  + E6.g i(c3, String) → f
  + F2.c d(c3, int) → String
  + F4.B <init>(c2, int, String)
  + F4.B j() → c3
  + F4.F j() → c3
  + F4.b r(K1, T1) → r
  + F4.b s(String, n1, T1) → r
  + F4.c r(K1, T1) → r
  + F4.c s(String, n1, T1) → r
  + F4.t <init>(S0, int, String)
  + F4.t j() → c3
  + F4.v <init>(S0, String)
  + F4.w <init>(c2, String)
  + F4.x <init>(l2, String)
  + F6.j a() → n1
  + F6.l <init>(c3, p0, boolean, boolean, List, c, String, m0, a, List, List, boolean, boolean, b, q, C0, boolean, a)
  + F6.n <init>(X0)
  + F6.n E(boolean, g) → X0
  + F6.o E(boolean, g) → X0
  + F6.p E(boolean, g) → X0
  + F6.q E(boolean, g) → X0
  + F6.r d(v1) → boolean
  + G6.A a() → n1
  + G6.B a() → n1
  + G6.C a() → n1
  + G6.D a() → n1
  + G6.E a() → n1
  + G6.F a() → n1
  + G6.G a() → n1
  + G6.H a() → n1
  + G6.I a() → n1
  + G6.J a() → n1
  + G6.K a() → n1
  + G6.L a() → n1
  + G6.M a() → n1
  + G6.N a() → n1
  + G6.O a() → n1
  + G6.a a() → n1
  + G6.c a() → n1
  + G6.d a() → n1
  + G6.e a() → n1
  + G6.f a() → n1
  + G6.g a() → n1
  + G6.h a() → n1
  + G6.i a() → n1
  + G6.j a() → n1
  + G6.k a() → n1
  + G6.m a() → n1
  + G6.n a() → n1
  + G6.o a() → n1
  + G6.p a() → n1
  + G6.r a() → n1
  + G6.s a() → n1
  + G6.t a() → n1
  + G6.u a() → n1
  + G6.v a() → n1
  + G6.w a() → n1
  + G6.x a() → n1
  + G6.y a() → n1
  + G6.z a() → n1
  + H7.h <init>(String, b1, c, int, String, String)
  + H7.m <init>(K1, i, g, T1, L1)
  + H7.m H() → K1
  + H7.m L() →
...✂

@tillh-stripe tillh-stripe force-pushed the tillh/ibp-incentives-model-changes branch 6 times, most recently from 93ca9d6 to 6d90550 Compare November 19, 2024 18:41
@tillh-stripe tillh-stripe marked this pull request as ready for review November 20, 2024 14:01
@tillh-stripe tillh-stripe requested review from a team as code owners November 20, 2024 14:01
Copy link

emerge-tools bot commented Nov 20, 2024

2 builds increased size, 1 build had no size change

Name Version Download Change Install Change Approval
Stripe Identity Example
com.stripe.android.identity.example.theme1
21.2.0-theme1 (20) 3.8 MB - 8.9 MB - N/A
Financial Connections Example
com.stripe.android.financialconnections.example
21.2.0 (210200) 5.4 MB ⬆️ 599 B (0.01%) 10.7 MB ⬆️ 1.6 kB (0.02%) N/A
PaymentSheet Example
com.stripe.android.paymentsheet.example
21.2.0 (11) 8.4 MB ⬆️ 726 B 15.7 MB ⬆️ 1.6 kB (0.01%) N/A

Stripe Identity Example 21.2.0-theme1 (20)
com.stripe.android.identity.example.theme1

No changes to report

Financial Connections Example 21.2.0 (210200)
com.stripe.android.financialconnections.example

⚖️ Compare build
⏱️ Analyze build performance

Total install size change: ⬆️ 1.6 kB (0.02%)
Total download size change: ⬆️ 599 B (0.01%)

Largest size changes

Item Install Size Change Download Size Change
🗑 com.stripe.android.financialconnections.model.DataAccessNotice$Cr... ⬇️ -8.6 kB ⬇️ -4.0 kB
📝 com.stripe.android.financialconnections.model.CreditBalance$Creat... ⬆️ 8.6 kB ⬆️ 4.0 kB
🗑 com.stripe.android.model.SetupIntent$Creator ⬇️ -8.2 kB ⬇️ -3.9 kB
📝 com.stripe.android.model.PaymentMethodUpdateParams$Card$Networks$... ⬆️ 8.1 kB ⬆️ 3.8 kB
📝 androidx.fragment.app.FragmentManagerState$1 ⬆️ 6.5 kB ⬆️ 3.1 kB
View Treemap

Image of diff

PaymentSheet Example 21.2.0 (11)
com.stripe.android.paymentsheet.example

⚖️ Compare build
⏱️ Analyze build performance

Total install size change: ⬆️ 1.6 kB (0.01%)
Total download size change: ⬆️ 726 B

Largest size changes

Item Install Size Change Download Size Change
🗑 com.google.android.gms.wallet.zzac ⬇️ -9.1 kB ⬇️ -4.2 kB
🗑 com.stripe.android.financialconnections.model.BalanceRefresh$Crea... ⬇️ -8.5 kB ⬇️ -3.9 kB
📝 com.stripe.android.financialconnections.model.AddNewAccount$Creat... ⬆️ 8.5 kB ⬆️ 3.9 kB
📝 androidx.versionedparcelable.ParcelImpl$1 ⬆️ 7.6 kB ⬆️ 3.5 kB
🗑 com.stripe.android.model.PaymentMethodOptionsParams$WeChatPay$Cre... ⬇️ -7.3 kB ⬇️ -3.3 kB
View Treemap

Image of diff


🛸 Powered by Emerge Tools

We now get the formatted display text from the API.
- Use feature flag earlier
- Rename feature flag
No longer needed, as more stuff is happening on the server.
@tillh-stripe tillh-stripe force-pushed the tillh/ibp-incentives-model-changes branch from 8c82b3e to 33fe998 Compare November 20, 2024 16:26
@tillh-stripe tillh-stripe merged commit 7005003 into master Nov 20, 2024
16 checks passed
@tillh-stripe tillh-stripe deleted the tillh/ibp-incentives-model-changes branch November 20, 2024 16:41
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.

2 participants