Page MenuHomePhabricator

Fix an issue where any diff which could possibly be rendered as Jupyter decided to render as Jupyter

Authored by epriestley on Oct 2 2019, 1:50 AM.



See PHI1468. Engine selection for diffs is currently too aggressive in trying to find a shared engine and will fall back a shared engine with a very low score, causing all ".json" files to render as Jupyter files.

Only pick an engine as a difference engine by default if it's the highest-scoring engine for the new file.

Test Plan

Viewed ".json" files and ".ipynb" files in a revision. Before, both rendered as Jupyter. Now, the former rendered as JSON and the latter rendered as Jupyter.

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.Oct 2 2019, 1:50 AM
This revision was not accepted when it landed; it landed in state Needs Review.Oct 2 2019, 1:52 AM
epriestley requested review of this revision.
This revision was automatically updated to reflect the committed changes.