<?xml version="1.0" encoding="UTF-8"?>
<rss version="2.0" xmlns:atom="http://www.w3.org/2005/Atom" xmlns:dc="http://purl.org/dc/elements/1.1/">
  <channel>
    <title>DEV Community: Mahmood Ali</title>
    <description>The latest articles on DEV Community by Mahmood Ali (@mahmoodali_duvello).</description>
    <link>https://dev.to/mahmoodali_duvello</link>
    <image>
      <url>https://media2.dev.to/dynamic/image/width=90,height=90,fit=cover,gravity=auto,format=auto/https:%2F%2Fdev-to-uploads.s3.us-east-2.amazonaws.com%2Fuploads%2Fuser%2Fprofile_image%2F4265649%2Fb7c4ddc9-7151-43c6-9958-55c1a76a9ee5.jpg</url>
      <title>DEV Community: Mahmood Ali</title>
      <link>https://dev.to/mahmoodali_duvello</link>
    </image>
    <atom:link rel="self" type="application/rss+xml" href="https://dev.to/feed/mahmoodali_duvello"/>
    <language>en</language>
    <item>
      <title>5 production-only bugs I hit shipping my first Android app as a solo founder</title>
      <dc:creator>Mahmood Ali</dc:creator>
      <pubDate>Wed, 25 Nov 2026 23:59:10 +0000</pubDate>
      <link>https://dev.to/mahmoodali_duvello/5-production-only-bugs-i-hit-shipping-my-first-android-app-as-a-solo-founder-22g1</link>
      <guid>https://dev.to/mahmoodali_duvello/5-production-only-bugs-i-hit-shipping-my-first-android-app-as-a-solo-founder-22g1</guid>
      <description>&lt;p&gt;I'm Mahmood, a solo founder from Pakistan. Last month I shipped &lt;strong&gt;Duvello AI&lt;/strong&gt;, a bill reminder app for Android: you snap a paper bill (or paste the bill SMS), AI fills in the biller, amount and due date, and the app reminds you before every due date. It works offline and in 6 languages.&lt;/p&gt;

&lt;p&gt;The stack is boring on purpose:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;
&lt;strong&gt;React + Vite&lt;/strong&gt; for the UI&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Capacitor&lt;/strong&gt; to wrap it as a native Android app&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Firebase&lt;/strong&gt; (Auth, Firestore, Cloud Functions, Crashlytics, Hosting)&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Google Play Billing&lt;/strong&gt; for Premium&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;Everything worked perfectly in debug builds on my own phone. Then I shipped, and five bugs showed up that &lt;strong&gt;only existed in production&lt;/strong&gt;. If you're about to ship a Capacitor or React Native app, I hope this saves you a few nights.&lt;/p&gt;

&lt;h2&gt;
  
  
  1. R8 silently deleted a plugin class, and only in release builds
&lt;/h2&gt;

&lt;p&gt;My Settings screen crashed instantly in the Play Store build. In debug it was fine.&lt;/p&gt;

&lt;p&gt;The cause: &lt;code&gt;minifyEnabled true&lt;/code&gt; turns on R8, which strips classes it thinks are unused. Capacitor finds native plugins &lt;strong&gt;by reflection&lt;/strong&gt;, so R8 had no idea the Google Sign-In plugin class was needed and removed it.&lt;/p&gt;

&lt;p&gt;The fix was explicit keep rules in &lt;code&gt;proguard-rules.pro&lt;/code&gt;:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;-keep class com.getcapacitor.** { *; }
-keep class com.codetrixstudio.capacitor.GoogleAuth.** { *; }
-keep class com.google.firebase.** { *; }
-keep class com.google.android.gms.** { *; }
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;A month later I hit the exact same class of bug with the in-app purchase plugin. &lt;strong&gt;Lesson:&lt;/strong&gt; every time you add a native plugin, add a keep rule in the same commit, and test a &lt;em&gt;release&lt;/em&gt; build on a real device before uploading.&lt;/p&gt;

&lt;h2&gt;
  
  
  2. "Purchase failed" for three months, because there was nothing to buy
&lt;/h2&gt;

&lt;p&gt;My purchase flow wiring was all there: service account, a &lt;code&gt;verifyPurchase&lt;/code&gt; Cloud Function, the right Play Console permissions. Every test purchase still failed.&lt;/p&gt;

&lt;p&gt;The real reason was embarrassing. I had never actually created the subscription products under &lt;strong&gt;Monetize with Play&lt;/strong&gt;. There was a bare "Get started" button sitting there the whole time. No products means nothing to buy, whatever your code does.&lt;/p&gt;

&lt;p&gt;Then a second issue: my client code still registered the &lt;strong&gt;old product IDs&lt;/strong&gt; from before I renamed the app. The IDs in code must match Play Console character for character.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Lesson:&lt;/strong&gt; before debugging code, open the console and confirm the thing you're trying to buy actually exists, with the exact ID your code asks for.&lt;/p&gt;

