Skip to content

Update migration: handle deleted events and delisted days - #1132

Open
ionous wants to merge 8 commits into
shift-org:mainfrom
ionous:update-migration
Open

ionous wants to merge 8 commits into
shift-org:mainfrom
ionous:update-migration

Conversation

@ionous

@ionous ionous commented Nov 6, 2026

Copy link
Copy Markdown
Contributor

summary of changes:

  1. updates the v2 tables and the migration tool to handle deleted events and delisted days.
    1. adds a "revoked" reason column to cal_series table
    2. forces the collation of the eventstatus view
    3. no longer excludes deleted events or delisted days during migration
    4. improves created/modified time ordering during migration
  2. sets mysql connection collation ( ex. when running ./shift mysql )
  3. misc view changes to support deleted/hidden data (ex. generates 'D' for delisted days. ) these changes are carried over from the db-next branch; they aren't in use yet. includes a fix for storing an unspecified "ridelength" for db-next data.

steps to migrate:

running the migration adds new data; it doesn't affect existing data.

  1. merge this branch and update production code
  2. generate migration sql file:
    ./shift compose exec node npm run --silent -w tools mysql-migrate > /tmp/reorg.sql
  3. inspect to see its basically okay
    ex. at the bottom of the generated output there will be notes about events it skipped because there were no scheduled days, invalid image types, and rewrites to handle legacy 'E' exception events ( so far as i can tell, these were events which were copies so that the start time could be adjusted. the migration fully clones them and sets their status to 'A' )
  4. use shift script to import it:
    ./shift mysql-pipe < /tmp/reorg.sql

testing

to test things we could:

  1. stand up a test server,
  2. update it with the db-next branch
  3. run the migration
  4. compare the results to production.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant