From patchwork Sat Jul 4 18:25:48 2020 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Arun Isaac X-Patchwork-Id: 23045 Return-Path: X-Original-To: patchwork@mira.cbaines.net Delivered-To: patchwork@mira.cbaines.net Received: by mira.cbaines.net (Postfix, from userid 113) id 2B84827BBE1; Sat, 4 Jul 2020 19:27:10 +0100 (BST) X-Spam-Checker-Version: SpamAssassin 3.4.2 (2018-09-13) on mira.cbaines.net X-Spam-Level: X-Spam-Status: No, score=-2.8 required=5.0 tests=BAYES_00,DKIM_SIGNED, MAILING_LIST_MULTI,RCVD_IN_MSPIKE_H4,RCVD_IN_MSPIKE_WL,T_DKIM_INVALID, URIBL_BLOCKED autolearn=unavailable autolearn_force=no version=3.4.2 Received: from lists.gnu.org (lists.gnu.org [209.51.188.17]) by mira.cbaines.net (Postfix) with ESMTP id A046E27BBE3 for ; Sat, 4 Jul 2020 19:27:08 +0100 (BST) Received: from localhost ([::1]:54794 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1jrmsW-0002LZ-7V for patchwork@mira.cbaines.net; Sat, 04 Jul 2020 14:27:08 -0400 Received: from eggs.gnu.org ([2001:470:142:3::10]:39190) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1jrmsQ-0002LQ-CF for guix-patches@gnu.org; Sat, 04 Jul 2020 14:27:02 -0400 Received: from debbugs.gnu.org ([209.51.188.43]:48043) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1jrmsQ-00015T-3u for guix-patches@gnu.org; Sat, 04 Jul 2020 14:27:02 -0400 Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1jrmsQ-0004YW-1E for guix-patches@gnu.org; Sat, 04 Jul 2020 14:27:02 -0400 X-Loop: help-debbugs@gnu.org Subject: [bug#42192] [PATCH 0/3] Improve launchpad updater Resent-From: Arun Isaac Original-Sender: "Debbugs-submit" Resent-CC: guix-patches@gnu.org Resent-Date: Sat, 04 Jul 2020 18:27:01 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: report 42192 X-GNU-PR-Package: guix-patches X-GNU-PR-Keywords: patch To: 42192@debbugs.gnu.org Cc: Arun Isaac X-Debbugs-Original-To: guix-patches@gnu.org Received: via spool by submit@debbugs.gnu.org id=B.159388716717414 (code B ref -1); Sat, 04 Jul 2020 18:27:01 +0000 Received: (at submit) by debbugs.gnu.org; 4 Jul 2020 18:26:07 +0000 Received: from localhost ([127.0.0.1]:59578 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1jrmrX-0004Wo-2u for submit@debbugs.gnu.org; Sat, 04 Jul 2020 14:26:07 -0400 Received: from lists.gnu.org ([209.51.188.17]:52994) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1jrmrT-0004We-5O for submit@debbugs.gnu.org; Sat, 04 Jul 2020 14:26:04 -0400 Received: from eggs.gnu.org ([2001:470:142:3::10]:39074) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1jrmrS-00023g-4q for guix-patches@gnu.org; Sat, 04 Jul 2020 14:26:02 -0400 Received: from mugam.systemreboot.net ([139.59.75.54]:53970) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1jrmrO-000126-Pb for guix-patches@gnu.org; Sat, 04 Jul 2020 14:26:01 -0400 DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=systemreboot.net; s=default; h=Content-Transfer-Encoding:MIME-Version: Message-Id:Date:Subject:Cc:To:From:Sender:Reply-To:Content-Type:Content-ID: Content-Description:Resent-Date:Resent-From:Resent-Sender:Resent-To:Resent-Cc :Resent-Message-ID:In-Reply-To:References:List-Id:List-Help:List-Unsubscribe: List-Subscribe:List-Post:List-Owner:List-Archive; bh=c7pqnoUa+At0fMsb55JB8k7van84gyxyy+GdfrUxfrU=; b=eIFgCxbbUYUbCMa1WJUrhK41YK 2ufwtM1dNUlWdxpiw92tz+mYN22uEj9dyLnOuD12yQ1KGONuEyjMEg2eWSqYtURlbp61cKZXd7RMq wqTHf8Mbm259LGBic8PMLhA/9xaEsvFe2hTqscQ3X1WX7n6JQGVH+2kS9hLw60NLYJOE=; Received: from [192.168.2.1] (helo=localhost.localdomain) by systemreboot.net with esmtpsa (TLS1.3) tls TLS_AES_256_GCM_SHA384 (Exim 4.94) (envelope-from ) id 1jrmrG-0000GW-Uv; Sat, 04 Jul 2020 23:55:51 +0530 From: Arun Isaac Date: Sat, 4 Jul 2020 23:55:48 +0530 Message-Id: <20200704182548.25280-1-arunisaac@systemreboot.net> X-Mailer: git-send-email 2.26.2 MIME-Version: 1.0 Received-SPF: pass client-ip=139.59.75.54; envelope-from=arunisaac@systemreboot.net; helo=mugam.systemreboot.net X-detected-operating-system: by eggs.gnu.org: First seen = 2020/07/04 14:25:53 X-ACL-Warn: Detected OS = ??? X-Spam_score_int: -20 X-Spam_score: -2.1 X-Spam_bar: -- X-Spam_report: (-2.1 / 5.0 requ) BAYES_00=-1.9, DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, DKIM_VALID_EF=-0.1, SPF_HELO_NONE=0.001, SPF_PASS=-0.001, URIBL_BLOCKED=0.001 autolearn=_AUTOLEARN X-Spam_action: no action X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list X-BeenThere: guix-patches@gnu.org List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: guix-patches-bounces+patchwork=mira.cbaines.net@gnu.org Sender: "Guix-patches" X-getmail-retrieved-from-mailbox: Patches This patchset fixes a bug in the launchpad importer, and improves it to recognize more URLs and extensions. `guix refresh --list-updaters` reports an improvement in coverage from 0.1% to 0.2%. On a side note, all our updaters try to detect the URL format through a series of guesses. But, all our packages already encode information about how to construct the source URL from the version. If we could somehow tap into that information, our updaters would be much simpler. Unfortunately, all the uri fields of packages are strings. We would need them to be functions that take the version as an argument. This is a major conversion. Is it feasible? Any better ideas? Arun Isaac (3): import: launchpad: Handle list of source URLs correctly. import: launchpad: Recognize the .orig.tar.gz extension. import: launchpad: Recognize more URLs. guix/import/launchpad.scm | 38 +++++++++++++++++++++++++++++--------- 1 file changed, 29 insertions(+), 9 deletions(-)