fix(billing): follow Mollie's next charge date after a retried renewal #138
Etiketter
Inga etiketter
area/backups
area/ci
area/control-panel
area/identity
area/infra
area/observability
area/payments
area/security
area/storage
area/web
blocked
needs-info
needs-triage
priority
high
priority
low
priority
medium
ready-for-implementation
type
bug
type
chore
type
docs
type
epic
type
feature
type
task
wontfix
Ingen milstolpe
Inget projekt
Inga tilldelade
1 deltagare
Notiser
Förfallodatum
Inget förfallodatum satt.
Beroenden
Inga beroenden satta
Referens
bitborg/bitborg-payment#138
Läser in…
Hänvisa till i nytt ärende
Ingen beskrivning angiven.
Ta bort grenen "%!s()"
Borttagning av en gren är permanent. Även om den borttagna grenen kan fortsätta existera en kort tid innan den faktiskt tas bort, kan det INTE ångras i de flesta fall. Vill du fortsätta?
Our period end and next charge date come from a fixed anchor (
src/billing.ts:210-265, "The anchor never moves"; README lines 61-62). Mollie moves its schedule after a retried renewal:https://docs.mollie.com/docs/recurring-payments
Failing case, monthly, anchor day 2:
nextCharge.onsays Dec 2, so the 7-day reminder gives the wrong date.active.Fix: after applying a renewal, read the Mollie subscription and set
periodEndfromnextPaymentDate(Amsterdam midnight minus 1 ms). Use the same value fornextCharge.on. Keep the local calculation as the fallback. Correct the README.Not verified: test mode cannot force a failed renewal, so the retry path is untested end to end.