This is an automated email from the ASF dual-hosted git repository.

ggal pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/incubator-livy.git


The following commit(s) were added to refs/heads/master by this push:
     new 4c2549ac [LIVY-1025][TEST] Clean up Python2InterpreterSpec post Python 
deprecation
4c2549ac is described below

commit 4c2549ac92159f8e7ab886c9a836632ec5633281
Author: Arnav Balyan <[email protected]>
AuthorDate: Fri Dec 5 01:53:23 2025 +0530

    [LIVY-1025][TEST] Clean up Python2InterpreterSpec post Python deprecation
    
    ## What changes were proposed in this pull request?
    
     * Cleans up Python2InterpreterSpec since python 2 is deprecated.
     * Also removed the Python2SessionSpec counterpart
    
    ## How was this patch tested?
    
     * CI
---
 .../apache/livy/repl/PythonInterpreterSpec.scala   | 27 +---------------------
 .../org/apache/livy/repl/PythonSessionSpec.scala   |  2 --
 2 files changed, 1 insertion(+), 28 deletions(-)

diff --git 
a/repl/src/test/scala/org/apache/livy/repl/PythonInterpreterSpec.scala 
b/repl/src/test/scala/org/apache/livy/repl/PythonInterpreterSpec.scala
index e2d63e8c..dc8083f9 100644
--- a/repl/src/test/scala/org/apache/livy/repl/PythonInterpreterSpec.scala
+++ b/repl/src/test/scala/org/apache/livy/repl/PythonInterpreterSpec.scala
@@ -278,32 +278,7 @@ abstract class PythonBaseInterpreterSpec extends 
BaseInterpreterSpec {
   }
 }
 
-class Python2InterpreterSpec extends PythonBaseInterpreterSpec {
-
-  implicit val formats = DefaultFormats
-
-  override def createInterpreter(): Interpreter = {
-    val sparkConf = new SparkConf()
-    PythonInterpreter(sparkConf, new SparkEntries(sparkConf))
-  }
-
-  // Scalastyle is treating unicode escape as non ascii characters. Turn off 
the check.
-  // scalastyle:off non.ascii.character.disallowed
-  it should "print unicode correctly" in withInterpreter { intp =>
-    intp.execute("print(u\"\u263A\")") should equal(Interpreter.ExecuteSuccess(
-      TEXT_PLAIN -> "\u263A"
-    ))
-    intp.execute("""print(u"\u263A")""") should 
equal(Interpreter.ExecuteSuccess(
-      TEXT_PLAIN -> "\u263A"
-    ))
-    intp.execute("""print("\xE2\x98\xBA")""") should 
equal(Interpreter.ExecuteSuccess(
-      TEXT_PLAIN -> "\u263A"
-    ))
-  }
-  // scalastyle:on non.ascii.character.disallowed
-}
-
-class Python3InterpreterSpec extends PythonBaseInterpreterSpec with 
BeforeAndAfterAll {
+class PythonInterpreterSpec extends PythonBaseInterpreterSpec with 
BeforeAndAfterAll {
 
   implicit val formats = DefaultFormats
 
diff --git a/repl/src/test/scala/org/apache/livy/repl/PythonSessionSpec.scala 
b/repl/src/test/scala/org/apache/livy/repl/PythonSessionSpec.scala
index b54be11a..170d3c72 100644
--- a/repl/src/test/scala/org/apache/livy/repl/PythonSessionSpec.scala
+++ b/repl/src/test/scala/org/apache/livy/repl/PythonSessionSpec.scala
@@ -170,8 +170,6 @@ abstract class PythonSessionSpec extends 
BaseSessionSpec(PySpark) {
   }
 }
 
-class Python2SessionSpec extends PythonSessionSpec
-
 class Python3SessionSpec extends PythonSessionSpec with BeforeAndAfterAll {
 
   override protected def withFixture(test: NoArgTest): Outcome = {

Reply via email to