Page MenuHomePhabricator

Extract PHIDs from transactions later, fixing Paste extraction/attachment
ClosedPublic

Authored by epriestley on Nov 16 2015, 6:22 PM.
Tags
None
Referenced Files
F15586435: D14494.diff
Thu, May 8, 5:45 PM
F15585442: D14494.id35078.diff
Thu, May 8, 9:00 AM
F15562348: D14494.id35078.diff
Wed, Apr 30, 1:53 AM
F15550565: D14494.id.diff
Sun, Apr 27, 12:19 PM
F15546142: D14494.diff
Sat, Apr 26, 2:04 PM
F15538464: D14494.id35065.diff
Thu, Apr 24, 7:28 PM
F15529461: D14494.id.diff
Tue, Apr 22, 8:05 PM
F15521557: D14494.id35065.diff
Sun, Apr 20, 3:17 PM
Subscribers
None

Details

Summary

Fixes T9787. Currently, file PHID extraction logic happens very early, before we normalize/merge/etc the transactions.

In D14390, I changed how the CONTENT transaction works: before, callers would pass in a file PHID. Afterward, they just pass in the content.

Passing in the content is generaly easier and feels more correct, but inadvertenly broke PHID extraction because converting the content into a file PHID now happened after we extracted the PHID. So we'd extract the entire text of the paste as a "file PHID", which wouldn't work.

Instead, extract file PHIDs later. This impacts a couple of other applications (Conpherence, Pholio) which receive an object or have an unusual file-oriented transaction.

Test Plan
  • Made a new paste, verified the raw file attached to it properly.
  • Made and updated a mock, verified all the files attached properly.
  • Updated a Conpherence room image, verified the files attached properly.

Diff Detail

Repository
rP Phabricator
Branch
eengine15
Lint
Lint Passed
Unit
Tests Passed
Build Status
Buildable 8875
Build 10383: Run Core Tests
Build 10382: arc lint + arc unit

Event Timeline

epriestley retitled this revision from to Extract PHIDs from transactions later, fixing Paste extraction/attachment.
epriestley updated this object.
epriestley edited the test plan for this revision. (Show Details)
epriestley added a reviewer: chad.
chad edited edge metadata.
This revision is now accepted and ready to land.Nov 17 2015, 5:17 AM
This revision was automatically updated to reflect the committed changes.