Page MenuHomePhabricator

Create database migration for donor data tables
Open, Needs TriagePublic

Description

NOTE: This is a technical subticket of T390611: Extract Donor data into tables.

Acceptance criteria

Implementation Notes

  • This should be branched off the changes in T390618: Write Donor entities when saving donation
  • You can test the migration like this:
    1. Change the fundraising-donation dependency in composer.json to the migration branch
    2. Change the FunFunFactory to match the new dependencies
    3. Try creating a donation. It should fail because of the missing tables
    4. Run run the migration in your local environment.
    5. Try creating a donation again. It should succeeed and the data should show up in the new tables
    6. Try out other donation types. It should succeeed and the data should show up in the new tables
    7. Try out the scrubbing script for donations. it should succeed and delete the old entries, replacing them with scrubbed donors
  • If the migration does not work, do the following steps:
    1. Update the migration branch (with force-push)
    2. Update dependencies with make update-php to get the newest release
    3. Drop the database with docker compose down -v
    4. Start the environment
    5. Run the migration again

DO NOT regenerate the SQL with make generate-database-schema! That would make the the migration impossible. Regenerating the schema in the local environment is part of T369160: Change Fundraising Application to support individual street name and house number fields

Event Timeline

gabriel-wmde renamed this task from Create database migration for new tables to Create database migration for donor data tables.May 10 2025, 4:27 PM