Tenant Migrations and the Perils of Implicit State
The Reimpact/platform project involves managing multi-tenant applications. One subtle issue arose related to running migrations within these tenants. The original approach, while seemingly straightforward, introduced an unexpected dependency on implicit state, leading to incorrect migration behavior.
The Problem
Initially, tenant migrations were executed using Laravel's