Page MenuHomePhabricator

Migration "20160223.paste.fileedges.php" fails after the "Paste" database was renamed
Closed, ResolvedPublic

Description

See https://discourse.phabricator-community.org/t/storage-upgrade-error/3748/.

At time of writing, the 20160223.paste.fileedges.php migration currently fails. It attempts to write edges into the paste database, but the database will be named pastebin in the state when the patch runs (it was renamed by D20661).

It's probably reasonable to insert these edges with bare INSERT IGNORE ... statements.

Event Timeline

epriestley triaged this task as Wishlist priority.Apr 15 2020, 6:05 PM
epriestley created this task.

I think I'm just going to no-op this migration.

Although EdgeEditor could be modified to take a particular database name, this code would only really have this one callsite.

Alternatively, the migration could just be moved past the database rename, but then all existing installs would need to perform it again.

This migration fixes a data issue that can only occur if you ran specific versions of Paste from 2015. If any of those still exist, I can walk them through the repair the first time or two and update the migration if it's more common than I think.