Show Email OTP Countdown Immediately After Screen Recreation - #3942
Conversation
…mes, so a restored wait is never blank after recreation. Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com>
|
Navigate logical layers of code changes, visualize relationships, and explore their blast radius. No actionable comments were generated in the recent review. 🎉 ℹ️ Recent review info⚙️ Run configurationConfiguration used: Repository UI Review profile: CHILL Plan: Advanced Run ID: 📒 Files selected for processing (1)
Included review availability: This review used your included allowance. Your plan provides up to 1 included review per hour; 0 remain after this review. 📝 WalkthroughWalkthrough
Priority: ⬇️ Low Estimated code review effort: 1 (Trivial) | ~3 minutes Change: Bug fix Suggested reviewers: Merge Risk: ⚪ Minimal · up to The resend countdown starts immediately after the screen resumes, and repeated resumes do not create duplicate timer callbacks. No concrete issue remains to resolve before merging. 🚥 Pre-merge checks | ✅ 4 | ❌ 1❌ Failed checks (1 warning)
✅ Passed checks (4 passed)
✨ Finishing Touches 💡 1📝 Generate docstrings 💡
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. Comment |
…email-otp-countdown-after-recreation
Codecov Report✅ All modified and coverable lines are covered by tests. Additional details and impacted files@@ Coverage Diff @@
## master #3942 +/- ##
============================================
- Coverage 36.86% 36.83% -0.03%
+ Complexity 6747 6743 -4
============================================
Files 1032 1032
Lines 60857 60860 +3
Branches 7399 7399
============================================
- Hits 22432 22416 -16
- Misses 35825 35844 +19
Partials 2600 2600 ☔ View full report in Codecov by Harness. 🚀 New features to boost your workflow:
|
Product Description
After the email verification screen is recreated (font size or dark mode change, or the app being reclaimed in the background), the resend countdown now shows straight away instead of being blank for about 100ms.
Technical Summary
The email screen's first countdown update was posted with a 100ms delay, so a restored view stayed blank until it fired. The phone verification screen already avoids this by updating before starting its timer; this brings the email screen in line.
Why this fails the unit tests in #3929:
a server-supplied wait survives a configuration changereads the countdown right afterrecreate()without advancing Robolectric's clock. On master it only passes because the app bar's elevation animation moves the fake clock about 195ms during recreation, past the 100ms delay. #3929 moves PersonalID onto ConnectTheme, whoseWidget.Connect.AppBarLayoutremoves that animation, so only about 45ms pass and the test reads the still-blank view. This PR should merge before #3929.Safety Assurance
Safety story
What gives confidence
Risks to review
onResumeandrequestOtp, before the 1s ticks start.Automated test coverage
No new tests; the existing saved-state test covers the restored countdown once #3929's theme removes the incidental clock advance.
🤖 Generated with Claude Code