From patchwork Sat Nov 24 22:50:24 2012 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Doug Evans X-Patchwork-Id: 201483 Return-Path: X-Original-To: incoming@patchwork.ozlabs.org Delivered-To: patchwork-incoming@bilbo.ozlabs.org Received: from sourceware.org (server1.sourceware.org [209.132.180.131]) by ozlabs.org (Postfix) with SMTP id DB7E82C008D for ; Sun, 25 Nov 2012 09:50:35 +1100 (EST) Comment: DKIM? See http://www.dkim.org DKIM-Signature: v=1; a=rsa-sha1; c=relaxed/relaxed; d=gcc.gnu.org; s=default; x=1354402236; h=Comment: DomainKey-Signature:Received:Received:Received:Received:Received: Received:Received:Date:Message-Id:From:To:Subject:Mailing-List: Precedence:List-Id:List-Unsubscribe:List-Archive:List-Post: List-Help:Sender:Delivered-To; bh=JH+f4ZMHGn34biW6OnfxzvaHpmY=; b=egpyUyTKsOQmucY7ABgDZjQhsY7kqohusDjeAfebcYT4aJDOr48gjkIoWzEOXi 9TSOdOJnbLzTCdxBvTNZ0TbRUCHA5jDltOiMnfG+orjwQrE+fI9VUOrPcOdvq9So t9aRrkHDFN6+9EILKiGSEEWR90R4oZwnm5mXGwjA2TMM4= Comment: DomainKeys? See http://antispam.yahoo.com/domainkeys DomainKey-Signature: a=rsa-sha1; q=dns; c=nofws; s=default; d=gcc.gnu.org; h=Received:Received:X-SWARE-Spam-Status:X-Spam-Check-By:Received:Received:X-Google-DKIM-Signature:Received:Received:Received:Date:Message-Id:From:To:Subject:X-Gm-Message-State:X-IsSubscribed:Mailing-List:Precedence:List-Id:List-Unsubscribe:List-Archive:List-Post:List-Help:Sender:Delivered-To; b=fQ7UVSwh7725IcQDgLmjzc7E5qFRK7j4iZs2LNuIj8Ix1vfvcLjyL7PnG5nPsw MvuNu1rQPndlye1CcNkL7NkLVN4SO68TgZLhOU/i8hk+ArTfKpo2JAerrOHP9AOX GTpiR42reDly3myYot2KyMculnfq9JbETfE4+9LdhDuhc=; Received: (qmail 31473 invoked by alias); 24 Nov 2012 22:50:32 -0000 Received: (qmail 31465 invoked by uid 22791); 24 Nov 2012 22:50:30 -0000 X-SWARE-Spam-Status: No, hits=-4.4 required=5.0 tests=AWL, BAYES_00, DKIM_SIGNED, DKIM_VALID, DKIM_VALID_AU, KHOP_RCVD_TRUST, RCVD_IN_DNSWL_LOW, RCVD_IN_HOSTKARMA_YE, RP_MATCHES_RCVD X-Spam-Check-By: sourceware.org Received: from mail-gh0-f201.google.com (HELO mail-gh0-f201.google.com) (209.85.160.201) by sourceware.org (qpsmtpd/0.43rc1) with ESMTP; Sat, 24 Nov 2012 22:50:26 +0000 Received: by mail-gh0-f201.google.com with SMTP id z19so939735ghb.2 for ; Sat, 24 Nov 2012 14:50:25 -0800 (PST) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=20120113; h=date:message-id:from:to:subject:x-gm-message-state; bh=F4VHksKzpIGVGh5G8WFRXUDosteTV2ievCMfR2JZf6c=; b=ABacoWZKniXLUzE4oyFKZHHGluriL5HpJqDPDO8dptlDqHxnq9t9i/LSKdW7/+fgXw rCaU3zxA6vLjv+pVtWrv2oKz2qyU5aXesQNxw6ghE/I6/a2mcUkomJefXWT9Suupi6mw JNP7RVg3l8GW+LqUA6jZuaM5M+kDpfzq80wRd1J0GHLBjg7mocYSonTBq3WMu9R0wyAP Q2tEGeIHJabuF9hrGbShT6jzf+bkPmhytUYEMuKI4dZFm66fvmjWw8Li98hR25RoZaVi vL8AgvURWt1WE/BBxSEpHH8IXi9Lhueplk5vKU7Ggp0VnC260fbtxG0HP/AyAzNhzuV+ Pukw== Received: by 10.236.130.205 with SMTP id k53mr5320903yhi.38.1353797425786; Sat, 24 Nov 2012 14:50:25 -0800 (PST) Received: from wpzn3.hot.corp.google.com (216-239-44-65.google.com [216.239.44.65]) by gmr-mx.google.com with ESMTPS id i63si724640yhk.5.2012.11.24.14.50.25 (version=TLSv1/SSLv3 cipher=AES128-SHA); Sat, 24 Nov 2012 14:50:25 -0800 (PST) Received: from ruffy2.mtv.corp.google.com (ruffy2.mtv.corp.google.com [172.17.128.107]) by wpzn3.hot.corp.google.com (Postfix) with ESMTP id 3FBC7100047; Sat, 24 Nov 2012 14:50:25 -0800 (PST) Date: Sat, 24 Nov 2012 14:50:24 -0800 Message-Id: From: Doug Evans To: dnovillo@google.com, gcc-patches@gcc.gnu.org Subject: [RFA 4/8] validate_failures.py: rename --manifest to --manifest_path X-Gm-Message-State: ALoCoQnrmiybLo9lVKa8jbQg0LX3fZzTwW0LRO1P5stT9m4EwSmu+ax33mqnLSIP3lNChADBDi8l7Md9XW1LHCgI+f5V3yjDJih00XiAqSOW/ofpsxNXU0AjNOREQZOYAvBzVAf4PAstvBhDwNa/qY4+Ecyy9FJ65oB2MgvcrJZZW+0J3Akq4PlASD6/OKLMgMuVL0+5xkn0p4EqhnPxcN5mYbI/Yb3ysw== X-IsSubscribed: yes Mailing-List: contact gcc-patches-help@gcc.gnu.org; run by ezmlm Precedence: bulk List-Id: List-Unsubscribe: List-Archive: List-Post: List-Help: Sender: gcc-patches-owner@gcc.gnu.org Delivered-To: mailing list gcc-patches@gcc.gnu.org Hi. This fourth patch renames option --manifest to --manifest_path. I have a later patch that adds a --manifest_name option, making "--manifest" too confusing/ambiguous. Ok to check in? [I still have to update invocations that use --manifest, but that's a separate patch.] 2012-11-24 Doug Evans * testsuite-management/validate_failures.py: Rename option --manifest to --manifest_path. Rename local variables manifest_name to manifest_path. --- validate_failures.py= 2012-11-19 11:47:29.997632548 -0800 +++ validate_failures.py 2012-11-24 13:31:29.770809999 -0800 @@ -211,7 +211,7 @@ def ParseSummary(sum_fname): return result_set -def GetManifest(manifest_name): +def GetManifest(manifest_path): """Build a set of expected failures from the manifest file. Each entry in the manifest file should have the format understood @@ -220,8 +220,8 @@ def GetManifest(manifest_name): If no manifest file exists for this target, it returns an empty set. """ - if os.path.exists(manifest_name): - return ParseSummary(manifest_name) + if os.path.exists(manifest_path): + return ParseManifest(manifest_path) else: return set() @@ -326,14 +326,14 @@ def CheckExpectedResults(options): (srcdir, target, valid_build) = GetBuildData(options) if not valid_build: return False - manifest_name = _MANIFEST_PATH_PATTERN % (srcdir, target) + manifest_path = _MANIFEST_PATH_PATTERN % (srcdir, target) else: - manifest_name = options.manifest - if not os.path.exists(manifest_name): - Error('Manifest file %s does not exist.' % manifest_name) + manifest_path = options.manifest + if not os.path.exists(manifest_path): + Error('Manifest file %s does not exist.' % manifest_path) - print 'Manifest: %s' % manifest_name - manifest = GetManifest(manifest_name) + print 'Manifest: %s' % manifest_path + manifest = GetManifest(manifest_path) sum_files = GetSumFiles(options.results, options.build_dir) actual = GetResults(sum_files) @@ -349,14 +349,14 @@ def ProduceManifest(options): if not valid_build: return False - manifest_name = _MANIFEST_PATH_PATTERN % (srcdir, target) - if os.path.exists(manifest_name) and not options.force: + manifest_path = _MANIFEST_PATH_PATTERN % (srcdir, target) + if os.path.exists(manifest_path) and not options.force: Error('Manifest file %s already exists.\nUse --force to overwrite.' % - manifest_name) + manifest_path) sum_files = GetSumFiles(options.results, options.build_dir) actual = GetResults(sum_files) - manifest_file = open(manifest_name, 'w') + manifest_file = open(manifest_path, 'w') for result in sorted(actual): print result manifest_file.write('%s\n' % result) @@ -406,8 +406,8 @@ def Main(argv): 'that the expected failure has been fixed, or ' 'it did not run, or it may simply be flaky ' '(default = False)') - parser.add_option('--manifest', action='store', type='string', - dest='manifest', default=None, + parser.add_option('--manifest_path', action='store', type='string', + dest='manifest_path', default=None, help='Name of the manifest file to use (default = ' 'taken from contrib/testsuite-managment/.xfail)') parser.add_option('--produce_manifest', action='store_true',