You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@heron.apache.org by GitBox <gi...@apache.org> on 2018/08/29 21:37:25 UTC

[GitHub] julienledem commented on a change in pull request #3009: fix version detection to avoid matching on single dot

julienledem commented on a change in pull request #3009: fix version detection to avoid matching on single dot
URL: https://github.com/apache/incubator-heron/pull/3009#discussion_r213842850
 
 

 ##########
 File path: bazel_configure.py
 ##########
 @@ -149,7 +149,7 @@ def fail(message):
 
 # Assumes the version is at the end of the first line consisting of digits and dots
 def get_trailing_version(line):
-  version = re.search('([\d.]+)$', line)
+  version = re.search('([\d.]+\d)$', line)
 
 Review comment:
   ah right. maybe it doesn't fail when version is empty. This code needs to be hardened a little bit to verify what version matched is and whether it makes sense. Having a unit test with known version strings would help. Not sure why the version needs to be trailing. 

----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on GitHub and use the
URL above to go to the specific comment.
 
For queries about this service, please contact Infrastructure at:
users@infra.apache.org


With regards,
Apache Git Services