Resolve "Enable code highlighting for Jupyter Diffs"
What does this MR do and why?
Describe in detail what your merge request does and why.
With !71477 (merged) we added better diff experience for Jupyter Notebooks by transforming them into markdown first, but we were not highlighting the code.
NOTE: Since this is part of a larger feature (!71477 (merged)) we are not adding a changelog on this MR.
Screenshots or screen recordings
Before:
After:
How to set up and validate locally
-
Clone the repository:
https://gitlab.com/gitlab-org/incubation-engineering/mlops/ipynb-test-projects/diff-sample
into your local gdk installation -
Enable the feature locally only for the created project
Feature.enable(:jupyter_clean_diffs)
-
Open
http://gdk.test:3000/root/diff_test/-/commit/542d42a0196e2e94a0d5793acdee5ba997ab12bf
-
The diff should display as shown the after screenshot above
MR acceptance checklist
This checklist encourages us to confirm any changes have been analyzed to reduce risks in quality, performance, reliability, security, and maintainability.
-
I have evaluated the MR acceptance checklist for this MR.
Related to #344903 (closed)