Page MenuHomePhabricator

When creating a File storage object for a Paste, try to give it the same name as the Paste

Authored by epriestley on Fri, May 1, 1:57 PM.



Ref T13528. Paste data is stored in files, but the files are always named "raw.txt".

Now that Paste provides a hint to use Files for "DocumentEngine" rendering, try to use the same name as the paste instead.

Test Plan
  • Created a paste named "staggering-insight.ipynb".
  • Clicked "View as Jupyter Notebook" from Paste.
  • Saw a file named "staggering-insight.ipynb", not "raw.txt".
  • Created a paste with no name, saw a file named "raw-paste-data.txt" get created.

Diff Detail

rP Phabricator
Automatic diff as part of commit; lint not applicable.
Automatic diff as part of commit; unit tests not applicable.

Event Timeline

epriestley created this revision.Fri, May 1, 1:57 PM
epriestley requested review of this revision.Fri, May 1, 1:58 PM
This revision was not accepted when it landed; it landed in state Needs Review.Fri, May 1, 4:10 PM
This revision was automatically updated to reflect the committed changes.