fapaul commented on code in PR #198:
URL: 
https://github.com/apache/flink-connector-kafka/pull/198#discussion_r2540965885


##########
flink-python/setup.py:
##########
@@ -81,7 +81,16 @@ def prepare_pyflink_dir():
     connector_version = pom_root.findall(
         
"./{http://maven.apache.org/POM/4.0.0}version";)[0].text.replace("-SNAPSHOT", 
".dev0")
 
-    flink_dependency = "apache-flink>=" + flink_version
+    # Pin to the minor version (e.g., >=1.19.1,<1.20.0) to allow patch updates
+    # but prevent major/minor version upgrades
+    version_parts = flink_version.split('.')
+    if len(version_parts) >= 2:
+        next_minor = str(int(version_parts[1]) + 1)
+        next_version = version_parts[0] + '.' + next_minor + '.0'
+        flink_dependency = "apache-flink>=" + flink_version + ",<" + 
next_version
+    else:
+        # Fallback to exact match if version format is unexpected

Review Comment:
   Let's add a print here to notify the user it's rather unexpected



-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]

Reply via email to