ferenc-csaky commented on code in PR #23306:
URL: https://github.com/apache/flink/pull/23306#discussion_r1307401154


##########
flink-python/apache-flink-libraries/setup.py:
##########
@@ -98,8 +98,12 @@ def find_file_path(pattern):
                   file=sys.stderr)
             sys.exit(-1)
         flink_version = VERSION.replace(".dev0", "-SNAPSHOT")
-        FLINK_HOME = os.path.abspath(
-            "../../flink-dist/target/flink-%s-bin/flink-%s" % (flink_version, 
flink_version))
+        flink_homes = glob.glob('../../flink-dist/target/flink-*-bin/flink-*')
+        if len(flink_homes) != 1:
+            print("More than one Flink home directory found 
{0}".format(flink_homes),

Review Comment:
   Is it possible to get to this line if we did not package Flink yet? Even if 
not, I could end up cleaning up the dist target dir, so there is a possibility 
that `len(flink_homes)` will be `0` and in that case the "More than one..." 
error msg. is misleading. I think this can be rephrased in a more general way, 
maybe "Ambiguous Flink home directory found: ..." or something.



-- 
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