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

jrmccluskey pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/beam.git


The following commit(s) were added to refs/heads/master by this push:
     new 3105260ce58 Warn when using Beam with Python 3.8 (#32484)
3105260ce58 is described below

commit 3105260ce5803783f8ef18b6d3ae87c065e6f8e4
Author: Jack McCluskey <[email protected]>
AuthorDate: Wed Sep 18 09:54:39 2024 -0400

    Warn when using Beam with Python 3.8 (#32484)
    
    * Warn when using Beam with Python 3.8
    
    * Call out in CHANGES.md
    
    * formatting
---
 CHANGES.md                          | 2 ++
 sdks/python/apache_beam/__init__.py | 6 ++++++
 sdks/python/setup.py                | 5 +++++
 3 files changed, 13 insertions(+)

diff --git a/CHANGES.md b/CHANGES.md
index b936ba6dda3..d58ceffeb41 100644
--- a/CHANGES.md
+++ b/CHANGES.md
@@ -82,6 +82,8 @@
 ## Deprecations
 
 * X behavior is deprecated and will be removed in X versions 
([#X](https://github.com/apache/beam/issues/X)).
+* Python 3.8 is reaching EOL and support is being removed in Beam 2.61.0. The 
2.60.0 release will warn users
+when running on 3.8. ([#31192](https://github.com/apache/beam/issues/31192))
 
 ## Bugfixes
 
diff --git a/sdks/python/apache_beam/__init__.py 
b/sdks/python/apache_beam/__init__.py
index 27c2b293fbd..6e08083bc0d 100644
--- a/sdks/python/apache_beam/__init__.py
+++ b/sdks/python/apache_beam/__init__.py
@@ -75,6 +75,12 @@ if sys.version_info.major == 3:
         'This version of Apache Beam has not been sufficiently tested on '
         'Python %s.%s. You may encounter bugs or missing features.' %
         (sys.version_info.major, sys.version_info.minor))
+  elif sys.version_info.minor == 8:
+    warnings.warn(
+        'Python 3.8 reaches EOL in October 2024 and support will '
+        'be removed from Apache Beam in version 2.61.0. See '
+        'https://github.com/apache/beam/issues/31192 for more '
+        'information.')
   pass
 else:
   raise RuntimeError(
diff --git a/sdks/python/setup.py b/sdks/python/setup.py
index 21669416890..ddd7bfea52c 100644
--- a/sdks/python/setup.py
+++ b/sdks/python/setup.py
@@ -278,6 +278,11 @@ if sys.version_info.major == 3 and sys.version_info.minor 
>= 12:
       'This version of Apache Beam has not been sufficiently tested on '
       'Python %s.%s. You may encounter bugs or missing features.' %
       (sys.version_info.major, sys.version_info.minor))
+elif sys.version_info.major == 3 and sys.version_info.minor == 8:
+  warnings.warn('Python 3.8 reaches EOL in October 2024 and support will '
+                'be removed from Apache Beam in version 2.61.0. See '
+                'https://github.com/apache/beam/issues/31192 for more '
+                'information.')
 
 if __name__ == '__main__':
   # In order to find the tree of proto packages, the directory

Reply via email to