Script 'mail_helper' called by obssrc
Hello community,

here is the log from the commit of package python-google-api-core for 
openSUSE:Factory checked in at 2026-04-13 23:19:50
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Comparing /work/SRC/openSUSE:Factory/python-google-api-core (Old)
 and      /work/SRC/openSUSE:Factory/.python-google-api-core.new.21863 (New)
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++

Package is "python-google-api-core"

Mon Apr 13 23:19:50 2026 rev:48 rq:1346446 version:2.30.3

Changes:
--------
--- 
/work/SRC/openSUSE:Factory/python-google-api-core/python-google-api-core.changes
    2026-04-07 16:51:05.205947965 +0200
+++ 
/work/SRC/openSUSE:Factory/.python-google-api-core.new.21863/python-google-api-core.changes
 2026-04-13 23:22:16.964532891 +0200
@@ -1,0 +2,7 @@
+Mon Apr 13 11:28:49 UTC 2026 - John Paul Adrian Glaubitz 
<[email protected]>
+
+- Update to 2.30.3
+  * Avoid repeated scan of entire venv via packages_distributions()
+    at import time (#16579)
+
+-------------------------------------------------------------------

Old:
----
  google_api_core-2.30.2.tar.gz

New:
----
  google_api_core-2.30.3.tar.gz

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

Other differences:
------------------
++++++ python-google-api-core.spec ++++++
--- /var/tmp/diff_new_pack.7GkNlJ/_old  2026-04-13 23:22:17.508555336 +0200
+++ /var/tmp/diff_new_pack.7GkNlJ/_new  2026-04-13 23:22:17.508555336 +0200
@@ -26,7 +26,7 @@
 %endif
 %{?sle15_python_module_pythons}
 Name:           python-google-api-core
-Version:        2.30.2
+Version:        2.30.3
 Release:        0
 Summary:        Google API client core library
 License:        Apache-2.0

++++++ google_api_core-2.30.2.tar.gz -> google_api_core-2.30.3.tar.gz ++++++
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/google_api_core-2.30.2/PKG-INFO 
new/google_api_core-2.30.3/PKG-INFO
--- old/google_api_core-2.30.2/PKG-INFO 2026-04-02 23:16:37.215727300 +0200
+++ new/google_api_core-2.30.3/PKG-INFO 2026-04-10 02:34:46.223877000 +0200
@@ -1,6 +1,6 @@
 Metadata-Version: 2.4
 Name: google-api-core
-Version: 2.30.2
+Version: 2.30.3
 Summary: Google API client core library
 Author-email: Google LLC <[email protected]>
 License: Apache 2.0
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' 
old/google_api_core-2.30.2/google/api_core/_python_version_support.py 
new/google_api_core-2.30.3/google/api_core/_python_version_support.py
--- old/google_api_core-2.30.2/google/api_core/_python_version_support.py       
2026-04-02 23:14:54.000000000 +0200
+++ new/google_api_core-2.30.3/google/api_core/_python_version_support.py       
2026-04-10 02:34:10.000000000 +0200
@@ -16,6 +16,7 @@
 
 import datetime
 import enum
+import functools
 import logging
 import warnings
 import sys
@@ -152,15 +153,16 @@
 else:
     from importlib import metadata
 
+    @functools.cache
+    def _cached_packages_distributions():
+        return metadata.packages_distributions()
+
     def _get_pypi_package_name(module_name):
         """Determine the PyPI package name for a given module name."""
         try:
-            # Get the mapping of modules to distributions
-            module_to_distributions = metadata.packages_distributions()
+            module_to_distributions = _cached_packages_distributions()
 
-            # Check if the module is found in the mapping
             if module_name in module_to_distributions:  # pragma: NO COVER
-                # The value is a list of distribution names, take the first one
                 return module_to_distributions[module_name][0]
         except Exception as e:  # pragma: NO COVER
             _LOGGER.info(
@@ -195,7 +197,6 @@
         The support status of the current Python version.
     """
     today = today or datetime.date.today()
-    package_label, _ = _get_distribution_and_import_packages(package)
 
     python_version = sys.version_info
     version_tuple = (python_version.major, python_version.minor)
@@ -221,7 +222,14 @@
                 return f"{version[0]}.{version[1]}"
         return "at a currently supported version 
[https://devguide.python.org/versions]";
 
+    # Resolve the pretty package label lazily so we avoid any work on
+    # the happy path (supported Python version, no warning needed).
+    def get_package_label():
+        label, _ = _get_distribution_and_import_packages(package)
+        return label
+
     if gapic_end < today:
+        package_label = get_package_label()
         message = _flatten_message(
             f"""
             You are using a non-supported Python version ({py_version_str}).
@@ -236,6 +244,7 @@
 
     eol_date = version_info.python_eol + EOL_GRACE_PERIOD
     if eol_date <= today <= gapic_end:
+        package_label = get_package_label()
         message = _flatten_message(
             f"""
             You are using a Python version ({py_version_str})
@@ -250,6 +259,7 @@
         return PythonVersionStatus.PYTHON_VERSION_EOL
 
     if gapic_deprecation <= today <= gapic_end:
+        package_label = get_package_label()
         message = _flatten_message(
             f"""
             You are using a Python version ({py_version_str}) which Google will
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/google_api_core-2.30.2/google/api_core/version.py 
new/google_api_core-2.30.3/google/api_core/version.py
--- old/google_api_core-2.30.2/google/api_core/version.py       2026-04-02 
23:14:55.000000000 +0200
+++ new/google_api_core-2.30.3/google/api_core/version.py       2026-04-10 
02:34:10.000000000 +0200
@@ -12,4 +12,4 @@
 # See the License for the specific language governing permissions and
 # limitations under the License.
 
-__version__ = "2.30.2"
+__version__ = "2.30.3"
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' 
old/google_api_core-2.30.2/google_api_core.egg-info/PKG-INFO 
new/google_api_core-2.30.3/google_api_core.egg-info/PKG-INFO
--- old/google_api_core-2.30.2/google_api_core.egg-info/PKG-INFO        
2026-04-02 23:16:37.000000000 +0200
+++ new/google_api_core-2.30.3/google_api_core.egg-info/PKG-INFO        
2026-04-10 02:34:46.000000000 +0200
@@ -1,6 +1,6 @@
 Metadata-Version: 2.4
 Name: google-api-core
-Version: 2.30.2
+Version: 2.30.3
 Summary: Google API client core library
 Author-email: Google LLC <[email protected]>
 License: Apache 2.0

Reply via email to