Gracefully handle invalid notes in legacy upload migration
If the database contains notes with invalid noteable values, the
background migration would fail repeatedly, causing duplicate "failed to
migrate" text to appear in LegacyDiffNotes
. To avoid this, we now bypass
validations when updating the note text. For LegacyDiffNotes
, we also
make the job idempotent so that the duplicate failed migration errors
cannot be added repeatedly.
Edited by Stan Hu