Renew expired SaaS error: Subscription is not upgradable
### Summary Coming from MRs !2408 and !2674 to allow renewing expired subscriptions during a grace period. Possibly related to #2574. [Customer](https://gitlab.zendesk.com/agent/tickets/204835) has an expired subscription which presents the `Renew` button because it's within grace period. Clicking that to enter the renew workflow (`/subscriptions/A-S00000000/renew`) results in > Subscription is not upgradable The order details can be found [in this note](https://gitlab.com/gitlab-com/support/internal-requests/-/issues/5689#note_549554909). ### Steps to reproduce Try to renew the expired subscription ### Relevant logs and/or screenshots [Sentry error](https://sentry.gitlab.net/gitlab/customersgitlabcom/issues/2551037/events/40208029/) states > Errors::NotFoundError: Order not found Which is thrown by [namespace_controller](https://gitlab.com/gitlab-org/customers-gitlab-com/-/blob/652029e95dd76d9d7597aa83d4d22db217f32841/app/controllers/gitlab/namespaces_controller.rb#L25) when [locating an order](https://gitlab.com/gitlab-org/customers-gitlab-com/-/blob/652029e95dd76d9d7597aa83d4d22db217f32841/app/controllers/gitlab/namespaces_controller.rb#L54-62). Possibly, due to `.with_self_service_gitlab_plan` [scoping orders](https://gitlab.com/gitlab-org/customers-gitlab-com/-/blob/652029e95dd76d9d7597aa83d4d22db217f32841/app/models/order.rb#L34) to [Plan.self_service_gitlab_com_plans](https://gitlab.com/gitlab-org/customers-gitlab-com/-/blob/652029e95dd76d9d7597aa83d4d22db217f32841/app/models/plan.rb#L392-395): ```ruby @@self_service_gitlab_com_plans ||= DEPRECATED_SAAS_GITLAB_PLANS + [PREMIUM_SAAS_1_YEAR_PLAN, ULTIMATE_SAAS_1_YEAR_PLAN] ``` None of which appear to contain `FREE_PLAN`, which the expired order is set to via `product_rate_plan_id: "free-plan-id"`. ### Workarounds - Sales assisted - Purchase new subscription ### Reported examples 1. https://gitlab.zendesk.com/agent/tickets/204835 1. https://gitlab.zendesk.com/agent/tickets/206351 1. https://gitlab.zendesk.com/agent/tickets/212091 1. https://gitlab.zendesk.com/agent/tickets/211449 1. https://gitlab.zendesk.com/agent/tickets/212874 1. https://gitlab.zendesk.com/agent/tickets/251911 1. https://gitlab.zendesk.com/agent/tickets/253597 1. https://gitlab.zendesk.com/agent/tickets/254719 1. https://gitlab.zendesk.com/agent/tickets/257772 <!--- Please add both severity and priority level according to: https://docs.gitlab.com/ee/development/contributing/issue_workflow.html#severity-labels --->
issue