From patchwork Thu Sep 22 19:44:10 2022 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Greg Hogan X-Patchwork-Id: 42855 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 6D4D027BBEA; Thu, 22 Sep 2022 20:48:17 +0100 (BST) X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on mira.cbaines.net X-Spam-Level: X-Spam-Status: No, score=-2.7 required=5.0 tests=BAYES_00,DKIM_INVALID, DKIM_SIGNED,MAILING_LIST_MULTI,SPF_HELO_PASS,URIBL_BLOCKED autolearn=unavailable autolearn_force=no version=3.4.6 Received: from lists.gnu.org (lists.gnu.org [209.51.188.17]) by mira.cbaines.net (Postfix) with ESMTPS id E3F4B27BBE9 for ; Thu, 22 Sep 2022 20:48:16 +0100 (BST) Received: from localhost ([::1]:60082 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1obSBC-0004Yc-HG for patchwork@mira.cbaines.net; Thu, 22 Sep 2022 15:48:14 -0400 Received: from eggs.gnu.org ([2001:470:142:3::10]:54092) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1obS89-0002d8-G9 for guix-patches@gnu.org; Thu, 22 Sep 2022 15:45:05 -0400 Received: from debbugs.gnu.org ([209.51.188.43]:39568) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1obS88-0000eX-Fj for guix-patches@gnu.org; Thu, 22 Sep 2022 15:45:04 -0400 Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1obS88-00081L-AP for guix-patches@gnu.org; Thu, 22 Sep 2022 15:45:04 -0400 X-Loop: help-debbugs@gnu.org Subject: [bug#58012] [core-updates PATCH 7/7] gnu: python-louvain: Fix test. Resent-From: Greg Hogan Original-Sender: "Debbugs-submit" Resent-CC: guix-patches@gnu.org Resent-Date: Thu, 22 Sep 2022 19:45:04 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 58012 X-GNU-PR-Package: guix-patches X-GNU-PR-Keywords: patch To: 58012@debbugs.gnu.org Cc: Greg Hogan Received: via spool by 58012-submit@debbugs.gnu.org id=B58012.166387589130750 (code B ref 58012); Thu, 22 Sep 2022 19:45:04 +0000 Received: (at 58012) by debbugs.gnu.org; 22 Sep 2022 19:44:51 +0000 Received: from localhost ([127.0.0.1]:38640 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1obS7u-0007zp-RY for submit@debbugs.gnu.org; Thu, 22 Sep 2022 15:44:51 -0400 Received: from mail-qk1-f179.google.com ([209.85.222.179]:35607) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1obS7Y-0007yC-L6 for 58012@debbugs.gnu.org; Thu, 22 Sep 2022 15:44:29 -0400 Received: by mail-qk1-f179.google.com with SMTP id u28so6961238qku.2 for <58012@debbugs.gnu.org>; Thu, 22 Sep 2022 12:44:28 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=greghogan-com.20210112.gappssmtp.com; s=20210112; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:from:to:cc:subject:date; bh=KLlEZ1ckE4tHRApsqhGaeG5ptLfyoCHJii5oLVO6YPQ=; b=XXBmmAQulFSJ+XgvpXSZRT6Lu4F3IJz+xiEssvGQ5daarQtqjJJh+TPzmIjpZdOu7s qZsmP5X0iNZbHMVdwJs/f6Eifq6atQfAuQWe5uHI1H+gzz0O9F5Ja9J73cBuwrLojBV+ f2QQg7AkDq55pcSiTv16ImhUvODAF6mEGU7T6d7OXVo7CSWW4O6xTEuBnNLTnMsJ1Jkj xO31NOlLG+SlMOkHFY/CuhtbfixSxhA2IiTqt17sXtPgoeFMEZZE3AQhbrf+wEdAAKcn z2jHS21NR+vG5VSr9DwbXbIvz/xogVixzY5btfX0BCLELzMP+pZMG9cx5r002448H15o xY8A== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:x-gm-message-state:from:to:cc :subject:date; bh=KLlEZ1ckE4tHRApsqhGaeG5ptLfyoCHJii5oLVO6YPQ=; b=qks5nMQtmVPwQmi80NzwSf8POHs6mJRsWZHaYCxCmim7r+osn16S0t2CYkElnDLpSw 2Oiy8fuiqKs/hbLvJP7KLrPbhWrnCWLi54l7H7AVvDzpLMhxQZuhwd7deuuCb+Xu7pB+ rjq4zfyQ58WCyvTlCPnEhiM4PO0QTMkta4ZOExJbl82xOI8Ru999HRJCdhSug2ZYYSgz RfJ/kblL4WvkZFaBtffiavKvzZyW2MjcUZ2KUvJ4nrf+Ee3owDd752HEdlEiSX6fpKKv YMDX1m4DLEBEVcMVUhrhWCfLDjlF5+1W14qhNfLxK4/ZxSxyyKynop5Yhk+fqn4poY4w qO/w== X-Gm-Message-State: ACrzQf32Cege6qQ4/HFKcCIy9AbeDRI97kgfBR39KlYr1oSuk3dSSS6j 9umJy4gjWLPzrJidSJhtRjKQRXXngSLDYW45 X-Google-Smtp-Source: AMsMyM5rIlVAPfeXYtbK5OM9pmSp00VtxLOjaw0GP1d1i2BZy4cSNdb+60w+xUSHLuXAUzahWWRy5Q== X-Received: by 2002:a37:e116:0:b0:6cf:4dbd:18f1 with SMTP id c22-20020a37e116000000b006cf4dbd18f1mr3421928qkm.120.1663875862943; Thu, 22 Sep 2022 12:44:22 -0700 (PDT) Received: from ip-10-114-89-198.evoforge.org (ec2-52-70-167-183.compute-1.amazonaws.com. [52.70.167.183]) by smtp.gmail.com with ESMTPSA id d20-20020ae9ef14000000b006ce5fe31c2dsm4232105qkg.65.2022.09.22.12.44.21 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Thu, 22 Sep 2022 12:44:22 -0700 (PDT) From: Greg Hogan Date: Thu, 22 Sep 2022 19:44:10 +0000 Message-Id: <115f9b06a44f76669dcf9944235dab12ee130728.1663875245.git.code@greghogan.com> X-Mailer: git-send-email 2.37.3 In-Reply-To: References: MIME-Version: 1.0 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 * gnu/packages/graph.scm (python-louvain)[source]: Add patch. * gnu/packages/patches/python-louvain-fix-test.patch: New file. * gnu/local.mk (dist_patch_DATA): Register patch. --- gnu/local.mk | 1 + gnu/packages/graph.scm | 1 + .../patches/python-louvain-fix-test.patch | 15 +++++++++++++++ 3 files changed, 17 insertions(+) create mode 100644 gnu/packages/patches/python-louvain-fix-test.patch diff --git a/gnu/local.mk b/gnu/local.mk index ef1bae5f3c..11213b2197 100644 --- a/gnu/local.mk +++ b/gnu/local.mk @@ -1614,6 +1614,7 @@ dist_patch_DATA = \ %D%/packages/patches/ppsspp-disable-upgrade-and-gold.patch \ %D%/packages/patches/pthreadpool-system-libraries.patch \ %D%/packages/patches/python-chai-drop-python2.patch \ + %D%/packages/patches/python-louvain-fix-test.patch \ %D%/packages/patches/python-random2-getrandbits-test.patch \ %D%/packages/patches/python-poppler-qt5-fix-build.patch \ %D%/packages/patches/python-w3lib-fix-test-failure.patch \ diff --git a/gnu/packages/graph.scm b/gnu/packages/graph.scm index 109ba68675..02c80f0682 100644 --- a/gnu/packages/graph.scm +++ b/gnu/packages/graph.scm @@ -290,6 +290,7 @@ (define-public python-louvain (origin (method url-fetch) (uri (pypi-uri "python-louvain" version)) + (patches (search-patches "python-louvain-fix-test.patch")) (sha256 (base32 "0sx53l555rwq0z7if8agirjgw4ddp8r9b949wwz8vlig03sjvfmp")))) (build-system python-build-system) diff --git a/gnu/packages/patches/python-louvain-fix-test.patch b/gnu/packages/patches/python-louvain-fix-test.patch new file mode 100644 index 0000000000..2127df681c --- /dev/null +++ b/gnu/packages/patches/python-louvain-fix-test.patch @@ -0,0 +1,15 @@ +https://github.com/taynaud/python-louvain/commit/638804ae636dc65306900ef6518ca0a1c9202566.diff + +diff --git a/test_community.py b/test_community.py +index 1ee1976..566a4b1 100644 +--- a/test_community.py ++++ b/test_community.py +@@ -203,7 +203,7 @@ def test_karate(self): + self.assertAlmostEqual(co.modularity(part, graph), + co.modularity(part_weight, + graph, +- "test_weight"), places=2) ++ "test_weight"), places=1) + + part_res_low = co.best_partition(graph, resolution=0.1) + self.assertTrue(