From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mp0 ([2001:41d0:2:4a6f::]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)) by ms11 with LMTPS id wEdsOztM4l6fNgAA0tVLHw (envelope-from ) for ; Thu, 11 Jun 2020 15:22:35 +0000 Received: from aspmx1.migadu.com ([2001:41d0:2:4a6f::]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)) by mp0 with LMTPS id oJZVNztM4l7WbgAA1q6Kng (envelope-from ) for ; Thu, 11 Jun 2020 15:22:35 +0000 Received: from lists.gnu.org (lists.gnu.org [209.51.188.17]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by aspmx1.migadu.com (Postfix) with ESMTPS id A6ACE94066B for ; Thu, 11 Jun 2020 15:22:35 +0000 (UTC) Received: from localhost ([::1]:38868 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1jjP2I-0006Sw-AB for larch@yhetil.org; Thu, 11 Jun 2020 11:22:34 -0400 Received: from eggs.gnu.org ([2001:470:142:3::10]:52278) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1jjOv1-00071T-GP for guix-patches@gnu.org; Thu, 11 Jun 2020 11:15:03 -0400 Received: from debbugs.gnu.org ([209.51.188.43]:54449) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1jjOv1-00048C-3V for guix-patches@gnu.org; Thu, 11 Jun 2020 11:15:03 -0400 Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1jjOv0-0005JN-Uw for guix-patches@gnu.org; Thu, 11 Jun 2020 11:15:02 -0400 X-Loop: help-debbugs@gnu.org Subject: [bug#41807] [PATCH 02/26] gnu: Add python-immutables. Resent-From: Giacomo Leidi Original-Sender: "Debbugs-submit" Resent-CC: guix-patches@gnu.org Resent-Date: Thu, 11 Jun 2020 15:15:02 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 41807 X-GNU-PR-Package: guix-patches X-GNU-PR-Keywords: patch To: 41807@debbugs.gnu.org Cc: Giacomo Leidi Received: via spool by 41807-submit@debbugs.gnu.org id=B41807.159188845720065 (code B ref 41807); Thu, 11 Jun 2020 15:15:02 +0000 Received: (at 41807) by debbugs.gnu.org; 11 Jun 2020 15:14:17 +0000 Received: from localhost ([127.0.0.1]:37694 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1jjOuG-0005DF-If for submit@debbugs.gnu.org; Thu, 11 Jun 2020 11:14:17 -0400 Received: from latitanza.investici.org ([82.94.249.234]:21991) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1jjOuE-0005Cc-QB for 41807@debbugs.gnu.org; Thu, 11 Jun 2020 11:14:15 -0400 Received: from mx3.investici.org (unknown [127.0.0.1]) by latitanza.investici.org (Postfix) with ESMTP id 92C3C120178; Thu, 11 Jun 2020 15:14:13 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=autistici.org; s=stigmate; t=1591888453; bh=2eFDLjd9Tr/2uqn613Bz+6hsZt3e5rCd0CBqjXdVqVY=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=pyfPxQP37S0nir6W79ddgnWsLBxM24dsWDBx9h5AMF5sLpdym6HFmWNniiuEPDmWl k6aYSAlv4mO4ZBvQJn0c95OCK6vPKmXHLV6BjPeXEN/hf7hoASd/pzn7JAUIP++xbU LBmD1uyjYd2vmlttiTR0Ehr9MjmFIdU3XZJbroWo= Received: from [82.94.249.234] (mx3.investici.org [82.94.249.234]) (Authenticated sender: goodoldpaul@autistici.org) by localhost (Postfix) with ESMTPSA id 610AA12015C; Thu, 11 Jun 2020 15:14:13 +0000 (UTC) From: Giacomo Leidi Date: Thu, 11 Jun 2020 17:13:33 +0200 Message-Id: <20200611151357.18843-2-goodoldpaul@autistici.org> X-Mailer: git-send-email 2.26.2 In-Reply-To: <20200611151357.18843-1-goodoldpaul@autistici.org> References: <20200611151357.18843-1-goodoldpaul@autistici.org> MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Spam-Score: -0.0 (/) X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list X-Spam-Score: -1.0 (-) X-BeenThere: guix-patches@gnu.org List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: guix-patches-bounces+larch=yhetil.org@gnu.org Sender: "Guix-patches" X-Scanner: scn0 Authentication-Results: aspmx1.migadu.com; dkim=fail (rsa verify failed) header.d=autistici.org header.s=stigmate header.b=pyfPxQP3; dmarc=none; spf=pass (aspmx1.migadu.com: domain of guix-patches-bounces@gnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom=guix-patches-bounces@gnu.org X-Spam-Score: 4.99 X-TUID: rYwkmXlJhwhJ * gnu/packages/python-xyz.scm (python-immutables): New variable. --- gnu/packages/python-xyz.scm | 26 ++++++++++++++++++++++++++ 1 file changed, 26 insertions(+) diff --git a/gnu/packages/python-xyz.scm b/gnu/packages/python-xyz.scm index 11630d4818..106a6802bd 100644 --- a/gnu/packages/python-xyz.scm +++ b/gnu/packages/python-xyz.scm @@ -20098,3 +20098,29 @@ For the most part it's transliterated from C, the major differences are: outcome of a Python function call, so that it can be passed around.") ;; Choice of either license. (license (list license:expat license:asl2.0)))) + +(define-public python-immutables + (package + (name "python-immutables") + (version "0.14") + (source + (origin + (method url-fetch) + (uri (pypi-uri "immutables" version)) + (sha256 + (base32 + "0y0aqw29g525frdnmv9paljzacpp4s21sadfbca5b137iciwr8d0")))) + (build-system python-build-system) + (home-page + "https://github.com/MagicStack/immutables") + (synopsis "High-performance immutable mapping type for Python") + (description "@code{python-immutables} provides an immutable mapping +type for Python. The underlying datastructure is a Hash Array Mapped Trie +(HAMT), and it's used in Clojure, Scala, Haskell, and other functional +languages. This implementation is used in CPython 3.7 in the contextvars module +(see PEP 550 and PEP 567 for more details). + +Immutable mappings based on HAMT have O(log N) performance for both @code{set()} +and @code{get()} operations, which is essentially O(1) for relatively +small mappings.") + (license license:asl2.0))) -- 2.26.2