HyukjinKwon commented on code in PR #42196:
URL: https://github.com/apache/spark/pull/42196#discussion_r1277112777
##########
python/pyspark/testing/utils.py:
##########
@@ -189,6 +190,39 @@ def search_jar(project_relative_path, sbt_jar_name_prefix,
mvn_jar_name_prefix):
return jars[0]
+def _context_diff(actual: List[str], expected: List[str], n: int = 3):
+ """
+ Modified from difflib context_diff API,
+ see original code here:
https://github.com/python/cpython/blob/main/Lib/difflib.py#L1180
+ """
+ def red(s: str) -> str:
Review Comment:
I think we'll need a configuration to disable the colors. In some terminals,
they do not work, and looks weird characters. One reference is `sbt -no-colors`
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: [email protected]
For queries about this service, please contact Infrastructure at:
[email protected]
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]