&lt;h2&gt;
  
  
  3. Trusting the client for purchases was the wrong design
&lt;/h2&gt;

&lt;p&gt;My first version verified purchases from the app. It was fragile: confirmations arrived late, the app reported failure too early, and a purchase that was never &lt;em&gt;acknowledged&lt;/em&gt; gets auto-refunded by Google after a few days.&lt;/p&gt;

&lt;p&gt;The version that finally worked moved everything server-side:&lt;/p&gt;

&lt;ol&gt;
&lt;li&gt;The app tags each purchase with the user's Firebase UID (&lt;code&gt;obfuscatedAccountId&lt;/code&gt;).&lt;/li&gt;
&lt;li&gt;Google Play &lt;strong&gt;Real-time Developer Notifications&lt;/strong&gt; publish to a Pub/Sub topic.&lt;/li&gt;
&lt;li&gt;A Cloud Function (&lt;code&gt;onPlayRtdn&lt;/code&gt;) verifies the purchase with the Play Developer API, acknowledges it, and writes the entitlement to Firestore.&lt;/li&gt;
&lt;li&gt;The app only &lt;strong&gt;listens&lt;/strong&gt; to Firestore. Security rules let it read Premium status but never write it.&lt;/li&gt;
&lt;/ol&gt;

&lt;p&gt;I also keep a per-purchase ledger (&lt;code&gt;users/{uid}/purchases/{token}&lt;/code&gt;) and recompute the entitlement from all active purchases. Before I did that, a monthly renewal overwrote a Lifetime purchase. Lifetime should always win.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Lesson:&lt;/strong&gt; for payments, the client should display state, never decide it.&lt;/p&gt;

&lt;h2&gt;
  
  
  4. Logs were useless until I added breadcrumbs
&lt;/h2&gt;

&lt;p&gt;Without a USB cable for logcat, I was guessing. I wired purchase, restore, store-init and sync errors into &lt;strong&gt;Firebase Crashlytics as non-fatal errors&lt;/strong&gt;, with the UID set as the user ID and breadcrumbs at each step.&lt;/p&gt;

&lt;p&gt;Within one test, the breadcrumbs showed the bug: the purchase validator callback was receiving &lt;code&gt;productId: "unknown"&lt;/code&gt;, because it read the wrong fields from the plugin's purchase object. The server was never even being called.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Lesson:&lt;/strong&gt; add structured, step-by-step breadcrumbs to every money path &lt;em&gt;before&lt;/em&gt; you need them.&lt;/p&gt;

&lt;h2&gt;
  
  
  5. Reminder emails at 9 AM... for whom?
&lt;/h2&gt;

&lt;p&gt;My first scheduled reminder function ran at a fixed UTC time. That means 2 PM for my users in Pakistan and 4 AM for someone in California.&lt;/p&gt;

&lt;p&gt;The fix: an hourly scheduled function that sends each user's reminders when it's &lt;strong&gt;9 AM in their own time zone&lt;/strong&gt;, plus a user-chosen summary schedule (daily, weekly or monthly). Emails go out through Resend from my own domain.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Lesson:&lt;/strong&gt; "send at 9 AM" is a per-user requirement, not a cron expression.&lt;/p&gt;

&lt;h2&gt;
  
  
  Bonus: the boring infrastructure that saved me
&lt;/h2&gt;

&lt;ul&gt;
&lt;li&gt;
&lt;strong&gt;Firestore daily backups and point-in-time recovery.&lt;/strong&gt; Turn them on before launch, not after.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;A budget alert on the Cloud billing account.&lt;/strong&gt; My card was once declined, billing got disabled, and every Cloud Function started failing with "billing is disabled for this project." The app looked broken for reasons that had nothing to do with code.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Your Play developer name shows in emails and on the listing.&lt;/strong&gt; I had to rename mine after rebranding.&lt;/li&gt;
&lt;/ul&gt;

&lt;h2&gt;
  
  
  Where it is now
&lt;/h2&gt;

&lt;p&gt;Duvello AI is live on Google Play in 177 countries. The core features are free: reminders, budgets, offline use, 6 languages and 5 AI bill scans a month.&lt;/p&gt;

&lt;p&gt;👉 &lt;a href="https://play.google.com/store/apps/details?id=com.lifeledger.ai" rel="noopener noreferrer"&gt;Duvello AI on Google Play&lt;/a&gt; · &lt;a href="https://duvello.app" rel="noopener noreferrer"&gt;duvello.app&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;If you're building with Capacitor and Play Billing and you're stuck on something similar, ask in the comments. I've probably hit it.&lt;/p&gt;

</description>
      <category>android</category>
      <category>react</category>
      <category>firebase</category>
      <category>startup</category>
    </item>
  </channel>
</rss>
