Script 'mail_helper' called by obssrc
Hello community,

here is the log from the commit of package SHERPA-MC for openSUSE:Factory 
checked in at 2026-11-17 17:20:45
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Comparing /work/SRC/openSUSE:Factory/SHERPA-MC (Old)
 and      /work/SRC/openSUSE:Factory/.SHERPA-MC.new.1251 (New)
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++

Package is "SHERPA-MC"

Tue Nov 17 17:20:45 2026 rev:24 rq:1398102 version:2.2.16

Changes:
--------
--- /work/SRC/openSUSE:Factory/SHERPA-MC/SHERPA-MC.changes      2025-11-24 
14:13:37.056447182 +0100
+++ /work/SRC/openSUSE:Factory/.SHERPA-MC.new.1251/SHERPA-MC.changes    
2026-11-17 17:23:31.621539937 +0100
@@ -1,0 +2,11 @@
+Tue Nov 17 08:34:29 UTC 2026 - Ana Guerrero <[email protected]>
+
+- Update Source URL
+
+-------------------------------------------------------------------
+Mon Nov 16 14:55:00 UTC 2026 - Dominique Leuenberger <[email protected]>
+
+- Add SHERPA-MC-swig-py3.patch: replace obsolete Python 2 calls
+  (PyString_*, PyInt_*) with Python 3 C API in AddOns/Python/*.i.
+
+-------------------------------------------------------------------

New:
----
  SHERPA-MC-swig-py3.patch

----------(New B)----------
  New:
- Add SHERPA-MC-swig-py3.patch: replace obsolete Python 2 calls
  (PyString_*, PyInt_*) with Python 3 C API in AddOns/Python/*.i.
----------(New E)----------

++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++

Other differences:
------------------
++++++ SHERPA-MC.spec ++++++
--- /var/tmp/diff_new_pack.vqYN8y/_old  2026-11-17 17:23:32.684585193 +0100
+++ /var/tmp/diff_new_pack.vqYN8y/_new  2026-11-17 17:23:32.688585363 +0100
@@ -1,7 +1,7 @@
 #
 # spec file for package SHERPA-MC
 #
-# Copyright (c) 2025 SUSE LLC and contributors
+# Copyright (c) 2026 SUSE LLC and contributors
 #
 # All modifications and additions to the file contributed by third parties
 # remain the property of their copyright owners, unless otherwise agreed
@@ -27,13 +27,15 @@
 Group:          Development/Libraries/C and C++
 URL:            https://sherpa-team.gitlab.io/
 #Git-Clone:     https://gitlab.com/sherpa-team/sherpa.git
-Source:         
https://www.hepforge.org/downloads/sherpa/%{name}-%{version}.tar.gz
+Source:         https://sherpa.hepforge.org/downloads/%{name}-%{version}.tar.gz
 # PATCH-FIX-UPSTREAM SHERPA-MC-no-return-in-non-void-function.patch 
[email protected] -- Fix a non-void (bool) function that was not returning 
any data to return "true"
 Patch0:         SHERPA-MC-no-return-in-non-void-function.patch
 # PATCH-FIX-UPSTREAM SHERPA-MC-swig-noruntime.patch [email protected] -- 
Drop `-noruntime` from swig command line
 Patch2:         SHERPA-MC-swig-noruntime.patch
 # PATCH-FIX-OPENSUSE SHERPA-MC-fix-rivet-libs-check.patch [email protected] 
-- Fix configure check for rivet >= 4.0
 Patch3:         SHERPA-MC-fix-rivet-libs-check.patch
+# PATCH-FIX-UPSTREAM SHERPA-MC-swig-py3.patch -- replace obsolete PyString_* 
and PyInt_* with Python 3 C API in SWIG interfaces
+Patch4:         SHERPA-MC-swig-py3.patch
 BuildRequires:  HepMC-devel >= 3.0
 BuildRequires:  LHAPDF-devel
 BuildRequires:  fastjet-contrib-devel

++++++ SHERPA-MC-swig-py3.patch ++++++
--- a/AddOns/Python/MEProcess.i 2026-11-16 15:54:23.680705582 +0100
+++ b/AddOns/Python/MEProcess.i 2026-11-16 15:54:23.705340798 +0100
@@ -66,7 +66,7 @@
                                            
PyFloat_AsDouble(PySequence_GetItem(momentum,3)) ));
          $self->SetMomenta(vec4_vec);
        }
-      return PyInt_FromLong(1);
+      return PyLong_FromLong(1);
     };
   }
 
--- a/AddOns/Python/Exception.i 2026-11-16 15:54:23.684070087 +0100
+++ b/AddOns/Python/Exception.i 2026-11-16 15:54:23.705477526 +0100
@@ -89,7 +89,7 @@
       PyObject* __str__() {
        MyStrStream conv;
        conv<<*self;
-       return PyString_FromString(conv.str().c_str());
+       return PyUnicode_FromString(conv.str().c_str());
       };
     };
 
--- a/AddOns/Python/Sherpa.i    2026-11-16 15:54:23.685940662 +0100
+++ b/AddOns/Python/Sherpa.i    2026-11-16 15:54:23.705602191 +0100
@@ -25,8 +25,8 @@
     $1 = (char **) malloc((size+1)*sizeof(char *));
     for (i = 0; i < size; i++) {
       PyObject *o = PyList_GetItem($input,i);
-      if (PyString_Check(o))
-       $1[i] = PyString_AsString(PyList_GetItem($input,i));
+      if (PyUnicode_Check(o))
+       $1[i] = (char *) PyUnicode_AsUTF8(PyList_GetItem($input,i));
       else {
        PyErr_SetString(PyExc_TypeError,"Sherpa execution argument list must 
contain strings");
        free($1);

Reply via email to