Repository navigation
bug: a canceled subscription reads expired while its paid period runs #1413
Description
Twin: synonymdev/bitkit-ios#845
What happened?
Right after Swipe To Cancel, a subscription reads as expired while the period already paid for is still running. STATUS reads "Expired", the timing cell reads "EXPIRED " with the end of that paid period, the list row sits under EXPIRED, dimmed, and it no longer counts toward the ACTIVE count or the monthly cost. Nothing says the paid period is still running.
Bitkit Android showed this on 25 Sep: "Expired" and "EXPIRED November 25" on both sides, while the paid period ran until 25 Nov.
Where, on master (5e990b1):
PaykitSubscription.ktisActive(now)requiresACTIVE_RECURRING, andisExpired(now)countsCANCELEDas expired.SubscriptionsScreen.ktmaps every inactive subscription to "Expired":statusText(now):isActivegives "Active", everything else "Expired".timingTitle(now):!isActive(now)gives "Expired", so the date of a paid period that has not ended yet reads "EXPIRED " (renewalText(now)shows the end of the last paid period).rowSubtitle(now)and the section grouping inSubscriptionsContent:isExpired(now)puts a canceled subscription under EXPIRED, andsubscriptionMonthlyCostSatsskips it.nextSubscriptionTransitionhas no entry for the end of a canceled subscription's paid period, so an open screen would not refresh at that moment.
Expected behavior
The design's renew frame is the state for a subscription that has been canceled but has not expired yet. It reads like an active subscription with an end date:
- STATUS "Active", the list row subtitle "Expires ", and the row listed under ACTIVE (it counts toward the ACTIVE count and the monthly cost).
- The detail timing cell reads "EXPIRES ".
- When the paid period ends it moves to EXPIRED, the timing cell reads "EXPIRED ", and open screens switch at that moment without being reopened.
- A canceled subscription with no end date has no timing cell.
- The footer has More Info and no Cancel. Renew is tracked in Subscriptions: unbuilt controls and the swipe colour rule #1276.
Design (Figma v3 refactor frames): renew frame and list frame.
Steps to Reproduce
- Subscribe to a monthly subscription and pay the first period.
- Open it and Swipe To Cancel.
- See STATUS "Expired" and "EXPIRED " while that date is still ahead; the row moved from ACTIVE to EXPIRED.
Logs / Screenshots / Recordings
The code quotes above. Android on 25 Sep, right after Swipe To Cancel: "Expired" and "EXPIRED November 25".
Bitkit Version
master 5e990b1
Device / OS
Android emulator with a canceled fixture subscription; not checked with a real Swipe To Cancel against a live counterparty.
Reproducibility
Always
Additional context
iOS has the same defect, tracked in synonymdev/bitkit-ios#845. The Figma frames show no "Canceled" label anywhere, so both platforms follow the frames, not the "Canceled" wording in the iOS issue.
Activity