Return-Path: X-Original-To: archive-asf-public-internal@cust-asf2.ponee.io Delivered-To: archive-asf-public-internal@cust-asf2.ponee.io Received: from cust-asf.ponee.io (cust-asf.ponee.io [163.172.22.183]) by cust-asf2.ponee.io (Postfix) with ESMTP id DDFDB200BE3 for ; Wed, 7 Dec 2016 16:00:02 +0100 (CET) Received: by cust-asf.ponee.io (Postfix) id DCF37160B37; Wed, 7 Dec 2016 15:00:02 +0000 (UTC) Delivered-To: archive-asf-public@cust-asf.ponee.io Received: from mail.apache.org (hermes.apache.org [140.211.11.3]) by cust-asf.ponee.io (Postfix) with SMTP id E7158160B34 for ; Wed, 7 Dec 2016 16:00:01 +0100 (CET) Received: (qmail 10649 invoked by uid 500); 7 Dec 2016 15:00:00 -0000 Mailing-List: contact commits-help@ambari.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: ambari-dev@ambari.apache.org Delivered-To: mailing list commits@ambari.apache.org Received: (qmail 10011 invoked by uid 99); 7 Dec 2016 14:59:59 -0000 Received: from git1-us-west.apache.org (HELO git1-us-west.apache.org) (140.211.11.23) by apache.org (qpsmtpd/0.29) with ESMTP; Wed, 07 Dec 2016 14:59:59 +0000 Received: by git1-us-west.apache.org (ASF Mail Server at git1-us-west.apache.org, from userid 33) id 82A38F2151; Wed, 7 Dec 2016 14:59:59 +0000 (UTC) Content-Type: text/plain; charset="us-ascii" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit From: ncole@apache.org To: commits@ambari.apache.org Date: Wed, 07 Dec 2016 15:00:18 -0000 Message-Id: <7c833d805ab54ee6943617bfad81000b@git.apache.org> In-Reply-To: References: X-Mailer: ASF-Git Admin Mailer Subject: [20/50] [abbrv] ambari git commit: AMBARI-19039: In stack version, build number should not be mandatory (Amruta Borkar via dili) archived-at: Wed, 07 Dec 2016 15:00:03 -0000 AMBARI-19039: In stack version, build number should not be mandatory (Amruta Borkar via dili) Project: http://git-wip-us.apache.org/repos/asf/ambari/repo Commit: http://git-wip-us.apache.org/repos/asf/ambari/commit/b5122e25 Tree: http://git-wip-us.apache.org/repos/asf/ambari/tree/b5122e25 Diff: http://git-wip-us.apache.org/repos/asf/ambari/diff/b5122e25 Branch: refs/heads/branch-dev-patch-upgrade Commit: b5122e258bfe5a2e56511eb9dd29a70cf1260a9c Parents: 50ead4d Author: Di Li Authored: Mon Dec 5 16:03:50 2016 -0500 Committer: Di Li Committed: Mon Dec 5 16:03:50 2016 -0500 ---------------------------------------------------------------------- .../python/resource_management/libraries/functions/copy_tarball.py | 2 +- .../libraries/functions/dynamic_variable_interpretation.py | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) ---------------------------------------------------------------------- http://git-wip-us.apache.org/repos/asf/ambari/blob/b5122e25/ambari-common/src/main/python/resource_management/libraries/functions/copy_tarball.py ---------------------------------------------------------------------- diff --git a/ambari-common/src/main/python/resource_management/libraries/functions/copy_tarball.py b/ambari-common/src/main/python/resource_management/libraries/functions/copy_tarball.py index 519c88b..31a9be4 100644 --- a/ambari-common/src/main/python/resource_management/libraries/functions/copy_tarball.py +++ b/ambari-common/src/main/python/resource_management/libraries/functions/copy_tarball.py @@ -188,7 +188,7 @@ def _get_single_version_from_stack_select(): Logger.error("Could not verify stack version by calling '{0}'. Return Code: {1}, Output: {2}.".format(get_stack_versions_cmd, str(code), str(out))) return None - matches = re.findall(r"([\d\.]+\-\d+)", out) + matches = re.findall(r"([\d\.]+(?:-\d+)?)", out) if matches and len(matches) == 1: stack_version = matches[0] http://git-wip-us.apache.org/repos/asf/ambari/blob/b5122e25/ambari-common/src/main/python/resource_management/libraries/functions/dynamic_variable_interpretation.py ---------------------------------------------------------------------- diff --git a/ambari-common/src/main/python/resource_management/libraries/functions/dynamic_variable_interpretation.py b/ambari-common/src/main/python/resource_management/libraries/functions/dynamic_variable_interpretation.py index ca8fe19..74db04a 100644 --- a/ambari-common/src/main/python/resource_management/libraries/functions/dynamic_variable_interpretation.py +++ b/ambari-common/src/main/python/resource_management/libraries/functions/dynamic_variable_interpretation.py @@ -185,7 +185,7 @@ def copy_tarballs_to_hdfs(tarball_prefix, stack_select_component_name, component (get_stack_version_cmd, str(code), str(out))) return 1 - matches = re.findall(r"([\d\.]+\-\d+)", out) + matches = re.findall(r"([\d\.]+(?:-\d+)?)", out) stack_version = matches[0] if matches and len(matches) > 0 else None if not stack_version: