Message ID | 20210427025715.39514-2-andrew.gregory.8@gmail.com |
---|---|
State | Accepted, archived |
Headers | show
Return-Path: <pacman-dev-bounces@lists.archlinux.org> Delivered-To: patchwork@archlinux.org Received: from mail.archlinux.org [95.216.189.61] by patchwork.archlinux.org with IMAP (fetchmail-6.4.18) for <fetchmail@localhost> (single-drop); Tue, 27 Apr 2021 02:57:41 +0000 (UTC) Received: from mail.archlinux.org by mail.archlinux.org with LMTP id yEmSKaR9h2C81ggAK+/4rw (envelope-from <pacman-dev-bounces@lists.archlinux.org>) for <patchwork@archlinux.org>; Tue, 27 Apr 2021 02:57:40 +0000 Received: from luna.archlinux.org (luna.archlinux.org [5.9.250.164]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange ECDHE (P-384) server-signature RSA-PSS (4096 bits)) (No client certificate requested) by mail.archlinux.org (Postfix) with ESMTPS id 36AE9539E17; Tue, 27 Apr 2021 02:57:39 +0000 (UTC) Received: from luna.archlinux.org (luna.archlinux.org [127.0.0.1]) by luna.archlinux.org (Postfix) with ESMTP id D38E72C71E; Tue, 27 Apr 2021 02:57:38 +0000 (UTC) Received: from luna.archlinux.org (luna.archlinux.org [127.0.0.1]) by luna.archlinux.org (Postfix) with ESMTP id 751CB2C71E for <pacman-dev@lists.archlinux.org>; Tue, 27 Apr 2021 02:57:34 +0000 (UTC) X-Spam-Checker-Version: SpamAssassin 3.4.5 (2021-03-20) on luna.archlinux.org X-Spam-Level: X-Spam-Status: No, score=-1.9 required=5.0 tests=DKIM_SIGNED=0.1, DKIM_VALID=-0.1,DKIM_VALID_AU=-0.1,FREEMAIL_FROM=0.5, RCVD_IN_DNSWL_MED=-2.3,T_DMARC_POLICY_NONE=0.01, T_DMARC_SIMPLE_DKIM=0.01 autolearn=failed autolearn_force=no version=3.4.5 X-Spam-BL-Results: <dns:206.137.207.98.dnsbl.sorbs.net> [127.0.0.10] <dns:1.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.2.5.0.3.0.1.0.c.9.f.4.0.1.0.a.2.list.dnswl.org> [127.0.9.2] <dns:206.137.207.98.zen.spamhaus.org> [127.0.0.10] Received: from mail.archlinux.org (mail.archlinux.org [IPv6:2a01:4f9:c010:3052::1]) by luna.archlinux.org (Postfix) with ESMTPS for <pacman-dev@lists.archlinux.org>; Tue, 27 Apr 2021 02:57:34 +0000 (UTC) Received: from mail-pf1-x42c.google.com (mail-pf1-x42c.google.com [IPv6:2607:f8b0:4864:20::42c]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange ECDHE (P-384) server-signature RSA-PSS (4096 bits) server-digest SHA256) (No client certificate requested) by mail.archlinux.org (Postfix) with ESMTPS id B1B5F539E15 for <pacman-dev@archlinux.org>; Tue, 27 Apr 2021 02:57:32 +0000 (UTC) Received: by mail-pf1-x42c.google.com with SMTP id a12so541296pfc.7 for <pacman-dev@archlinux.org>; Mon, 26 Apr 2021 19:57:32 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=from:to:cc:subject:date:message-id:in-reply-to:references :mime-version:content-transfer-encoding; bh=zz+91XwLfOnr5NNbyCWRD9Kk9jIbrI8Ejcw70QDL+Gk=; b=qb5f+TXqfkP8/polObRh0IxvqbwtlM6qTFvJPMx4zqfMvC6reAVHH2cpGShaadCA3V sP6DhlZj9ZA0ATo8bIGzIUzAPihP+yw5J07n9ttP4MR/14dckOqsIVe3POsx67CsgDwh yVbUuwJ8Z/M3/yxdds9He0ARWPDjzl1IdOy86x1B9RWplc5sFRERDMo8s07dFBCH0DtP 7gecPivTlhYDRTa/Tvm5Y5gYpo7J1Jwyr1xIaaC1KBkd6tSO0aUo8cwv3hYm7olxxzqD RJNZa1mKDIEzE+Zya1kELqD9spy8fPf/TYNVJvOmKUTvC+XLnxikG5FHzjAzfiQ3tMSu eH7w== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:cc:subject:date:message-id:in-reply-to :references:mime-version:content-transfer-encoding; bh=zz+91XwLfOnr5NNbyCWRD9Kk9jIbrI8Ejcw70QDL+Gk=; b=oXlTITYhZ1mjjxn7yHGU1N3fWDKHaqK9jK3UFGcUUPqEvkcpDlnU/tl+gUiyk3FTB3 5EjtuYwqwGpyrVF1KynDgKHfTt/weyRpr9dXgOoIbLQm2uwDc1qmxQX394EspmW8HGhp gv9YY8v/b/P3lGdmzQfjexYfNBs8JcXQkF/z0Gh9RZUoxEXBWfXjo1ksm3i5bjIOU/Kw idJDnNkLKsuF/ShEtHWJhv/0prynIBjNQQWcbJP+pBpMAipKAk0yuWewJ/ZZst47rgu5 uVAI12D5wIWITB3uGtL8jUuRrbVPgw2bijQKQStXuVqac0PVARAPHVjJMTidAS0ljmW2 AZ3w== X-Gm-Message-State: AOAM533c4GHSfZmEckiNd/YzTS2kv64AGD4KklPH1d34SZxMKRxhJ61p 0h9FHcN8twzlVn4PJIv+boos1GTDl8DkBw== X-Google-Smtp-Source: ABdhPJzLRSwtIqK0fr8t5kVLbta3uHRb32THGbRdTHIMPO8YKtaSJk7rIXQSjLUtaZSQzoUBfxLtEg== X-Received: by 2002:a05:6a00:b94:b029:278:3e2f:a5a with SMTP id g20-20020a056a000b94b02902783e2f0a5amr5343734pfj.25.1619492250748; Mon, 26 Apr 2021 19:57:30 -0700 (PDT) Received: from localhost.localdomain (c-98-207-137-206.hsd1.ca.comcast.net. [98.207.137.206]) by smtp.gmail.com with ESMTPSA id i126sm861589pfc.20.2021.04.26.19.57.30 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Mon, 26 Apr 2021 19:57:30 -0700 (PDT) From: Andrew Gregory <andrew.gregory.8@gmail.com> To: pacman-dev@archlinux.org Cc: Andrew Gregory <andrew.gregory.8@gmail.com> Date: Mon, 26 Apr 2021 19:57:14 -0700 Message-Id: <20210427025715.39514-2-andrew.gregory.8@gmail.com> X-Mailer: git-send-email 2.31.1 In-Reply-To: <20210427025715.39514-1-andrew.gregory.8@gmail.com> References: <20210427025715.39514-1-andrew.gregory.8@gmail.com> MIME-Version: 1.0 Content-Transfer-Encoding: 8bit Subject: [pacman-dev] [PATCH 2/3] pmserve: allow serving byte objects directly X-BeenThere: pacman-dev@lists.archlinux.org X-Mailman-Version: 2.1.34 Precedence: list List-Id: Discussion list for pacman development <pacman-dev.lists.archlinux.org> List-Unsubscribe: <https://lists.archlinux.org/options/pacman-dev>, <mailto:pacman-dev-request@lists.archlinux.org?subject=unsubscribe> List-Archive: <https://lists.archlinux.org/pipermail/pacman-dev/> List-Post: <mailto:pacman-dev@lists.archlinux.org> List-Help: <mailto:pacman-dev-request@lists.archlinux.org?subject=help> List-Subscribe: <https://lists.archlinux.org/listinfo/pacman-dev>, <mailto:pacman-dev-request@lists.archlinux.org?subject=subscribe> Reply-To: Discussion list for pacman development <pacman-dev@lists.archlinux.org> Errors-To: pacman-dev-bounces@lists.archlinux.org Sender: "pacman-dev" <pacman-dev-bounces@lists.archlinux.org> Authentication-Results: mail.archlinux.org; dkim=fail ("headers rsa verify failed") header.d=gmail.com header.s=20161025 header.b=qb5f+TXq; dmarc=fail reason="SPF not aligned (relaxed)" header.from=gmail.com (policy=none); spf=pass (mail.archlinux.org: domain of pacman-dev-bounces@lists.archlinux.org designates 5.9.250.164 as permitted sender) smtp.mailfrom=pacman-dev-bounces@lists.archlinux.org X-Rspamd-Queue-Id: 36AE9539E17 X-Spamd-Result: default: False [4.19 / 15.00]; HAS_REPLYTO(0.00)[pacman-dev@lists.archlinux.org]; RCVD_VIA_SMTP_AUTH(0.00)[]; GREYLIST(0.00)[pass,meta]; TO_DN_SOME(0.00)[]; R_DKIM_REJECT(1.00)[gmail.com:s=20161025]; FREEMAIL_FROM(0.00)[gmail.com]; R_MISSING_CHARSET(2.50)[]; BROKEN_CONTENT_TYPE(1.50)[]; R_SPF_ALLOW(-0.20)[+ip4:5.9.250.164]; DKIM_TRACE(0.00)[gmail.com:-]; RCPT_COUNT_TWO(0.00)[2]; RCVD_IN_DNSWL_MED(-0.40)[2a01:4f9:c010:3052::1:received,5.9.250.164:from]; MAILLIST(-0.20)[mailman]; RECEIVED_SPAMHAUS_PBL(0.00)[98.207.137.206:received]; MIME_TRACE(0.00)[0:+]; RCVD_TLS_LAST(0.00)[]; ASN(0.00)[asn:24940, ipnet:5.9.0.0/16, country:DE]; MID_RHS_MATCH_FROM(0.00)[]; TAGGED_FROM(0.00)[]; FROM_NEQ_ENVFROM(0.00)[andrewgregory8@gmail.com,pacman-dev-bounces@lists.archlinux.org]; ARC_NA(0.00)[]; FROM_HAS_DN(0.00)[]; TAGGED_RCPT(0.00)[]; REPLYTO_DOM_NEQ_FROM_DOM(0.00)[]; MIME_GOOD(-0.10)[text/plain]; HAS_LIST_UNSUB(-0.01)[]; RCVD_IN_DNSWL_NONE(0.00)[2607:f8b0:4864:20::42c:received]; NEURAL_HAM(-0.00)[-1.000]; FREEMAIL_CC(0.00)[gmail.com]; RCVD_COUNT_SEVEN(0.00)[7]; FORGED_SENDER_MAILLIST(0.00)[]; DMARC_POLICY_SOFTFAIL(0.10)[gmail.com : SPF not aligned (relaxed),none] X-Rspamd-Server: mail.archlinux.org |
Series |
[pacman-dev,1/3] pmpkg: add makepkg_bytes
|
expand
|
diff --git a/test/pacman/pmserve.py b/test/pacman/pmserve.py index 47e041d0..b6de9797 100644 --- a/test/pacman/pmserve.py +++ b/test/pacman/pmserve.py @@ -78,6 +78,8 @@ def do_GET(self): response.get('body', ''), headers=response.get('headers', {}), code=response.get('code', 200)) + elif isinstance(response, bytes): + self.respond_bytes(response) else: self.respond_string(response) else:
Useful for serving in-memory package files. Signed-off-by: Andrew Gregory <andrew.gregory.8@gmail.com> --- test/pacman/pmserve.py | 2 ++ 1 file changed, 2 insertions(+)