The Stripe statuses that suspend a plan are listed again in the operator's billing card and the test kit instead of read from the reconcile #276
Open
opened 2026-10-26 20:58:25 +00:00 by cgalo5758
·
0 comments
Labels
Clear labels
accessibility
area/billing
area/catalog
area/discourse
area/domains
area/entitlements
area/fedwiki
area/identity
area/integrations
area/licensing
area/member-ui
area/meta
area/operator-ui
area/ops
area/testing
duplicate
good-first-issue
invalid
privacy
security
upstream
wontfix
A barrier for people using assistive technology or a keyboard alone.
The Stripe mirror, checkout, subscriptions, invoices, fulfillment.
Products, prices, plan ladders, purchasability.
The Discourse integration.
The domains registry, claims, placements, the certificate ask.
Entitlement sets, rules, grants, pools, provisioning.
The Federated Wiki integration and farm sync.
Sign-in, sessions, persons, organizations, workspaces, roles.
The provider registry, outbox and webhooks in general.
Licenses, the contributor agreement, SPDX headers.
Member pages.
The repository itself, its contributing guide, CI, the tracker and the workflow.
Operator pages, forms, lists, the design system.
Deployment, configuration, migrations, workflows, instance settings.
The test stack, screens, lint, walkthroughs.
Closed because another issue already covers it.
Small, self-contained, and explained enough to be a first contribution.
Closed because it is not a ticket for this repository.
Touches what a person's data reveals.
Touches authentication, authorization, secrets or data exposure.
Waits on another repository or project before it can move.
Closed because it will not be done, with the reason in the last comment.
kind
bug
The software does something other than what it promises; closed when it again does what it promises.
kind
debt
Code, tests or tooling to clean up with nothing visible changing; closed when they are cleaner.
kind
design
A question to settle before work can be defined; closed when the decision is written down.
kind
docs
Documentation that is wrong or missing; closed when it says the right thing.
kind
enhancement
Something the software does not do yet; closed when it does.
priority
critical
Blocks the active milestone or harms members now.
priority
high
Next in line inside the active milestone.
priority
low
Inside the active milestone, when nothing else is left.
priority
medium
Inside the active milestone, after the high ones.
Milestone
No items
No Milestone
Projects
Clear projects
No projects
No Assignees
Notifications
Due Date
No due date set.
Dependencies
No dependencies set.
Reference: wiki-cafe/member-console#276
Reference in New Issue
Block a user
Blocking a user prevents them from interacting with repositories, such as opening or commenting on pull requests or issues. Learn more about blocking a user.
What a contributor runs into
The console sorts each Stripe subscription status into a class:
activeandtrialingdeliver the plan.past_due,unpaidandpausedkeep the plan but suspend what it delivers.canceledandincomplete_expiredend it.incompleteis recorded and delivers nothing yet.The reconcile reads a subscription from Stripe and brings the console's records in line with it. It decides delivery with
classifyStatus(internal/fulfillment/reconcile.go:1042-1053). Other code that needs the same answer does not askclassifyStatus. It lists the statuses again:subscriptionStatePrecedence(internal/server/operator_enrollment.go:380) ranks the states of the operator's billing card with the three suspending ones first, and its comment (lines 370-379) restates why.subscriptionState(lines 395-399) treatsactiveandtrialingas the healthy pair that a period-end cancellation turns into "canceling".subscriptionPeriodNote(lines 441-453) lists the three suspending statuses (line 442) and the two ending ones (line 443). It uses them to choose between "renews {date}", "ends {date}" and no note.subscriptionMayBeDisplaced(lines 460-466) lists the five delivering and suspending statuses. It uses them to decide whether a subscription still pays for its tiers.CountLiveSubscriptionsByStatus(internal/billing/queries/subscriptions.sql:95-104) countsactiveandtrialingas the subscriptions owed service, for the operator overview's Monthly recurring caption.Suspend(internal/testkit/world/plans.go:377-383) accepts onlypast_due,unpaidandpaused, and writes the suspension the reconcile writes for them.The copies already disagree on one status. The reconcile gives an
incompletesubscription nothing (reconcile.go:1050-1051). The card's period note falls silent only forcanceledandincomplete_expired, so it reads anincompletesubscription as renewing on its period end.Why it costs
#255 asks whether a past-due plan should keep delivering for a grace period. Any answer other than suspending at once changes
classifyStatus, and every copy has to change with it. If one copy is missed, nothing fails. The operator's card then ranks a delivering subscription with the suspended ones and says it does not renew, or the test kit writes a suspension the reconcile no longer writes. A status that Stripe adds later also lands in each copy's default separately.Where
internal/fulfillment/reconcile.go,internal/server/operator_enrollment.go,internal/billing/queries/subscriptions.sql,internal/testkit/world/plans.goDone when
One exported function names the class of each subscription status. The reconcile, the four functions in
operator_enrollment.goand the test kit'sSuspendread that function. The overview's count takes its statuses from the function, or its comment names the class it counts. A test fails when a status that the schema's check constraint allows (internal/db/migrations/00010_schema_hardening.sql:65-66) has no class.