Remove obsolete Python version check
authorPeter Eisentraut <[email protected]>
Tue, 25 Feb 2025 13:11:38 +0000 (14:11 +0100)
committerPeter Eisentraut <[email protected]>
Tue, 25 Feb 2025 13:11:38 +0000 (14:11 +0100)
The checked version is already the current minimum supported version
(3.2).

Discussion: https://www.postgresql.org/message-id/flat/ee410de1-1e0b-4770-b125-eeefd4726a24@eisentraut.org

src/pl/plpython/plpy_exec.c

index 0e84bb90829ec27c4323cb4a4d3b979713a65807..00747bb811b551a0f8354fd3629b71c5c4f82061 100644 (file)
@@ -1066,13 +1066,7 @@ PLy_procedure_call(PLyProcedure *proc, const char *kargs, PyObject *vargs)
 
    PG_TRY();
    {
-#if PY_VERSION_HEX >= 0x03020000
-       rv = PyEval_EvalCode(proc->code,
-                            proc->globals, proc->globals);
-#else
-       rv = PyEval_EvalCode((PyCodeObject *) proc->code,
-                            proc->globals, proc->globals);
-#endif
+       rv = PyEval_EvalCode(proc->code, proc->globals, proc->globals);
 
        /*
         * Since plpy will only let you close subtransactions that you