From patchwork Fri Mar 25 13:31:28 2022 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: =?utf-8?q?Leo_Nikkil=C3=A4?= X-Patchwork-Id: 38060 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 2AD5627BBEA; Fri, 25 Mar 2022 14:11:24 +0000 (GMT) X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on mira.cbaines.net X-Spam-Level: X-Spam-Status: No, score=-3.7 required=5.0 tests=BAYES_00,DKIM_INVALID, DKIM_SIGNED,MAILING_LIST_MULTI,RCVD_IN_MSPIKE_H5,RCVD_IN_MSPIKE_WL, 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 234AE27BBE9 for ; Fri, 25 Mar 2022 14:11:23 +0000 (GMT) Received: from localhost ([::1]:49066 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1nXkev-0002PK-84 for patchwork@mira.cbaines.net; Fri, 25 Mar 2022 10:11:21 -0400 Received: from eggs.gnu.org ([209.51.188.92]:54968) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1nXkdm-0000lq-Ky for guix-patches@gnu.org; Fri, 25 Mar 2022 10:10:14 -0400 Received: from debbugs.gnu.org ([209.51.188.43]:58172) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1nXkdm-0004bQ-9N for guix-patches@gnu.org; Fri, 25 Mar 2022 10:10:10 -0400 Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1nXkdm-0003AG-0z for guix-patches@gnu.org; Fri, 25 Mar 2022 10:10:10 -0400 X-Loop: help-debbugs@gnu.org Subject: [bug#54560] [PATCH 04/47] gnu: go-github-com-prometheus-client-golang: Update to 1.12.1. Resent-From: Leo =?utf-8?q?Nikkil=C3=A4?= Original-Sender: "Debbugs-submit" Resent-CC: guix-patches@gnu.org Resent-Date: Fri, 25 Mar 2022 14:10:09 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 54560 X-GNU-PR-Package: guix-patches X-GNU-PR-Keywords: patch To: 54560@debbugs.gnu.org Cc: Leo =?utf-8?q?Nikkil=C3=A4?= Received: via spool by 54560-submit@debbugs.gnu.org id=B54560.164821736311735 (code B ref 54560); Fri, 25 Mar 2022 14:10:09 +0000 Received: (at 54560) by debbugs.gnu.org; 25 Mar 2022 14:09:23 +0000 Received: from localhost ([127.0.0.1]:51974 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1nXkd0-000336-4u for submit@debbugs.gnu.org; Fri, 25 Mar 2022 10:09:22 -0400 Received: from wout3-smtp.messagingengine.com ([64.147.123.19]:35187) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1nXk44-0001dj-71 for 54560@debbugs.gnu.org; Fri, 25 Mar 2022 09:33:17 -0400 Received: from compute4.internal (compute4.nyi.internal [10.202.2.44]) by mailout.west.internal (Postfix) with ESMTP id 9C8B43200973; Fri, 25 Mar 2022 09:33:10 -0400 (EDT) Received: from mailfrontend2 ([10.202.2.163]) by compute4.internal (MEProxy); Fri, 25 Mar 2022 09:33:10 -0400 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=lnikki.la; h=cc :cc:content-transfer-encoding:content-type:date:date:from:from :in-reply-to:in-reply-to:message-id:mime-version:references :reply-to:sender:subject:subject:to:to; s=fm2; bh=C2+cuqHll/IovE x/A9oVNGngUsg++3O1SefuAVMdFUw=; b=jyVfmIl6JiQHa/L+Fxw/bqPSdW9hXr 7pZZ/RGJFGKgWflrNR7HZ7SOOPlENDff4M0xnA7buICDtGfWzbvjkuBfbDPNH/GD wwiqkG2wsrQv8icW/gwo6TGRHyNcyO8CqsLHOHifG0DFyRxFifOugjDOqwbaeiFd DPMK8vLRjRKPGV4WXe8Y52bh8zIEZPmgccA9t1PtFAnIJdM+Z/b/hkET0SSX2O5E GraZzEVUk/Loynxu3HFsWq5tJ7NHiuEU/xZP/UyrEMLJ0jTnhP5cswaHlzHL6300 AaBBeglW1CIp1rReur4vNyLYBvTBOf7UGzPai1oRrFbW0FxBQKWv66UA== DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d= messagingengine.com; h=cc:cc:content-transfer-encoding :content-type:date:date:from:from:in-reply-to:in-reply-to :message-id:mime-version:references:reply-to:sender:subject :subject:to:to:x-me-proxy:x-me-proxy:x-me-sender:x-me-sender :x-sasl-enc; s=fm3; bh=C2+cuqHll/IovEx/A9oVNGngUsg++3O1SefuAVMdF Uw=; b=AapcRufI0jnLQptrqkaMo8plTwR4UZhpJc5lMndMlVU0bylOm8EUkR6Wj /TzqaDrH0wsWUEs1X038G2b8sJwHc+aH1T0hBsKaxwiyn98eCSI7IG7Yo4GizOfs +YxC+JI0gv+cwEyk2Iy2wXS/gnpy94C2ALgcLOTLzMHavrxIg9u0A1QAf/zwPxOU LAbQjSMuHme6uBAHiVTH5VEAu98FkPNfOusZdFXVT4nzQiFr1I7pPuJao7llS8VG DtNYglCkpYz9mTP0/vJDYcHJ56Or+i3cv+v2oA6Mn1d73aa/a9HhGZL1/JD18a7m V8HP7Ph/GIIeooliYqCg462btJICg== X-ME-Sender: X-ME-Received: X-ME-Proxy-Cause: gggruggvucftvghtrhhoucdtuddrgedvvddrudehuddgheefucetufdoteggodetrfdotf fvucfrrhhofhhilhgvmecuhfgrshhtofgrihhlpdfqfgfvpdfurfetoffkrfgpnffqhgen uceurghilhhouhhtmecufedttdenucenucfjughrpefhvffufffkofgjfhggtgfgsehtke ertdertdejnecuhfhrohhmpefnvghoucfpihhkkhhilhomuceohhgvlhhloheslhhnihhk khhirdhlrgeqnecuggftrfgrthhtvghrnhepvdeljeevjeelvdehgefhjedtfffgieejhe elgfevfeeikedvudefueejteeiudetnecuffhomhgrihhnpehgihhthhhusgdrtghomhen ucevlhhushhtvghrufhiiigvpedtnecurfgrrhgrmhepmhgrihhlfhhrohhmpehhvghllh hosehlnhhikhhkihdrlhgr X-ME-Proxy: Received: by mail.messagingengine.com (Postfix) with ESMTPA; Fri, 25 Mar 2022 09:33:08 -0400 (EDT) From: Leo =?utf-8?q?Nikkil=C3=A4?= Date: Fri, 25 Mar 2022 15:31:28 +0200 Message-Id: <20220325133211.5128-4-hello@lnikki.la> X-Mailer: git-send-email 2.34.0 In-Reply-To: <20220325133211.5128-1-hello@lnikki.la> References: <20220325133211.5128-1-hello@lnikki.la> MIME-Version: 1.0 X-Mailman-Approved-At: Fri, 25 Mar 2022 10:09:18 -0400 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/patches/go-github-com-prometheus-common-remove-readidletimeout.patch: New patch, avoid updating go-golang-org-x-net just yet. * gnu/packages/syncthing.scm (go-github-com-prometheus-client-golang): Update to 1.12.1. (go-github-com-prometheus-client-model): Update to 0.2.0. (go-github-com-prometheus-common): Update to 0.32.1. [patches]: Use patch. (go-github-com-prometheus-procfs): Update to 0.7.3. {unpack-test-data}, {delete-test-data}: New phases. [arguments]: Enable tests. --- ...etheus-common-remove-readidletimeout.patch | 28 +++ gnu/packages/syncthing.scm | 182 ++++++++++-------- 2 files changed, 130 insertions(+), 80 deletions(-) create mode 100644 gnu/packages/patches/go-github-com-prometheus-common-remove-readidletimeout.patch diff --git a/gnu/packages/patches/go-github-com-prometheus-common-remove-readidletimeout.patch b/gnu/packages/patches/go-github-com-prometheus-common-remove-readidletimeout.patch new file mode 100644 index 0000000000..4eea8ae5c5 --- /dev/null +++ b/gnu/packages/patches/go-github-com-prometheus-common-remove-readidletimeout.patch @@ -0,0 +1,28 @@ +ConfigureTransports was introduced in a newer version of +go-golang-org-x-net: + + +Prior to this, Prometheus didn't configure ReadIdleTimeout: + + +It's somewhat unclear whether ReadIdleTimeout is absolutely required to +work around the upstream issues with HTTP/2 mentioned in the codebase, +however HTTP/2 can be disabled using enable_http2 if this is the case. + +diff --git a/config/http_config.go b/config/http_config.go +index 4b87241..7698ba4 100644 +--- a/config/http_config.go ++++ b/config/http_config.go +@@ -411,11 +411,10 @@ func NewRoundTripperFromConfig(cfg HTTPClientConfig, name string, optFuncs ...HT + // issues again, but will be removed once we are confident that + // things work as expected. + +- http2t, err := http2.ConfigureTransports(rt.(*http.Transport)) ++ err := http2.ConfigureTransport(rt.(*http.Transport)) + if err != nil { + return nil, err + } +- http2t.ReadIdleTimeout = time.Minute + } + + // If a authorization_credentials is provided, create a round tripper that will set the diff --git a/gnu/packages/syncthing.scm b/gnu/packages/syncthing.scm index 107b97e547..b9c72a3212 100644 --- a/gnu/packages/syncthing.scm +++ b/gnu/packages/syncthing.scm @@ -7,6 +7,7 @@ ;;; Copyright © 2021 Maxim Cournoyer ;;; Copyright © 2021 Arun Isaac ;;; Copyright © 2022 John Kehayias +;;; Copyright © 2022 Leo Nikkilä ;;; ;;; This file is part of GNU Guix. ;;; @@ -819,34 +820,32 @@ (define-public go-github-com-beorn7-perks-quantile (license expat)))) (define-public go-github-com-prometheus-client-model - (let ((commit "14fe0d1b01d4d5fc031dd4bec1823bd3ebbe8016") - (revision "2")) - (package - (name "go-github-com-prometheus-client-model") - (version (git-version "0.0.2" revision commit)) - (source (origin - (method git-fetch) - (uri (git-reference - (url "https://github.com/prometheus/client_model") - (commit commit))) - (file-name (git-file-name name version)) - (sha256 - (base32 - "0zdmk6rbbx39cvfz0r59v2jg5sg9yd02b4pds5n5llgvivi99550")))) - (build-system go-build-system) - (arguments - '(#:import-path "github.com/prometheus/client_model" - #:tests? #f - #:phases - (modify-phases %standard-phases - ;; Source-only package - (delete 'build)))) - (propagated-inputs - (list go-github-com-golang-protobuf-proto)) - (synopsis "Data model artifacts for Prometheus") - (description "This package provides data model artifacts for Prometheus.") - (home-page "https://github.com/prometheus/client_model") - (license asl2.0)))) + (package + (name "go-github-com-prometheus-client-model") + (version "0.2.0") + (source (origin + (method git-fetch) + (uri (git-reference + (url "https://github.com/prometheus/client_model") + (commit (string-append "v" version)))) + (file-name (git-file-name name version)) + (sha256 + (base32 + "0jffnz94d6ff39fr96b5w8i8yk26pwnrfggzz8jhi8k0yihg2c9d")))) + (build-system go-build-system) + (arguments + '(#:import-path "github.com/prometheus/client_model" + #:tests? #f + #:phases + (modify-phases %standard-phases + ;; Source-only package + (delete 'build)))) + (propagated-inputs (list go-github-com-golang-protobuf-proto + go-github-com-golang-protobuf-ptypes)) + (synopsis "Data model artifacts for Prometheus") + (description "This package provides data model artifacts for Prometheus.") + (home-page "https://github.com/prometheus/client_model") + (license asl2.0))) (define-public go-github-com-matttproud-golang-protobuf-extensions-pbutil (let ((commit "c12348ce28de40eed0136aa2b644d0ee0650e56c") @@ -879,65 +878,87 @@ (define-public go-github-com-matttproud-golang-protobuf-extensions-pbutil (license asl2.0)))) (define-public go-github-com-prometheus-common - (package - (name "go-github-com-prometheus-common") - (version "0.4.1") - (source (origin - (method git-fetch) - (uri (git-reference - (url "https://github.com/prometheus/common") - (commit (string-append "v" version)))) - (file-name (git-file-name name version)) - (sha256 - (base32 - "0sf4sjdckblz1hqdfvripk3zyp8xq89w7q75kbsyg4c078af896s")))) - (build-system go-build-system) - (arguments - '(#:import-path "github.com/prometheus/common" - #:tests? #f - #:phases - (modify-phases %standard-phases - ;; Source-only package - (delete 'build)))) - (propagated-inputs - (list go-github-com-golang-protobuf-proto - go-github-com-matttproud-golang-protobuf-extensions-pbutil - go-github-com-prometheus-client-model)) - (synopsis "Prometheus metrics") - (description "This package provides tools for reading and writing + (package + (name "go-github-com-prometheus-common") + (version "0.32.1") + (source (origin + (method git-fetch) + (uri (git-reference + (url "https://github.com/prometheus/common") + (commit (string-append "v" version)))) + (file-name (git-file-name name version)) + (sha256 + (base32 + "0501dwlv427vr78c59h4z25vxzkzjx76haydjj4pql1sx44546vv")) + ;; This can be removed once go-golang-org-x-net is + ;; updated past 08b38378de702b893ee869b94b32f833e2933bd2. + (patches + (search-patches + "go-github-com-prometheus-common-remove-readidletimeout.patch")))) + (build-system go-build-system) + (arguments + '(#:import-path "github.com/prometheus/common" + #:tests? #f + #:phases + (modify-phases %standard-phases + ;; Source-only package + (delete 'build)))) + (propagated-inputs + (list go-github-com-golang-protobuf-proto + go-github-com-golang-protobuf-ptypes + go-github-com-julienschmidt-httprouter + go-github-com-matttproud-golang-protobuf-extensions-pbutil + go-github-com-prometheus-client-model)) + (synopsis "Prometheus metrics") + (description "This package provides tools for reading and writing Prometheus metrics.") - (home-page "https://github.com/prometheus/common") - (license asl2.0))) + (home-page "https://github.com/prometheus/common") + (license asl2.0))) (define-public go-github-com-prometheus-procfs - (package - (name "go-github-com-prometheus-procfs") - (version "0.0.4") - (source (origin - (method git-fetch) - (uri (git-reference - (url "https://github.com/prometheus/procfs") - (commit (string-append "v" version)))) - (file-name (git-file-name name version)) - (sha256 - (base32 - "1z5jq5rjala0a0di4nwk1rai0z9f73qwqj6mgcbpjbg2qknlb544")))) - (build-system go-build-system) - (arguments - '(#:import-path "github.com/prometheus/procfs" - ;; The tests require Go modules, which are not yet supported in Guix's - ;; Go build system. - #:tests? #f)) - (synopsis "Go library for reading @file{/proc}") - (description "The @code{procfs} Go package provides functions to retrieve + (package + (name "go-github-com-prometheus-procfs") + (version "0.7.3") + (source (origin + (method git-fetch) + (uri (git-reference + (url "https://github.com/prometheus/procfs") + (commit (string-append "v" version)))) + (file-name (git-file-name name version)) + (sha256 + (base32 + "00z7ghcb86y2ajx0xvwmn3d18nq4djmvmjn52crgm85gsl442lb4")))) + (build-system go-build-system) + (arguments + '(#:import-path "github.com/prometheus/procfs" + #:phases + (modify-phases %standard-phases + (add-before 'check 'unpack-test-data + (lambda* (#:key tests? import-path #:allow-other-keys) + (when tests? + (with-directory-excursion (string-append "src/" import-path) + (invoke "make" "fixtures"))) + #t)) + ;; We don't want to install fixtures and other test data. + (add-before 'install 'delete-test-data + (lambda* (#:key import-path #:allow-other-keys) + (with-directory-excursion (string-append "src/" import-path) + (delete-file "ttar") + (delete-file "fixtures.ttar") + (delete-file-recursively "fixtures")) + #t))))) + (propagated-inputs (list go-golang-org-x-sys)) + (native-inputs (list go-github-com-google-go-cmp-cmp)) + (synopsis "Go library for reading @file{/proc}") + (description "The @code{procfs} Go package provides functions to retrieve system, kernel, and process metrics from the @file{/proc} pseudo file system.") - (home-page "https://github.com/prometheus/procfs") - (license asl2.0))) + (home-page "https://github.com/prometheus/procfs") + (license asl2.0))) (define-public go-github-com-prometheus-client-golang (package (name "go-github-com-prometheus-client-golang") - (version "1.2.1") + (version "1.12.1") (source (origin (method git-fetch) (uri (git-reference @@ -946,7 +967,7 @@ (define-public go-github-com-prometheus-client-golang (file-name (git-file-name name version)) (sha256 (base32 - "0zs49psk23n9z8wrl02d5vib5wclpym8kaxcy6n5pk696i419065")))) + "0d46nindizpjgdygryc140fd94j1qfkzwyzwh9p2g3zp6v4fw0s1")))) (build-system go-build-system) (arguments '(#:tests? #f @@ -958,6 +979,7 @@ (define-public go-github-com-prometheus-client-golang (propagated-inputs (list go-github-com-beorn7-perks-quantile go-github-com-golang-protobuf-proto + go-github-com-golang-protobuf-ptypes go-github-com-prometheus-client-model go-github-com-prometheus-common go-github-com-prometheus-procfs