Script 'mail_helper' called by obssrc
Hello community,

here is the log from the commit of package python-mistralai for 
openSUSE:Factory checked in at 2026-07-08 17:35:46
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Comparing /work/SRC/openSUSE:Factory/python-mistralai (Old)
 and      /work/SRC/openSUSE:Factory/.python-mistralai.new.1982 (New)
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++

Package is "python-mistralai"

Wed Jul  8 17:35:46 2026 rev:7 rq:1364155 version:2.5.0

Changes:
--------
--- /work/SRC/openSUSE:Factory/python-mistralai/python-mistralai.changes        
2026-05-05 17:59:12.577298874 +0200
+++ 
/work/SRC/openSUSE:Factory/.python-mistralai.new.1982/python-mistralai.changes  
    2026-07-08 17:37:55.080363029 +0200
@@ -1,0 +2,13 @@
+Tue Jun 30 09:57:18 UTC 2026 - Matej Cepl <[email protected]>
+
+- Update to 2.5.0:
+  https://github.com/mistralai/client-python/releases
+- Add python-msgpack BuildRequires for test suite.
+- Ignore test_otel_tracing.py as
+  python-opentelemetry-instrumentation-httpx is not available.
+- Add correct-traceparent-hook.patch to fix failure in
+  TestTraceparentInjectionHook.test_propagates_sampled_active_span
+  with newer opentelemetry-sdk where trace_flags has more than the lowest
+  bit set (0x03).
+
+-------------------------------------------------------------------

Old:
----
  mistralai-2.4.4.tar.gz

New:
----
  correct-traceparent-hook.patch
  mistralai-2.5.0.tar.gz

----------(New B)----------
  New:  python-opentelemetry-instrumentation-httpx is not available.
- Add correct-traceparent-hook.patch to fix failure in
  TestTraceparentInjectionHook.test_propagates_sampled_active_span
----------(New E)----------

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

Other differences:
------------------
++++++ python-mistralai.spec ++++++
--- /var/tmp/diff_new_pack.1guVlX/_old  2026-07-08 17:37:56.620416702 +0200
+++ /var/tmp/diff_new_pack.1guVlX/_new  2026-07-08 17:37:56.624416842 +0200
@@ -17,13 +17,14 @@
 
 
 Name:           python-mistralai
-Version:        2.4.4
+Version:        2.5.0
 Release:        0
 Summary:        Python Client SDK for the Mistral AI API
 License:        Apache-2.0
 URL:            https://github.com/mistralai/client-python
 Source0:        
https://files.pythonhosted.org/packages/source/m/mistralai/mistralai-%{version}.tar.gz
 Source99:       python-mistralai.rpmlintrc
+Patch0:         correct-traceparent-hook.patch
 BuildRequires:  %{python_module hatchling}
 BuildRequires:  %{python_module pip}
 BuildRequires:  fdupes
@@ -60,6 +61,9 @@
 BuildRequires:  %{python_module opentelemetry-semantic-conventions >= 0.60b1}
 BuildRequires:  %{python_module pydantic >= 2.11.2}
 BuildRequires:  %{python_module pytest}
+BuildRequires:  %{python_module pytest-asyncio}
+BuildRequires:  %{python_module zstandard}
+BuildRequires:  %{python_module msgpack >= 1.1.0}
 BuildRequires:  %{python_module python-dateutil >= 2.8.2}
 BuildRequires:  %{python_module typing-inspection >= 0.4.0}
 # /SECTION
@@ -90,6 +94,7 @@
 # test_create_function_result_*_span and 
test_concurrent_async_requests_get_correct_spans
 # tests use asyncio.get_event_loop() which raises RuntimeError on Python 3.14
 # where an implicit event loop is no longer created automatically (upstream 
bug).
+export PYTEST_ADDOPTS="--ignore=src/mistralai/extra/tests/test_otel_tracing.py"
 %pytest -k "not (test_create_function_result_error_span or 
test_create_function_result_span_attributes or 
test_concurrent_async_requests_get_correct_spans)"
 
 %files %{python_files}

++++++ _scmsync.obsinfo ++++++
--- /var/tmp/diff_new_pack.1guVlX/_old  2026-07-08 17:37:56.668418375 +0200
+++ /var/tmp/diff_new_pack.1guVlX/_new  2026-07-08 17:37:56.672418514 +0200
@@ -1,5 +1,5 @@
-mtime: 1777985651
-commit: 0578a78ef4b60a39b31b380804670ab45e1e4344cf6de5c3eac551e08ab2f3fe
+mtime: 1782822093
+commit: 5e7fc3c4ddd93fedd92550776e1ac496da612711e243f9ffaba5e59d535ec98d
 url: https://src.opensuse.org/AI/python-mistralai.git
 revision: factory
 

++++++ build.specials.obscpio ++++++
--- old/.gitignore      2026-05-05 14:54:11.000000000 +0200
+++ new/.gitignore      2026-06-30 14:21:33.000000000 +0200
@@ -3,3 +3,4 @@
 _build.*
 _service:*
 .pbuild
+python-mistralai-*-build/

++++++ build.specials.obscpio ++++++
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/.gitignore new/.gitignore
--- old/.gitignore      1970-01-01 01:00:00.000000000 +0100
+++ new/.gitignore      2026-06-30 14:21:33.000000000 +0200
@@ -0,0 +1,6 @@
+*.obscpio
+*.osc
+_build.*
+_service:*
+.pbuild
+python-mistralai-*-build/

++++++ correct-traceparent-hook.patch ++++++
Index: mistralai-2.5.0/src/mistralai/client/_hooks/traceparent.py
===================================================================
--- mistralai-2.5.0.orig/src/mistralai/client/_hooks/traceparent.py
+++ mistralai-2.5.0/src/mistralai/client/_hooks/traceparent.py
@@ -23,7 +23,18 @@ class TraceparentInjectionHook(BeforeReq
         carrier: Dict[str, str] = {}
         inject(carrier)
         traceparent = carrier.get("traceparent", "")
-        if not traceparent.endswith("-01"):
+        is_sampled = False
+        if traceparent:
+            parts = traceparent.split("-")
+            if len(parts) == 4 and parts[0] == "00":
+                try:
+                    flags = int(parts[3], 16)
+                    if flags & 0x01:
+                        is_sampled = True
+                except ValueError:
+                    pass
+
+        if not is_sampled:
             trace_id = random.getrandbits(128)
             span_id = random.getrandbits(64)
             traceparent = f"00-{trace_id:032x}-{span_id:016x}-01"
Index: mistralai-2.5.0/src/mistralai/extra/tests/test_traceparent_hook.py
===================================================================
--- mistralai-2.5.0.orig/src/mistralai/extra/tests/test_traceparent_hook.py
+++ mistralai-2.5.0/src/mistralai/extra/tests/test_traceparent_hook.py
@@ -85,7 +85,8 @@ class TestTraceparentInjectionHook(unitt
 
         assert isinstance(result, httpx.Request)
         injected = result.headers["traceparent"]
-        self.assertTrue(injected.endswith("-01"))
+        expected_suffix = f"-{span.get_span_context().trace_flags:02x}"
+        self.assertTrue(injected.endswith(expected_suffix))
         trace_id_hex = f"{span.get_span_context().trace_id:032x}"
         self.assertIn(trace_id_hex, injected)
 

++++++ mistralai-2.4.4.tar.gz -> mistralai-2.5.0.tar.gz ++++++
++++ 44938 lines of diff (skipped)

Reply via email to